This is an automated email from the git hooks/post-receive script. Git pushed a commit to branch master in repository ffmpeg.
commit 729de963f9063efb6d6cb04e8a29dccc809155b3 Author: Kacper Michajłow <[email protected]> AuthorDate: Sat Oct 17 01:37:54 2026 +0200 Commit: Kacper Michajłow <[email protected]> CommitDate: Wed Nov 4 02:28:56 2026 +0000 avformat/hls: keep the subtitle cues still shown at the seek target Discard the cues of a subtitle playlist by their end time when seeking or when the playlist is enabled during playback, so a cue that is on screen at the target is delivered instead of the next one starting after it. Signed-off-by: Kacper Michajłow <[email protected]> --- libavformat/hls.c | 7 +++++++ tests/ref/fate/hls-webvtt-seek-demux | 6 ++++++ 2 files changed, 13 insertions(+) diff --git a/libavformat/hls.c b/libavformat/hls.c index 8cc3511e5a..4c50cc65d1 100644 --- a/libavformat/hls.c +++ b/libavformat/hls.c @@ -3106,6 +3106,13 @@ retry: pls->seek_timestamp = AV_NOPTS_VALUE; break; } + /* a cue still shown at the target is delivered, the cues + * after it may still have ended before the target */ + if (pls->is_subtitle && pls->pkt->duration > 0 && + av_rescale_q_rnd(pls->pkt->dts + pls->pkt->duration, tb, + AV_TIME_BASE_Q, AV_ROUND_DOWN) > + pls->seek_timestamp) + break; } av_packet_unref(pls->pkt); } diff --git a/tests/ref/fate/hls-webvtt-seek-demux b/tests/ref/fate/hls-webvtt-seek-demux index b2742c8c66..5de0423fa5 100644 --- a/tests/ref/fate/hls-webvtt-seek-demux +++ b/tests/ref/fate/hls-webvtt-seek-demux @@ -1,4 +1,10 @@ WEBVTT +00:11.000 --> 00:14.500 line:1 +long + +00:11.000 --> 00:14.500 line:1 +long + 00:14.500 --> 00:15.500 third -- To stop receiving notification emails like this one, please contact [email protected]. _______________________________________________ ffmpeg-cvslog mailing list -- [email protected] To unsubscribe send an email to [email protected]
