mpv/player
Dudemanguy fa89082f2e sub: avoid unneeded calls to is_animated
4e5d996c3a added this as part of a series
of patches written to avoid wasteful sub redraws when playing a still
image with subs. The is_animated special case was specifically for ASS
subtitles that have animations/effects and would need repeated redraws
in the still image case. This check was done unconditionally for all ASS
subtitles, but for very big ASS subtitles, this text parsing can get a
bit expensive.

Because this function call is only ever needed for the weird edge case
of ASS subtitles over a still image, some additional logic can be added
to avoid calling is_animated in the vast majority of cases. The animated
field in demux_packet can be changed to a tristate instead where -1
indicates "unknown" (the default state). In update_subtitle, we can look
at the current state of the video tracks and decide whether or not it is
neccesary to perform is_animated and pass that knowledge to sd_ass
before any subtitle packets are decoded and thus save us from doing this
potentially expensive call.
2024-06-04 12:29:13 +00:00
..
javascript console.lua: don't convert integers for mp.input to string 2024-05-12 23:13:48 +02:00
lua osc.lua: fix lint warnings 2024-06-02 22:26:00 +02:00
audio.c player: put speed adjustment back into playing_audio_pts 2024-05-29 13:48:40 +00:00
client.c player/client: fix typo in description of MPV_ERROR_UNINITIALIZED 2024-05-08 18:52:40 +02:00
client.h
command.c command: simplify printing floats as integers 2024-06-03 15:14:40 +02:00
command.h options: add --input-commands option 2024-03-21 14:48:53 +00:00
configfiles.c player: replace get_current_time with get_playback_time in some spots 2024-05-29 13:48:40 +00:00
core.h player/playloop: remove now unused get_percent_pos() 2024-06-03 19:16:35 +02:00
external_files.c misc/language: move mp_guess_lang_from_filename() here 2024-05-10 01:22:31 +02:00
external_files.h misc/language: move mp_guess_lang_from_filename() here 2024-05-10 01:22:31 +02:00
javascript.c osdep/dirent: add implementation for Windows SDK build 2024-05-06 22:01:17 +02:00
loadfile.c player/loadfile: match language and subcodes 2024-05-09 17:12:55 +02:00
lua.c select.lua: add this script 2024-05-12 23:13:48 +02:00
main.c various: fix indentation 2024-05-07 11:23:08 +02:00
meson.build meson: generate .com in the same place as the .exe if possible 2023-11-27 18:42:19 +00:00
misc.c win32: quantize taskbar playback position into uint8 range 2024-06-03 19:16:35 +02:00
osd.c osd: don't use get_percent_pos function 2024-06-03 15:14:40 +02:00
playloop.c player/playloop: remove now unused get_percent_pos() 2024-06-03 19:16:35 +02:00
screenshot.c image_writer: fix TOCTOU in screenshot filename generation 2024-03-19 19:30:27 +01:00
screenshot.h
scripting.c select.lua: add this script 2024-05-12 23:13:48 +02:00
sub.c sub: avoid unneeded calls to is_animated 2024-06-04 12:29:13 +00:00
video.c player: put speed adjustment back into playing_audio_pts 2024-05-29 13:48:40 +00:00