Has anyone succeeded in modifying the LiveMedia classes to support accepting parameters in the URI, something like the following to request a specific height and width, bitrate, and framerate:

rtsp://media.server.com/live_video?height=320&width=400&kbps=300&fps=15

With a H.264 stream changing some of these parameters will change the SPS, and PPS and thus change the SDP. The way RTSPServer, ServerMediaSession, and OnDemandMediaSession work they all make assumptions about the media name and that the SDP will not change

For this reason, you should probably treat each stream as having its own "ServerMediaSubsession" (subclass) object, rather than trying to use the same "ServerMediaSubsession" (subclass) object for each stream. That way, these objects can continue to work from the assumption that their SDP config information - once set up - will not change.

For example (to use your example string), "live_video?height=320&width=400&kbps=300&fps=15" would use a completely separate "ServerMediaSubsession" (subclass) object than "live_video?height=320&width=400&kbps=300&fps=30".

You can probably do this by subclassing "RTSPServer" and redefining the virtual function "lookupServerMediaSession()" in your subclass. Plus, of course, you'll need your own subclass of "OnDemandServerMediaSubsession" (it'll be similar to "H264VideoFileServerMediaSubsession" if you're streaming H.264), but you're presumably already doing that.

Once again, when you think of extending the supplied code, you should be thinking first about subclassing, and modify the supplied code only as a last resort (if at all).

I also want to remind everyone that subclassing the code considerably simplifies your obligations under the LGPL. If you modify the supplied code, and then release a product based on these modifications, then you are required to also make your modified source code available. If, instead, you subclass the supplied code (without modifying it), then you are not required to make available any of your source code.
--

Ross Finlayson
Live Networks, Inc.
http://www.live555.com/
_______________________________________________
live-devel mailing list
live-devel@lists.live555.com
http://lists.live555.com/mailman/listinfo/live-devel

Reply via email to