changeset 6509:762d3cf8da36

init libavcodec
author arpi
date Sat, 22 Jun 2002 23:57:45 +0000
parents 3dcf7fe14bd3
children 4f23a6c3cda4
files libmpcodecs/vd_svq1.c
diffstat 1 files changed, 11 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/libmpcodecs/vd_svq1.c	Sat Jun 22 23:49:50 2002 +0000
+++ b/libmpcodecs/vd_svq1.c	Sat Jun 22 23:57:45 2002 +0000
@@ -24,8 +24,19 @@
     return CONTROL_UNKNOWN;
 }
 
+extern int avcodec_inited;
+
 // init driver
 static int init(sh_video_t *sh){
+
+#ifdef USE_LIBAVCODEC
+    if(!avcodec_inited){
+      avcodec_init();
+      avcodec_register_all();
+      avcodec_inited=1;
+    }
+#endif
+
     if(!mpcodecs_config_vo(sh,sh->disp_w,sh->disp_h,IMGFMT_YVU9)) return 0;
 
     sh->context=malloc(sizeof(svq1_t));