From d57eaa7e30a2faada712b60e75b7b2eb734cca3c Mon Sep 17 00:00:00 2001 From: wm4 Date: Sat, 21 Dec 2013 20:06:36 +0100 Subject: av_log: mp_msg conversion This is pretty nasty, because FFmpeg/Libav is yet another library with a global message callback. We do something with mutexes trying to get it done, but of course we can't actually solve this problem. If more than one library in a process use FFmpeg/Libav, only one of them will get log messages. --- player/main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'player') diff --git a/player/main.c b/player/main.c index db2794c1ad..b1d5d8163e 100644 --- a/player/main.c +++ b/player/main.c @@ -140,6 +140,7 @@ static MP_NORETURN void exit_player(struct MPContext *mpctx, #endif getch2_disable(); + uninit_libav(mpctx->global); if (how != EXIT_NONE) { const char *reason; @@ -310,8 +311,7 @@ static int mpv_main(int argc, char *argv[]) struct MPOpts *opts = mpctx->opts; mpctx->global->opts = opts; - - init_libav(); + init_libav(mpctx->global); GetCpuCaps(&gCpuCaps); screenshot_init(mpctx); mpctx->mixer = mixer_init(mpctx, mpctx->global); -- cgit v1.2.3