pipeline hangs on preroll - waiting in preroll for flush or PLAYING

mehdi semsarzadeh m.semsar at gmail.com
Mon Apr 3 20:09:18 UTC 2017


Thanks Sebastian for answering my question,

It is on NVIDIA TK1 platform and I have attached the snippet of source code.

Based on your comment I analysed the logs and can see that "stream-start"
signal has came into sink pad of the "h264enc1" but it has not gone out of
it's src.

*$ ag "h264enc1\:sink" mylog129.txt | ag "stream-start"*9165:0:05:26.048170281
22386   0x6f70c0 LOG                 GST_PADS
gstpad.c:4729:gst_pad_push_event_unchecked:<capsfilter38:src> sending event
0x9a804b40 (stream-start) to peerpad <h264enc1:sink>
9166:0:05:26.048188615 22386   0x6f70c0 DEBUG              GST_EVENT
gstpad.c:4985:gst_pad_send_event_unchecked:<h264enc1:sink> have event type
stream-start event: 0x9a804b40, time 99:99:99.999999999, seq-num 1853,
GstEventStreamStart, stream-id=(string)cfad77d0d1ad3cedc4628ed812655089,
flags=(GstStreamFlags)GST_STREAM_FLAG_NONE, group-id=(uint)7;
9173:0:05:26.048317863 22386   0x6f70c0 LOG                 GST_PADS
gstpad.c:4571:store_sticky_event:<h264enc1:sink> stored sticky event
stream-start


*$ ag "h264enc1\:src" mylog129.txt | ag "stream-start*
Nothing!


where as for h264enc0 I can see that this signal has passed both pads.

*$ ag "h264enc0\:sink" mylog129.txt | ag "stream-start"*
9056:0:05:26.046121139 22386 0xa0103b80 LOG                 GST_PADS
gstpad.c:4729:gst_pad_push_event_unchecked:<queue14:src> sending event
0x9a804b40 (stream-start) to peerpad <h264enc0:sink>
9058:0:05:26.046143722 22386 0xa0103b80 DEBUG              GST_EVENT
gstpad.c:4985:gst_pad_send_event_unchecked:<h264enc0:sink> have event type
stream-start event: 0x9a804b40, time 99:99:99.999999999, seq-num 1853,
GstEventStreamStart, stream-id=(string)cfad77d0d1ad3cedc4628ed812655089,
flags=(GstStreamFlags)GST_STREAM_FLAG_NONE, group-id=(uint)7;
9071:0:05:26.046345720 22386 0xa0103b80 LOG                 GST_PADS
gstpad.c:4571:store_sticky_event:<h264enc0:sink> stored sticky event
stream-start


*$ ag "h264enc0\:src" mylog129.txt | ag "stream-start"*
16181:0:05:27.768692738 22386 0x9a8038f0 LOG                 GST_PADS
gstpad.c:4571:store_sticky_event:<h264enc0:src> stored sticky event
stream-start
16186:0:05:27.768845903 22386 0x9a8038f0 LOG                 GST_PADS
gstpad.c:4729:gst_pad_push_event_unchecked:<h264enc0:src> sending event
0x9a804b40 (stream-start) to peerpad <capsfilter37:sink>
16220:0:05:27.769657310 22386 0x9a8038f0 DEBUG               GST_PADS
gstpad.c:3378:push_sticky:<h264enc0:src> event stream-start marked received
16239:0:05:27.769979056 22386 0x9a8038f0 DEBUG               GST_PADS
gstpad.c:3358:push_sticky:<h264enc0:src> event stream-start was already
received
16616:0:05:28.315091380 22386 0x9a8038f0 DEBUG               GST_PADS
gstpad.c:3358:push_sticky:<h264enc0:src> event stream-start was already
received
17242:0:05:28.331527267 22386 0x9a8038f0 DEBUG               GST_PADS
gstpad.c:3358:push_sticky:<h264enc0:src> event stream-start was already
received


I have set the GST_DEBUG to 7, so is there anyway to get more info form
encoder?
Thanks




On Fri, Mar 31, 2017 at 5:39 AM, Sebastian Dröge <sebastian at centricular.com>
wrote:

> On Tue, 2017-03-28 at 14:46 -0400, mehdi semsarzadeh wrote:
> > Dear All,
> > I am having the following pipeline I start and stop it multiple
> > times, and sometimes it fails to start after being stopped. It Hangs
> > on this log: "waiting in preroll for flush or PLAYING".
> > As I looked on gstreamer-devel forum the only reason that is
> > mentioned is the need of queue after tee, which is placed in this
> > pipeline.
> > I have attached the log file,
> > Thanks for your help
> >
> >
> >  appsrc name=videoSrc format=3 stream-type=0 ! video/x-raw,
> > format=(string)UYVY, width=1920, height=1080 ! nvvidconv
> > name=videoConvert0 ! video/x-raw(memory:NVMM), format=I420 ! tee
> > name=t ! queue ! omxh264enc name=h264enc0  ! video/x-h264, stream-
> > format=avc ! matroskamux streamable=true ! filesink name=videoPath0
> > location=vid_es_fifo_0 t. ! queue ! nvvidconv name=videoConvert1 !
> > video/x-raw(memory:NVMM), width=1920, height=1080 ! omxh264enc
> > name=h264enc1  ! video/x-h264, stream-format=avc ! matroskamux
> > streamable=true ! filesink name=videoPath1 location=vid_es_fifo_1
>
> According to the log, the problem here is that videoPath1 never gets
> any buffer. videoPath0 does. h264enc1 gets buffers but it doesn't look
> like it the muxer before it gets any buffers. So I'd expect there to be
> something wrong in the encoder element here, for which there is
> unfortunately not that much debug output in your log.
>
> Which platform is this on, which code is the omxh264enc based on?
>
> --
> Sebastian Dröge, Centricular Ltd · http://www.centricular.com
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
>
>


-- 
Mehdi Semsarzadeh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20170403/18b21354/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: scripttobesenttogstreamer.cpp
Type: text/x-c++src
Size: 4448 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20170403/18b21354/attachment-0001.cpp>


More information about the gstreamer-devel mailing list