appsrc does not receive EOS

Tim Müller tim at centricular.com
Mon Feb 13 09:39:32 UTC 2017


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


More information about the gstreamer-devel mailing list