Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

4.10 Stream Selection

The SelectStream request is sent by the client to notify the server which streams (2) it requests. If a file contains only one stream, the SelectStream request will request that the server send the default streams for that file. A SelectStream request will always accompany a Play request to denote which audio and/or video streams the client wants to play based on preferences and bandwidth considerations. As with Log and KeepAlive requests, SelectStream request can be sent multiple times during a session, and they are always sent as a POST request on a separate TCP connection.

The following scenarios are examples of when a SelectStream request would be sent by the client:

  • When streaming a server-side playlist, the client will send a SelectStream request between each playlist entry.

  • When streaming a multi-language Windows Media Audio (.wma) file, the client will send a SelectStream request whenever the client changes from one language to another.

  • When streaming a multiple bit rate ASF file, the client will send a SelectStream request whenever it experiences a prolonged change in bandwidth conditions.

The sequencing applies to both the pipelined and the non-pipelined mode of the protocol:

  1. The client sends a Describe request to retrieve the ASF header.

  2. The server responds with a $H (Header) packet.

  3. The client sends a Play request for the file, selecting one or more streams.

  4. The server responds with a $H (Header) packet and $D (Data) packets.

  5. To change streams, the client passes the stream selection information using a SelectStream request with the stream-switch-entry token on a Pragma header.

  6. The server responds by acknowledging the client request and switching to the requested stream.

  7. Note To avoid disruptions in a video stream, the server will switch the streams at a key frame.

  8. The client detects the stream change in the data stream and renders the new stream.

  9. Note The client will not send a message to the server as a result of this stream change.

The following figure shows the previously described sequence.

MS-WMSP_pict71dce2db-b5c5-4005-9fc3-3bf81ddd368f.png

Figure 13: Using the SelectStream Request packet sequencing

Show:
© 2015 Microsoft