]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/4xm.c
lavr: correct the documentation for the ff_audio_resample() return value
[ffmpeg] / libavcodec / 4xm.c
index 8cc5592c730d87eb99fb03772bb9d8fec2c9a70f..38fc2f2e64fd740cc8743e3a6f9bf8220cd51c87 100644 (file)
@@ -240,15 +240,18 @@ static void idct(DCTELEM block[64])
 
 static av_cold void init_vlcs(FourXContext *f)
 {
-    static VLC_TYPE table[8][32][2];
-    int i;
-
-    for (i = 0; i < 8; i++) {
-        block_type_vlc[0][i].table           = table[i];
-        block_type_vlc[0][i].table_allocated = 32;
-        init_vlc(&block_type_vlc[0][i], BLOCK_TYPE_VLC_BITS, 7,
-                 &block_type_tab[0][i][0][1], 2, 1,
-                 &block_type_tab[0][i][0][0], 2, 1, INIT_VLC_USE_NEW_STATIC);
+    static VLC_TYPE table[2][4][32][2];
+    int i, j;
+
+    for (i = 0; i < 2; i++) {
+        for (j = 0; j < 4; j++) {
+            block_type_vlc[i][j].table           = table[i][j];
+            block_type_vlc[i][j].table_allocated = 32;
+            init_vlc(&block_type_vlc[i][j], BLOCK_TYPE_VLC_BITS, 7,
+                     &block_type_tab[i][j][0][1], 2, 1,
+                     &block_type_tab[i][j][0][0], 2, 1,
+                     INIT_VLC_USE_NEW_STATIC);
+        }
     }
 }
 
@@ -897,9 +900,9 @@ static av_cold int decode_init(AVCodecContext *avctx)
     init_vlcs(f);
 
     if (f->version > 2)
-        avctx->pix_fmt = PIX_FMT_RGB565;
+        avctx->pix_fmt = AV_PIX_FMT_RGB565;
     else
-        avctx->pix_fmt = PIX_FMT_BGR555;
+        avctx->pix_fmt = AV_PIX_FMT_BGR555;
 
     return 0;
 }
@@ -928,7 +931,7 @@ static av_cold int decode_end(AVCodecContext *avctx)
 AVCodec ff_fourxm_decoder = {
     .name           = "4xm",
     .type           = AVMEDIA_TYPE_VIDEO,
-    .id             = CODEC_ID_4XM,
+    .id             = AV_CODEC_ID_4XM,
     .priv_data_size = sizeof(FourXContext),
     .init           = decode_init,
     .close          = decode_end,