Pipeline preroll problem

David Ing ding at panopto.com
Tue Apr 16 17:10:18 UTC 2019


I don't have an answer for you (I am not an expert) but I would suggest
using the function
*gst_debug_bin_to_dot_data(m_pPipeline, GST_DEBUG_GRAPH_SHOW_ALL)* to save
a dot file of the pipeline graph at the point where it gets stuck.  You can
use graphviz to convert the file to an SVG which will allow you to look at
the graph.

You might consider comparing the two graphs.

   1. After your problematic pipeline gets stuck (this probably happens
   during the attempted transition READY --> PAUSED).
   2. After your working pipeline successfully transitions to PAUSED.

You will probably notice a difference in the graphs.  Either there will be
a missing link in the first graph, or you will see that caps didn't get
negotiated properly ... or something like that.  It should provide a hint
about what is wrong.

On Tue, Apr 16, 2019 at 2:57 AM Duchassin Frederic <duchassin at sefram.fr>
wrote:

> Hello,
>
> This is a code snippets of my application :
>
> // Firstly, i link my scanning branch :
>
>       /* CreateGstreamer element */
>        m_pQueueTsParse = gst_element_factory_make("queue", "queueTsParse");
>        g_object_set(G_OBJECT(m_pQueueTsParse), "max-size-buffers",
> (guint)0, NULL);
>        g_object_set(G_OBJECT(m_pQueueTsParse), "max-size-bytes",
> (guint)0, NULL);
>        g_object_set(G_OBJECT(m_pQueueTsParse), "max-size-time",
> (guint64)0, NULL);
>
>        m_pTsparse = gst_element_factory_make("tsparse", "tsparse");
>        m_pFakesink = gst_element_factory_make("fakesink", "fakesink");
>        g_object_set(G_OBJECT(m_pFakesink), "async", false, NULL);
>
>        /*add gstelement to pipeline bin*/
>        gst_bin_add_many(GST_BIN(m_pPipeline), m_pQueueTsParse,
> m_pTsparse, m_pFakesink, NULL);
>
>        /*link element*/
>        gst_element_link_many(m_pTee, m_pQueueTsParse, m_pTsparse,
> m_pFakesink, NULL);
>
> // Secondly, i link my playing branch :
>
>        m_pDecodebin = gst_element_factory_make("decodebin", "decodebin1");
>        g_object_set(G_OBJECT(m_pDecodebin), "max-size-buffers", (guint)
> 0, NULL);
>        g_object_set(G_OBJECT(m_pDecodebin), "max-size-bytes", (guint)
> 100000000, NULL);
>        g_object_set(G_OBJECT(m_pDecodebin), "max-size-time", (guint64)
> 0, NULL);
>
>        m_pVideoqueue = gst_element_factory_make("queue", "queueVideo");
>        m_pVideosink = gst_element_factory_make("kmssink", "kmssink1");
>        g_object_set(G_OBJECT(m_pVideosink), "max-lateness", (gint64)
> 200000000, NULL);
>        //m_pVideosink = gst_element_factory_make("waylandsink",
> "waylandsink1");
>
>        m_pAudioqueue = gst_element_factory_make("queue", "queueAudio");
>        g_object_set(G_OBJECT(m_pAudioqueue), "max-size-time", (guint64)
> 10000000000, NULL);
>        g_object_set(G_OBJECT(m_pAudioqueue), "max-size-buffers",
> (guint64) 2000, NULL);
>
>        m_pAudioConvert = gst_element_factory_make("audioconvert",
> "audioconvert1");
>        m_pAudiosink = gst_element_factory_make("alsasink", "alsasink1");
>
>        //CB for dynamic link
>        g_signal_connect (m_pDecodebin, "autoplug-select", G_CALLBACK
> (cb_autoplug_select_decodebin), this);
>        g_signal_connect (m_pDecodebin, "pad-added", G_CALLBACK
> (cb_new_pad_decodebin), this);
>        g_signal_connect (m_pDecodebin, "element-added", G_CALLBACK
> (cb_element_added_decodebin), this);
>        g_signal_connect (m_pDecodebin, "autoplug-continue", G_CALLBACK
> (cb_autoplug_continue_decodebin), this);
>
>        /*add gstelement to pipeline bin*/
>        gst_bin_add_many(GST_BIN(m_pPipeline), m_pDecodebin,
> m_pVideoqueue, m_pVideosink, m_pAudioqueue, m_pAudioConvert,
> m_pAudiosink, NULL);
>
>        /*link element*/
>        gst_element_link_many(m_pTee, m_pDecodebin, NULL);
>        gst_element_link_many(m_pVideoqueue, m_pVideosink, NULL);
>        gst_element_link_many(m_pAudioqueue, m_pAudioConvert,
> m_pAudiosink, NULL);
>
>
> // And finally, i play the pipeline :
>
>       gst_element_set_state(m_pPipeline, GST_STATE_PLAYING);
>
>
> --> as a result, my pipeline is blocked in prerolling state.....and i
> don't really understand why.
>
> But If i link my scan branch after the playing branch, it magically works !
>
> Is somebody could explain me why ?
>
>
> BR
>
> Frédéric
>
>
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20190416/cab8f2d2/attachment.html>


More information about the gstreamer-devel mailing list