summaryrefslogtreecommitdiffstats
path: root/player/sub.c
diff options
context:
space:
mode:
Diffstat (limited to 'player/sub.c')
-rw-r--r--player/sub.c13
1 files changed, 3 insertions, 10 deletions
diff --git a/player/sub.c b/player/sub.c
index 548e7b22d9..384339c9e2 100644
--- a/player/sub.c
+++ b/player/sub.c
@@ -109,6 +109,9 @@ static void init_sub_renderer(struct MPContext *mpctx)
ass_set_style_overrides(mpctx->ass_library, opts->ass_force_style_list);
mpctx->ass_renderer = ass_renderer_init(mpctx->ass_library);
+
+ mp_ass_configure_fonts(mpctx->ass_renderer, opts->sub_text_style,
+ mpctx->global, mpctx->ass_log);
}
void uninit_sub_renderer(struct MPContext *mpctx)
@@ -126,9 +129,6 @@ void uninit_sub_renderer(struct MPContext *mpctx)
static void init_sub_renderer(struct MPContext *mpctx) {}
void uninit_sub_renderer(struct MPContext *mpctx) {}
-static void mp_ass_configure_fonts(struct ass_renderer *a, struct osd_style_opts *b,
- struct mpv_global *c, struct mp_log *d) {}
-
#endif
static void reset_subtitles(struct MPContext *mpctx, int order)
@@ -310,13 +310,6 @@ static void reinit_subdec(struct MPContext *mpctx, struct track *track,
&mpctx->ass_lock);
sub_init_from_sh(dec_sub, track->stream);
- if (mpctx->ass_renderer) {
- pthread_mutex_lock(&mpctx->ass_lock);
- mp_ass_configure_fonts(mpctx->ass_renderer, opts->sub_text_style,
- mpctx->global, mpctx->ass_log);
- pthread_mutex_unlock(&mpctx->ass_lock);
- }
-
// Don't do this if the file has video/audio streams. Don't do it even
// if it has only sub streams, because reading packets will change the
// demuxer position.