Discussion:
RTSP server streaming problem
Tran Tu
2016-05-17 07:46:42 UTC
Permalink
Dear all,

I am a new bee in Gstreamer and need your support for my problem recently.

Currently, I create a streaming server by using gstreamer RTSP server.
My intention is that for each pipeline constructed after calling
gst_rtsp_media_factory_set_launch(), only one client can access to the
stream. I use gst_rtsp_media_factory_set_shared (media, FALSE) but it is not
affected.

Is there anyone know how to configure this constraint?

Thanks for your great support.

Best regards,
Tran Tu



--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/RTSP-server-streaming-problem-tp4677595.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.
bomba
2016-05-17 08:50:14 UTC
Permalink
Hello Tran Tu,
Post by Tran Tu
My intention is that for each pipeline constructed after calling
gst_rtsp_media_factory_set_launch(), only one client can access to the
stream. I use gst_rtsp_media_factory_set_shared (media, FALSE) but it is
not affected.
What do you mean with "it is not affected"?

https://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-rtsp-server/html/GstRTSPMediaFactory.html
Post by Tran Tu
Configure if media created from this factory can be shared between
clients.
Setting this to FALSE, will not allow a second client to play the media.



--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/RTSP-server-streaming-problem-tp4677595p4677602.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.
Tran Tu
2016-05-17 21:44:56 UTC
Permalink
Hi Bomba,

When I run the "test-video" in examples of package gst-rtsp-server plugin
with this setting added
gst_rtsp_media_factory_set_shared (media, FALSE)

If I access to the stream twice (one is localhost) one from another LAN pc.
I can view two streams successfully, I wonder the way to configure that if
there is already one connection of client, another cannot access to see the
stream anymore.






--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/RTSP-server-streaming-problem-tp4677595p4677622.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.
Michael Gruner
2016-05-18 05:59:27 UTC
Permalink
Hi Tran Tu

You may try limiting the number of sessions to 1. To do so, try the following:

guint num_sessions = 1;

GstRTSPSessionPool *pool = gst_rtsp_server_get_session_pool(server);
gst_rtsp_session_pool_set_max_sessions (pool, num_sessions);

g_object_unref (pool);


Regards
Michael

—
Michael Gruner <***@ridgerun.com <mailto:***@ridgerun.com>>
Embedded Linux and GStreamer solutions
RidgeRun Engineering
Contact Us - http://www.ridgerun.com/#!contact/c3vn <http://www.ridgerun.com/#!contact/c3vn>
Post by Tran Tu
Hi Bomba,
When I run the "test-video" in examples of package gst-rtsp-server plugin
with this setting added
gst_rtsp_media_factory_set_shared (media, FALSE)
If I access to the stream twice (one is localhost) one from another LAN pc.
I can view two streams successfully, I wonder the way to configure that if
there is already one connection of client, another cannot access to see the
stream anymore.
--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/RTSP-server-streaming-problem-tp4677595p4677622.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.
_______________________________________________
gstreamer-devel mailing list
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Tran Tu
2016-05-23 11:30:24 UTC
Permalink
Dear Michael Gruner,

Thanks for your suggestion. From which now I can limit the client number to
1 only.

Best regards,
Tran Tu



--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/RTSP-server-streaming-problem-tp4677595p4677727.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.
Continue reading on narkive:
Loading...