Commit 83fe1b39 authored by Patricia Muscalu's avatar Patricia Muscalu Committed by Tim-Philipp Müller

Add source elements to the pipeline before activation

In plug_src we changed the element state before adding it to
the owner container. This prevented the pipeline from intercepting
a GST_STREAM_STATUS_TYPE_CREATE message from the pad in order
to assign a custom task pool.

Fixes #53
parent f11f127a
......@@ -2892,6 +2892,9 @@ plug_src (GstRTSPStream * stream, GstBin * bin, GstElement * src,
priv = stream->priv;
/* add src */
gst_bin_add (bin, src);
pad = gst_element_get_static_pad (src, "src");
if (priv->srcpad) {
/* block pad so src can't push data while it's not yet linked */
......@@ -2903,9 +2906,6 @@ plug_src (GstRTSPStream * stream, GstBin * bin, GstElement * src,
gst_element_set_locked_state (src, TRUE);
/* add src */
gst_bin_add (bin, src);
/* and link to the funnel */
selpad = gst_element_get_request_pad (funnel, "sink_%u");
gst_pad_link (pad, selpad);
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment