mpv/sub
wm4 6d9cb89333 sub: clear subtitle list when crossing timeline boundary
When crossing timeline boundaries (such as switching to a new segment or
chapter with ordered chapters), clear the internal text subtitle list.
This breaks the sub-seek command, but is otherwise not too harmful.
Fixes Sub-OC-test-final7.mkv. (The internal text subtitle list is
basically a cache to make subtitles show up at the right time when
seeking back.)

I suspect this was caused by 76fcef61. The sample file times subtitles
slightly before the video frame when it should show up. This is to avoid
problems with subtitles showing up a frame later than intended. It also
means that a subtitle which is supposed to show up on the start of a
timeline part boundary actually might first be shown in a different
part. Since we now manipulate the packet timestamps, instead of
manipulating timestamps after the subtitle decoder, this means this
subtitle event would have 2 timestamps, which our code of course does
not handle.

If the two parts come one after another, this would actually work (since
the subtitle would have the same timestamps in the old and new part),
but it breaks if the new part (which follows the old part in the
physical file) is has a completely different start time in the timeline.

Essentially, the trick used to time subtitles correctly is incompatible
with the way we cache subtitles (to make them survive seeks).

The simple solution is just clearing the cached subtitles when crossing
chapter boundaries.
2015-12-25 12:28:01 +01:00
..
ass_mp.c sub: remove unused function, move another one 2015-11-29 17:55:02 +01:00
ass_mp.h sub: remove unused function, move another one 2015-11-29 17:55:02 +01:00
dec_sub.c dec_sub: avoid segfault on sub_init_decoder failure 2015-12-22 13:00:05 +01:00
dec_sub.h sub: clear subtitle list when crossing timeline boundary 2015-12-25 12:28:01 +01:00
draw_bmp.c sub: use macros to remove code duplication 2015-12-24 17:32:10 +01:00
draw_bmp.h csputils: get rid of mp_csp_details 2015-01-06 16:50:58 +01:00
img_convert.c Update license headers 2015-04-13 12:10:01 +02:00
img_convert.h
lavc_conv.c lavc_conv: fix invalid write 2015-12-19 21:21:36 +01:00
osd.c video: switch from using display aspect to sample aspect 2015-12-19 20:45:36 +01:00
osd.h osd: use the same ASS_Renderer for OSD text and progbar 2015-11-28 19:24:31 +01:00
osd_dummy.c
osd_font.otf
osd_libass.c osd: fix and cleanup font style management 2015-11-29 17:55:02 +01:00
osd_state.h osd: use the same ASS_Renderer for OSD text and progbar 2015-11-28 19:24:31 +01:00
sd.h sub: remove unused video width/height headers 2015-12-18 03:59:52 +01:00
sd_ass.c sub: clear subtitle list when crossing timeline boundary 2015-12-25 12:28:01 +01:00
sd_lavc.c video: switch from using display aspect to sample aspect 2015-12-19 20:45:36 +01:00