How to wait for the pipeline destruction

Sebastian Dröge sebastian at centricular.com
Fri Jan 3 08:38:30 PST 2014


On Fr, 2014-01-03 at 17:35 +0100, Elio Francesconi wrote:
> Hi all,
> this is my code to close a pipeline:
>         if(pPipeline!=NULL)
>         {
>             gst_element_set_state(pPipeline, GST_STATE_NULL);
>             gst_object_unref(pPipeline);
>             pPipeline = NULL;
>         }
> 
> I noticed the pipeline is closed correctly but I need to wait for the pipeline destruction. Which is the best way to do that?

Send an EOS event to the pipeline with gst_element_send_event(), wait
for the EOS message to arrive on the bus.

-- 
Sebastian Dröge, Centricular Ltd - http://www.centricular.com
Expertise, Straight from the Source
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 966 bytes
Desc: This is a digitally signed message part
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20140103/a51bca73/attachment.pgp>


More information about the gstreamer-devel mailing list