diff options
author | wm4 <wm4@nowhere> | 2013-12-21 19:06:37 +0100 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2013-12-21 20:50:13 +0100 |
commit | 3846fc758789711347c0b11f87736b27fc6210a0 (patch) | |
tree | e9b01445291326f0a026e0b002d78f1487d781b2 /player | |
parent | 92f9b514263d8becf670c19567826bd288595fe7 (diff) | |
download | mpv-3846fc758789711347c0b11f87736b27fc6210a0.tar.bz2 mpv-3846fc758789711347c0b11f87736b27fc6210a0.tar.xz |
sub/osd: mp_msg conversions
Diffstat (limited to 'player')
-rw-r--r-- | player/core.h | 1 | ||||
-rw-r--r-- | player/loadfile.c | 6 | ||||
-rw-r--r-- | player/main.c | 5 | ||||
-rw-r--r-- | player/sub.c | 2 |
4 files changed, 9 insertions, 5 deletions
diff --git a/player/core.h b/player/core.h index a344b92ac3..9fe52b690b 100644 --- a/player/core.h +++ b/player/core.h @@ -313,6 +313,7 @@ typedef struct MPContext { */ struct ass_renderer *ass_renderer; struct ass_library *ass_library; + struct mp_log *ass_log; int last_dvb_step; diff --git a/player/loadfile.c b/player/loadfile.c index 1bee60119a..8ca793941f 100644 --- a/player/loadfile.c +++ b/player/loadfile.c @@ -842,8 +842,10 @@ static void init_sub_renderer(struct MPContext *mpctx) assert(!mpctx->ass_renderer); mpctx->ass_renderer = ass_renderer_init(mpctx->ass_library); - if (mpctx->ass_renderer) - mp_ass_configure_fonts(mpctx->ass_renderer, mpctx->opts->sub_text_style); + if (mpctx->ass_renderer) { + mp_ass_configure_fonts(mpctx->ass_renderer, mpctx->opts->sub_text_style, + mpctx->global, mpctx->ass_log); + } mpctx->initialized_flags |= INITIALIZED_LIBASS; #endif } diff --git a/player/main.c b/player/main.c index 0cf0a1a447..7ca64ed664 100644 --- a/player/main.c +++ b/player/main.c @@ -399,13 +399,14 @@ static int mpv_main(int argc, char *argv[]) getch2_enable(); #if HAVE_LIBASS - mpctx->ass_library = mp_ass_init(opts); + mpctx->ass_log = mp_log_new(mpctx, mpctx->global->log, "!libass"); + mpctx->ass_library = mp_ass_init(mpctx->global, mpctx->ass_log); #else MP_WARN(mpctx, "Compiled without libass.\n"); MP_WARN(mpctx, "There will be no OSD and no text subtitles.\n"); #endif - mpctx->osd = osd_create(opts); + mpctx->osd = osd_create(mpctx->global); if (opts->force_vo) { opts->fixed_vo = 1; diff --git a/player/sub.c b/player/sub.c index ceef81b319..ba8f7d70eb 100644 --- a/player/sub.c +++ b/player/sub.c @@ -185,7 +185,7 @@ void reinit_subs(struct MPContext *mpctx) if (!sh->sub->dec_sub) { assert(!mpctx->d_sub); - sh->sub->dec_sub = sub_create(opts); + sh->sub->dec_sub = sub_create(mpctx->global); } assert(!mpctx->d_sub || sh->sub->dec_sub == mpctx->d_sub); |