From bccfc679b5bf00dbbdce2f205632a76101e65a10 Mon Sep 17 00:00:00 2001 From: Vincent Penquerc'h Date: Thu, 14 Feb 2013 15:59:51 +0000 Subject: [PATCH] encodebin: activate ghost pad after creating it This ensures the ghost pad will not stay in flushing mode when it receives a flush stop event, and generally behave badly. This fixes at least one case of a dynamic decodebin2 + encodebin pipeline finding a source that has not prerolled when it should have been (due to the ghostpad staying in flushing mode). --- gst/encoding/gstencodebin.c | 1 + 1 file changed, 1 insertion(+) diff --git a/gst/encoding/gstencodebin.c b/gst/encoding/gstencodebin.c index 96bb4b9204..dd49c430f8 100644 --- a/gst/encoding/gstencodebin.c +++ b/gst/encoding/gstencodebin.c @@ -494,6 +494,7 @@ gst_encode_bin_init (GstEncodeBin * encode_bin) tmpl = gst_static_pad_template_get (&muxer_src_template); encode_bin->srcpad = gst_ghost_pad_new_no_target_from_template ("src", tmpl); gst_object_unref (tmpl); + gst_pad_set_active (encode_bin->srcpad, TRUE); gst_element_add_pad (GST_ELEMENT_CAST (encode_bin), encode_bin->srcpad); }