diff --git a/ChangeLog b/ChangeLog index fe710888ce..b5d0a3dccd 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2008-12-17 Sebastian Dröge + + * gst/mxf/mxfdemux.c: (gst_mxf_demux_chain): + In push mode skip the run in again if we get buffers with + an offset before the run in. This can happen on seeks for example. + 2008-12-16 Stefan Kost * ext/celt/gstceltenc.c: diff --git a/gst/mxf/mxfdemux.c b/gst/mxf/mxfdemux.c index 4b1a3ba15c..17ec3a1841 100644 --- a/gst/mxf/mxfdemux.c +++ b/gst/mxf/mxfdemux.c @@ -554,11 +554,11 @@ gst_mxf_demux_choose_package (GstMXFDemux * demux) for (i = 0; i < demux->preface->content_storage->n_packages; i++) { if (demux->preface->content_storage->packages[i] && - MXF_IS_METADATA_MATERIAL_PACKAGE (demux->preface-> - content_storage->packages[i])) { + MXF_IS_METADATA_MATERIAL_PACKAGE (demux->preface->content_storage-> + packages[i])) { ret = - MXF_METADATA_GENERIC_PACKAGE (demux->preface-> - content_storage->packages[i]); + MXF_METADATA_GENERIC_PACKAGE (demux->preface->content_storage-> + packages[i]); break; } } @@ -1666,6 +1666,11 @@ gst_mxf_demux_chain (GstPad * pad, GstBuffer * inbuf) } gst_adapter_flush (demux->adapter, 1); } + } else if (demux->offset < demux->run_in) { + gst_adapter_flush (demux->adapter, + MIN (gst_adapter_available (demux->adapter), + demux->run_in - demux->offset)); + continue; } if (G_UNLIKELY (ret != GST_FLOW_OK))