1
0
mirror of https://github.com/mpv-player/mpv synced 2024-12-28 10:02:17 +00:00
mpv/sub
Uoti Urpala 06e3dc8eba timeline: subs: keep subtitle tracks in source time
Timeline handling converted the pts values from demuxed subtitles to
timeline scale. Change the code to do most subtitle handling in
original subtitle source pts, and instead convert current playback
timeline pts to those units when deciding which subtitle to show.
The main functionality changes are that now demuxed subtitles which
overlap chapter boundaries are handled correctly (at least for libass
subtitles), and external subtitles are assumed to use same pts scale
as current source (this needs improvements later).

Before, a video subtitle that had a duration continuing past the end
of the chapter would continue to be shown for the original duration,
even if the chapter ended and playback switched to a position in the
source where the subtitle shouldn't exist. Now, the subtitle will
correctly end.

Before, external subtitle files were interpreted as specifying pts
values in timeline scale. Now, they're interpreted as specifying pts
values in source file time scale, for _every_ source file. This is
probably more likely to be what the user wants for the "main" source
file in case there is one, but almost certainly not quite right for
multiple source files where the same subs could be shown over
different scenes. If the user wants them to match some main source
file, it's probably still better to have incorrect extra subs for
video from some files than to have every subtitle appearing at the
wrong time. The new code makes it easier to change the interpretation
of the subtitle times, and some configurability should be added in
the future.
2012-03-25 22:30:37 +03:00
..
ass_mp.c options: move libass-related options to struct 2011-09-03 14:26:14 +03:00
ass_mp.h options: move libass-related options to struct 2011-09-03 14:26:14 +03:00
av_sub.c Update Libav API uses 2012-02-01 22:46:27 +02:00
av_sub.h
dec_sub.c
dec_sub.h
find_sub.c
find_subfiles.c windows support: unicode filenames 2012-03-09 20:48:54 +02:00
find_subfiles.h subs: options: add -sub-paths 2011-04-20 04:22:52 +03:00
font_load_ft.c cleanup: shut up more warnings 2011-05-06 18:33:16 +03:00
font_load.c windows support: unicode filenames 2012-03-09 20:48:54 +02:00
font_load.h
osd_font.h
sd_ass.c sd_ass.c: set event->Style to fix --ass-styles 2011-09-23 13:57:11 +03:00
sd.h
spudec.c build: switch to libavutil bswap.h and intreadwrite.h 2012-02-01 22:46:27 +02:00
spudec.h
sub_cc.c
sub_cc.h
sub.c core: allocate OSD text buffers dynamically 2011-08-09 03:28:58 +03:00
sub.h timeline: subs: keep subtitle tracks in source time 2012-03-25 22:30:37 +03:00
subassconvert.c subassconvert: handle "\r\n" line ends 2011-09-02 12:22:15 +03:00
subassconvert.h
subreader.c subreader.c: don't run FriBiDi code if using libass 2011-09-23 14:43:53 +03:00
subreader.h find_subfiles: move sub_filenames() here 2011-04-20 04:22:52 +03:00
unrar_exec.c
unrar_exec.h
vobsub.c cleanup: Silence compilation warnings on MinGW-w64 2012-03-01 00:22:30 +02:00
vobsub.h options: change -alang and -slang to use string list type 2011-04-20 04:22:42 +03:00