mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 11:41:09 +00:00
dash: Fix computing repeat_index
when seeking in stream with a start !=0 on the first fragment
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/3159>
This commit is contained in:
parent
f7abd81a45
commit
8a9821e805
2 changed files with 8 additions and 2 deletions
|
@ -1705,7 +1705,10 @@ gst_mpd_client_stream_seek (GstMPDClient * client, GstActiveStream * stream,
|
|||
GstClockTime chunk_time;
|
||||
|
||||
selectedChunk = segment;
|
||||
repeat_index = (ts - segment->start) / segment->duration;
|
||||
repeat_index =
|
||||
((ts - segment->start) +
|
||||
((GstMediaSegment *) stream->segments->pdata[0])->start) /
|
||||
segment->duration;
|
||||
|
||||
chunk_time = segment->start + segment->duration * repeat_index;
|
||||
|
||||
|
|
|
@ -1707,7 +1707,10 @@ gst_mpd_client2_stream_seek (GstMPDClient2 * client, GstActiveStream * stream,
|
|||
GstClockTime chunk_time;
|
||||
|
||||
selectedChunk = segment;
|
||||
repeat_index = (ts - segment->start) / segment->duration;
|
||||
repeat_index =
|
||||
((ts - segment->start) +
|
||||
((GstMediaSegment *) stream->segments->pdata[0])->start) /
|
||||
segment->duration;
|
||||
|
||||
chunk_time = segment->start + segment->duration * repeat_index;
|
||||
|
||||
|
|
Loading…
Reference in a new issue