Skip to content

mpdparser: Align the bounds check used to determine if a timestamp is within a given segment with dashdemux

Joseph Newman requested to merge jn/gst-plugins-bad:mpdparser-fix-bounds into master

mpdparser: Align the bounds check used to determine if a timestamp is within a given segment with dashdemux

This commit fixes two issues caused by an incorrect bounds check. Firstly, when seeking backwards beyond the first segment in to a previous period, the check would still pass due to a lack of lower bound and the seek would incorrectly succeed, whereas a failure would've passed the seek to dashdemux where the correct period could be initialised.

Secondly, when ts = end_time, ts was taken not to belong to the period as the upper bound specified ts < end_time in the forward case. However, when the failure was subsequently returned and the seek handed off to gst_dash_demux_seek(), the same period was initialised as the bounds check used there to determine the period is ts <= end_time. This led to a situation where the seek couldn't be completed.

Merge request reports

Loading