GStreamer RTSP server config

Chuck Crisler ccrisler at mutualink.net
Tue Sep 10 13:58:14 PDT 2013


I am confused about GStreamer RTSP processing. In the rtsp-server.c module,
the header for gst_rtsp_server_attach() states that the function should be
called when the server properties and URLs are fully configured. My URLs
don't change after the app is started, but users come and go. Here is the
process I follow.

This is done only once to initialize the server.

1. I set the server address and service.
2. Loop to create the factories, usually several.
3. Attach the server to the main loop context.

When the main app signals that a user is ready, I:

4. Call gst_rtsp_media_factory_set_launch() to establish the pipeline. This
could be done earlier.
5. Call gst_rtsp_media_mapping_add_factory().
6. Call gst_rtsp_media_factory_set_shared(factory, TRUE).

When a user disconnects, I:

7. Call gst_rtsp_media_mapping_remove_factory().

I never unref the server mapping since it is needed to add/remove factory
instances.

Is this organization and sequence reasonable? Or should I be breaking the
different pipelines into different executables?

Sometimes (without changing code) it fails to attach the server to the main
context (#3), which really confuses me. What are some reasons that might
happen?

Thank you for all guidance.

Chuck Crisler
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20130910/3ed99264/attachment.html>


More information about the gstreamer-devel mailing list