does a Upnp stop command to a renderer stop immediately

110 views Asked by At

Is the Upnp stop command supposed to stop a renderer immediately or is it supposed to empty the buffer first and then stop the renderer?

1

There are 1 answers

0
simonc On

Assuming you're asking about the Stop action on the AVTransport service, precise behaviour is undefined.

UPnP-av-AVTransport-v1-Service-20020625.pdf from the UPnP Forum docs bundle says the following about Stop:

This action stops the progression of the current resource that is associated with the specified instance. Additionally, it is recommended that the “output of the device” (defined below) should change to something other than the current snippet of resource. Although the exact nature of this change varies from device to device, a common behavior is to immediately cease all “output” from the device. Nevertheless, the exact behavior is defined by the manufacturer of the device

There is no specification for how quickly progression of the current resource stops. This means that it is possible (and valid) for a device to play some/all of its buffered content before stopping.

If you are implementing a renderer, you should probably make reasonable efforts to discard at least some of your buffered content when Stop is invoked. If you are writing a control point, you can't make any assumptions in general. (You probably also don't care exactly how a device implements the action though.)

There may be further guarantees offered if you limit yourself to dealing with devices which are DLNA compatible. DLNA specs are not freely available so I can't say whether they mandate any particular interpretation of the AVTransport spec.