summaryrefslogtreecommitdiffstats
path: root/av_log.c
diff options
context:
space:
mode:
Diffstat (limited to 'av_log.c')
-rw-r--r--av_log.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/av_log.c b/av_log.c
index 622cb1193a..376144800a 100644
--- a/av_log.c
+++ b/av_log.c
@@ -105,7 +105,13 @@ static void mp_msg_av_log_callback(void *ptr, int level, const char *fmt,
mp_msg_va(type, mp_level, fmt, vl);
}
-void set_av_log_callback(void)
+void init_libav(void)
{
- av_log_set_callback(mp_msg_av_log_callback);
+ av_log_set_callback(mp_msg_av_log_callback);
+#ifdef CONFIG_FFMPEG
+ avcodec_init();
+ avcodec_register_all();
+
+ av_register_all();
+#endif
}