<div dir="ltr"><div>Hi Michael, <br></div><div><br></div><div>Thanks for replying. The gst_rtsp_media_factory_set_shared is already being called on line 76 of examples/test-launch.c <a href="https://gitlab.freedesktop.org/gstreamer/gst-rtsp-server/-/blob/master/examples/test-launch.c#L76">https://gitlab.freedesktop.org/gstreamer/gst-rtsp-server/-/blob/master/examples/test-launch.c#L76</a></div><div>The default v4l2h264enc h264_i_frame_period is 60 and the video FPS is 20; could this be contributing to connection not establishing as well (don't know if rtsp server starts new client at next or previous keyframe). Any other suggestion to mitigate issue with v4l2src and pipelines? <br></div><div><br></div><div>Thanks <br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, Mar 9, 2022 at 12:30 AM Michael Gruner <<a href="mailto:michael.gruner@ridgerun.com">michael.gruner@ridgerun.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="auto">The problem is v4l2src and not gstrtspserver. Every time a new client connects, a new “pipeline” (called media in the server context) is created and played. The problem, I believe, is that the first client already has the device occupied. <div><br></div><div>Try setting gst_rtsp_media_factory_set_shared to true so that all clients share the same camera. </div><div><br></div><div><a href="https://gstreamer.freedesktop.org/documentation/gst-rtsp-server/rtsp-media-factory.html?gi-language=c#gst_rtsp_media_factory_set_shared" target="_blank">https://gstreamer.freedesktop.org/documentation/gst-rtsp-server/rtsp-media-factory.html?gi-language=c#gst_rtsp_media_factory_set_shared</a><br><br><div dir="ltr">Michael</div><div dir="ltr"><br><blockquote type="cite">On 8 Mar 2022, at 22:29, Alan Petrus via gstreamer-devel <<a href="mailto:gstreamer-devel@lists.freedesktop.org" target="_blank">gstreamer-devel@lists.freedesktop.org</a>> wrote:<br><br></blockquote></div><blockquote type="cite"><div dir="ltr"><div dir="ltr"><div>Hello, <br></div><div><br></div><div>I'm running test-launch.c from the gst-rtsp-server examples folder without any modifications; when the second client connects it kicks the first connected client. How can I get multiple clients to see the same video from a USB camera? (rtsp over tcp)<br></div><div><br></div><div>Here is my pipeline: <br></div><div>v4l2src device=/dev/video0 do-timestamp=true ! image/jpeg,width=1920,height=1080,framerate=20/1 ! jpegparse ! queue leaky=2 ! v4l2jpegdec output-io-mode=4 capture-io-mode=0 ! v4l2convert ! queue ! v4l2h264enc output-io-mode=5 capture-io-mode=4 extra-controls=controls,video_bitrate=4000000,repeat_sequence_header=1,h264_level=13,h264_profile=4; ! capsfilter caps=\"video/x-h264,profile=high,level=(string)4.2\" ! queue ! h264parse config-interval=-1 ! rtph264pay pt=96 name=pay0</div><div><br></div><div>logs:<br></div><div><a href="https://pastebin.com/geE40G0M" target="_blank">https://pastebin.com/geE40G0M</a></div><div><br></div><div>Thank you<br></div></div>
</div></blockquote></div></div></blockquote></div>