mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-03-28 11:55:39 +00:00
tests: add example of reusable pipelines
This commit is contained in:
parent
00291e5285
commit
b614319622
1 changed files with 8 additions and 0 deletions
|
@ -34,6 +34,12 @@ timeout (GstRTSPServer * server, gboolean ignored)
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
static void
|
||||
media_configure (GstRTSPMediaFactory * factory, GstRTSPMedia * media)
|
||||
{
|
||||
gst_rtsp_media_set_reusable (media, TRUE);
|
||||
}
|
||||
|
||||
int
|
||||
main (int argc, char *argv[])
|
||||
{
|
||||
|
@ -70,6 +76,8 @@ main (int argc, char *argv[])
|
|||
argv[1]);
|
||||
gst_rtsp_media_factory_set_launch (factory, str);
|
||||
gst_rtsp_media_factory_set_shared (factory, TRUE);
|
||||
g_signal_connect (factory, "media-configure", (GCallback) media_configure,
|
||||
NULL);
|
||||
g_free (str);
|
||||
|
||||
/* attach the test factory to the /test url */
|
||||
|
|
Loading…
Reference in a new issue