Hi,
Can anyone point me as how to serve feeds based on the client request? Based on the test-launch example, if we give the url, rtsp://ip-address:8554/test from a vlc-client, the server will start serving a particular feed. Is it possible to have something like this, a) if client gives url/test1 - serve first video file b) if client gives url/test2 - stop serving the first video file and start serving the second video file and so on.. Can someone point as how I can go about in doing this? Thanks, Krishnan. |
On 07/21/11 23:22, Krishnan wrote:
> Hi, > > Can anyone point me as how to serve feeds based on the client request? > > Based on the test-launch example, if we give the url, > rtsp://ip-address:8554/test from a vlc-client, the server will start serving > a particular feed. Is it possible to have something like this, > > a) if client gives url/test1 - serve first video file > b) if client gives url/test2 - stop serving the first video file and start > serving the second video file > and so on.. short and its easy to see where the "test" url comes from. Stefan > > Can someone point as how I can go about in doing this? > > Thanks, > Krishnan. > > -- > View this message in context: http://gstreamer-devel.966125.n4.nabble.com/Gst-Rtsp-Server-serving-feeds-on-client-request-tp3685133p3685133.html > Sent from the GStreamer-devel mailing list archive at Nabble.com. > _______________________________________________ > gstreamer-devel mailing list > [hidden email] > http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel _______________________________________________ gstreamer-devel mailing list [hidden email] http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
Hi Stefan,
Thank you for the reply. It looks like I have to create different factories for each stream. I tried like this, factory = gst_rtsp_media_factory_new (); factory1 = gst_rtsp_media_factory_new (); capture_input = 2; // to select second camera ret = initCapture(capture_input); gst_rtsp_media_factory_set_launch (factory, "( " "v4l2src ! video/x-raw-yuv,width=720,height=480 ! " "queue ! TIVidenc1 codecName=h264enc engineName=codecServer byteStream=FALSE ! " "queue ! rtph264pay pt=96 name=pay0 " ")"); gst_rtsp_media_factory_set_launch (factory1, "( " "videotestsrc ! video/x-raw-yuv,width=720,height=480 ! " "queue ! TIVidenc1 codecName=h264enc engineName=codecServer byteStream=FALSE ! " "queue ! rtph264pay pt=96 name=pay0 " ")"); gst_rtsp_media_mapping_add_factory (mapping, "/test", factory); gst_rtsp_media_mapping_add_factory (mapping, "/test1", factory1); gst_rtsp_media_factory_set_shared( factory, 1 ); gst_rtsp_media_factory_set_shared( factory1, 1 ); I could see both the videotestscr and v4l2src by accessing their respective URL's. My requirement is to stream different cameras having the same factory (v4l2src=/dev/video0 - cameras are selected based on the i2c commands and they all have the same /dev/video0 port) with different urls. For eg) if first url is selected, i should initialize the first camera (capture_input = 1 -> to select the first camera) and then pass the factory (containing v4l2src) to the mapping. Similarly, if second url is selected, i should initialize the second camera (capture_input = 2 -> to select the second camera) and then pass the factory (containing v4l2src) to the mapping. As you can see, I cannot pass the "capture_input" argument to the factory. So, I should find a way to initialize my camera first based on the url requested. Can you suggested me a way of how I can do this? Thanks, Krishnan. |
Free forum by Nabble | Edit this page |