options: add UPDATE_SUB_HARD flag to sub-ass-override

The other options that have to do with ass styles also uses this flag.
It's needed since we have to destroy the ass objects and reinit them.
It's a bit incomplete since it will technically only properly work when
paused (while playing, the current subtitle gets discarded). That fix is
in the next commit.
This commit is contained in:
Dudemanguy 2023-10-20 11:13:43 -05:00
parent 6f8d98f812
commit 90170c1100
1 changed files with 2 additions and 1 deletions

View File

@ -315,7 +315,8 @@ const struct m_sub_options mp_subtitle_sub_opts = {
{"simple", 0}, {"complex", 1})},
{"sub-ass-justify", OPT_BOOL(ass_justify)},
{"sub-ass-override", OPT_CHOICE(ass_style_override,
{"no", 0}, {"yes", 1}, {"force", 3}, {"scale", 4}, {"strip", 5})},
{"no", 0}, {"yes", 1}, {"force", 3}, {"scale", 4}, {"strip", 5}),
.flags = UPDATE_SUB_HARD},
{"sub-scale-by-window", OPT_BOOL(sub_scale_by_window)},
{"sub-scale-with-window", OPT_BOOL(sub_scale_with_window)},
{"sub-ass-scale-with-window", OPT_BOOL(ass_scale_with_window)},