qtdemux: set need_segment after a second moov

stream.segment should be updated with the values of the current edit
list, also when a new `moov` is received. Unfortunately this was not
being the case because of an early return.

As a consequence of this bugs, no end of movie clipping was being
performed on the new moov and no segment event was being emitted.

When performing stream switching (e.g. in MSE) the new moov may have a
different edit list. This is often the case when switching between
baseline H.264 (which lacks B-frames) and more demanding profiles. For
this reason it's important to emit a new segment in order to be able
to get matching stream times.
This commit is contained in:
Alicia Boya García 2018-11-30 19:29:30 +01:00 committed by Sebastian Dröge
parent 26cc201c8a
commit 38b553dda7

View file

@ -12665,6 +12665,8 @@ qtdemux_expose_streams (GstQTDemux * qtdemux)
g_ptr_array_remove_range (qtdemux->old_streams,
0, qtdemux->old_streams->len);
qtdemux->need_segment = TRUE;
return GST_FLOW_OK;
}