2.2.7.10 SelectStream

The purpose of the SelectStream request is to ask the server to modify the streaming state of one or two streams in the content. It is possible to ask the server to start or stop streaming a particular stream. It is also possible to ask the server to replace one stream with another and to specify if a stream is to be thinned. A thinned stream is a stream for which the server transmits only ASF media objects that are marked as containing key-frame data. The entity that creates the ASF media objects is responsible for marking them as key-frames as specified in [ASF] section 6.3, when appropriate.

The SelectStream request uses either the SETUP request method as specified in section 2.2.7.10.1, the TEARDOWN request method as specified in section 2.2.7.10.2, or the SET_PARAMETER request method as specified in section 2.2.7.10.3.

The syntax for the SelectStream requests that request a server to start streaming a new stream without replacing some other stream with the new stream is defined in section 2.2.7.10.1.

The syntax for the SelectStream requests that request a server is to stop streaming a stream without replacing that stream with some new stream is defined in section 2.2.7.10.2.

The syntax for the SelectStream requests that request a server to start or stop thinning that stream (that is, start or stop transmitting only ASF media objects that are marked as containing key-frame data) is defined in section 2.2.7.10.3.

The syntax for the SelectStream requests that request a server to replace one stream with another stream when both streams can use the same RTP session is defined in section 2.2.7.10.3.

It is not possible to use a SelectStream request to replace a pair of streams if they use different RTP sessions, for example, if one stream uses TCP and the other uses UDP. In this case, the client will have to send two SelectStream requests instead, one mapped to the TEARDOWN method and the other one mapped to the SETUP method.

Regardless of the RTSP request method used in the syntax of the SelectStream request, the following constraints apply to the syntax:

The message body is defined by the following ABNF syntax:

 OldStream         = 1*10DIGIT
 NewStream         = 1*10DIGIT
 ThinLevel         = "0" | "1" | "2"
 OldStreamURI      = rtsp_URL                 ; [RFC2326] section 3.2
 NewStreamURI      = rtsp_URL                 ; [RFC2326] section 3.2
 message-body      = "SSEntry:" SP OldStream SP NewStream SP ThinLevel 
                    [ SP OldStreamURI ]
                    [ SP NewStreamURI ]
                    CRLF

The value of the OldStream and NewStream parameters MUST be an integer in the range 0 to 4,294,967,295, inclusive. If there is a stream number then the value MUST be equal to the stream number of the stream being referenced, as determined by the "a=stream" attribute (for details, see section 2.2.5.2.5) in the corresponding SDP media description. If there is no applicable stream number (because a stream is only added or only removed), then the value MUST be set to 4,294,967,295.

The OldStreamURI parameter MUST NOT be present if the value of OldStream is 4,294,967,295. Otherwise, OldStreamURI MUST be present.

The NewStreamURI parameter MUST NOT be present if the value of NewStream is 4,294,967,295. Otherwise, NewStreamURI MUST be present.

The ThinLevel parameter specifies the thinning level of the stream identified by the NewStreamURI parameter, as specified in the following table.

 Value

 Meaning

0

All ASF media objects for the stream given by NewStreamURI are to be transmitted.

1

Only ASF media objects for the stream given by NewStreamURI that are marked as containing key-frame data are to be transmitted.

2

No ASF media objects for the stream given by NewStreamURI are to be transmitted.

If the value of the NewStream parameter is 4,294,967,295, then the value of the ThinLevel parameter SHOULD be 0 and MUST be ignored by the server.

The server's response to a SelectStream request does not include a message body.