For each period, media presentation is the relative to the
period-start time. So SIDX seek position should be target seek
position minus period-start. Also, if presentationTimeOffset
is defined, the value should be compensated
https://bugzilla.gnome.org/show_bug.cgi?id=780397
forward, flags, ts, final_ts);
if (gst_mpd_client_has_isoff_ondemand_profile (dashdemux->client)) {
+ GstClockTime period_start, offset;
+
+ period_start = gst_mpd_parser_get_period_start_time (dashdemux->client);
+ offset =
+ gst_mpd_parser_get_stream_presentation_offset (dashdemux->client,
+ dashstream->index);
+
+ if (G_UNLIKELY (ts < period_start))
+ ts = offset;
+ else
+ ts += offset - period_start;
+
if (last_index != dashstream->active_stream->segment_index ||
last_repeat != dashstream->active_stream->segment_repeat_index) {
GST_LOG_OBJECT (stream->pad,