appsrc does not receive EOS

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

appsrc does not receive EOS

Myzhar
Hi all,

I have a problem with my appsrc code and I cannot understand why.

My message callback receives each kind of message but EOS, so I cannot quit the mainLoop and stop the video recording.

To send the EOS signal I use the command:
GstFlowReturn eos_result = gst_app_src_end_of_stream( mAppSrc );

where mAppSrc is GstAppSrc*

This is the pipeline:

appsrc name=videosrc do-timestamp=0 is-live=1 format=time ! video/x-raw,format=I420,framerate=30/1,width=1280,height=720 ! queue ! videoscale ! video/x-raw,width=1280,height=720 ! queue ! videoconvert ! x264enc ! h264parse ! queue ! mp4mux ! queue ! filesink location=test.mp4 sync=false

Thank you
Walter
Walter Lucetti
www.myzhar.com
Reply | Threaded
Open this post in threaded view
|

Re: appsrc does not receive EOS

Tim Müller
On Tue, 2017-02-07 at 15:29 -0800, Myzhar wrote:

Hi,

> I have a problem with my appsrc code and I cannot understand why.
>
> My message callback receives each kind of message but EOS, so I
> cannot quit the mainLoop and stop the video recording.
>
> To send the EOS signal I use the command:
> GstFlowReturn eos_result = gst_app_src_end_of_stream( mAppSrc );
>
> where mAppSrc is GstAppSrc*
>
> This is the pipeline:
>  (snip)

Probably best to look at the debug log to see where the EOS event gets
stuck.

Just before you do the gst_app_src_end_of_stream(), do

gst_debug_set_default_threshold(GST_LEVEL_LOG);

which will activate debug logging (to stderr). Then grep for 'eos' in
the output to see which elements it goes through.

 ... 2>&1 | grep -i eos


Also make sure that you keep the pipeline in PLAYING state, otherwise
the sink will not post the EOS message on the bus.

Cheers
 -Tim
--
Tim Müller, Centricular Ltd - http://www.centricular.com
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel