diff options
author | Sebastian Dröge <sebastian.droege@collabora.co.uk> | 2013-05-06 15:47:34 +0200 |
---|---|---|
committer | Sebastian Dröge <sebastian.droege@collabora.co.uk> | 2013-05-06 15:49:00 +0200 |
commit | b719dd9f89e8b00c28262a6a4a73cb83720ea0e4 (patch) | |
tree | e120b5ea855f65549b5b7140402e81c8f77987d7 | |
parent | 1a83c7a36a7e4c7b882a68805803aec000ea4a37 (diff) |
decodebin: Expose pads when they receive EOS before any buffers
Stops decodebin from waiting forever to expose a pad if there
is never data on it.
https://bugzilla.gnome.org/show_bug.cgi?id=691072
-rw-r--r-- | gst/playback/gstdecodebin2.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/gst/playback/gstdecodebin2.c b/gst/playback/gstdecodebin2.c index 0e5e1fc90..78da6d62a 100644 --- a/gst/playback/gstdecodebin2.c +++ b/gst/playback/gstdecodebin2.c @@ -4083,9 +4083,11 @@ source_pad_blocked_cb (GstPad * pad, GstPadProbeInfo * info, gpointer user_data) return GST_PAD_PROBE_PASS; } - if (GST_EVENT_IS_STICKY (event)) { + if (GST_EVENT_IS_STICKY (event) && GST_EVENT_TYPE (event) != GST_EVENT_EOS) { /* manually push sticky events to ghost pad to avoid exposing pads - * that don't have the sticky events */ + * that don't have the sticky events. Handle EOS separately as we + * want to block the pad on it if we didn't get any buffers before + * EOS and expose the pad then. */ gst_pad_push_event (GST_PAD_CAST (dpad), gst_event_ref (event)); /* let the sticky events pass */ |