From c06cb7c14578c9cb0dd6325714bd2b9e10adeaea Mon Sep 17 00:00:00 2001 From: David Corvoysier Date: Thu, 28 Jun 2012 11:29:55 +0200 Subject: [PATCH] isomp4: Try to seek upstream before processing seek push event When it receives a seek in push mode, the qtdemux should first try to push the event upstream, and only if upstream fails fall back to its own seek logic. --- gst/isomp4/qtdemux.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/gst/isomp4/qtdemux.c b/gst/isomp4/qtdemux.c index 7a80c52c45..3e6a7b3b91 100644 --- a/gst/isomp4/qtdemux.c +++ b/gst/isomp4/qtdemux.c @@ -1488,8 +1488,11 @@ gst_qtdemux_handle_src_event (GstPad * pad, GstObject * parent, } if (qtdemux->pullbased) { res = gst_qtdemux_do_seek (qtdemux, pad, event); - } else if (qtdemux->state == QTDEMUX_STATE_MOVIE && qtdemux->n_streams && - !qtdemux->fragmented) { + } else if (gst_pad_push_event (qtdemux->sinkpad, gst_event_ref (event))) { + GST_DEBUG_OBJECT (qtdemux, "Upstream successfully seeked"); + res = TRUE; + } else if (qtdemux->state == QTDEMUX_STATE_MOVIE && qtdemux->n_streams + && !qtdemux->fragmented) { res = gst_qtdemux_do_push_seek (qtdemux, pad, event); } else { GST_DEBUG_OBJECT (qtdemux,