changeset 10262:0eed6587903b libavcodec

Replace last use of INIT_VLC_USE_STATIC by INIT_VLC_USE_NEW_STATIC in svq1dec
author reimar
date Thu, 24 Sep 2009 15:12:05 +0000
parents 64ee90bc6c31
children fd9dfd5aa5e9
files svq1dec.c
diffstat 1 files changed, 11 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/svq1dec.c	Thu Sep 24 11:04:46 2009 +0000
+++ b/svq1dec.c	Thu Sep 24 15:12:05 2009 +0000
@@ -768,6 +768,7 @@
 {
     MpegEncContext *s = avctx->priv_data;
     int i;
+    int offset = 0;
 
     MPV_decode_defaults(s);
 
@@ -789,12 +790,20 @@
         &mvtab[0][0], 2, 1, 176);
 
     for (i = 0; i < 6; i++) {
+        static const uint8_t sizes[2][6] = {{14, 10, 14, 18, 16, 18}, {10, 10, 14, 14, 14, 16}};
+        static VLC_TYPE table[168][2];
+        svq1_intra_multistage[i].table = &table[offset];
+        svq1_intra_multistage[i].table_allocated = sizes[0][i];
+        offset += sizes[0][i];
         init_vlc(&svq1_intra_multistage[i], 3, 8,
             &ff_svq1_intra_multistage_vlc[i][0][1], 2, 1,
-            &ff_svq1_intra_multistage_vlc[i][0][0], 2, 1, INIT_VLC_USE_STATIC);
+            &ff_svq1_intra_multistage_vlc[i][0][0], 2, 1, INIT_VLC_USE_NEW_STATIC);
+        svq1_inter_multistage[i].table = &table[offset];
+        svq1_inter_multistage[i].table_allocated = sizes[1][i];
+        offset += sizes[1][i];
         init_vlc(&svq1_inter_multistage[i], 3, 8,
             &ff_svq1_inter_multistage_vlc[i][0][1], 2, 1,
-            &ff_svq1_inter_multistage_vlc[i][0][0], 2, 1, INIT_VLC_USE_STATIC);
+            &ff_svq1_inter_multistage_vlc[i][0][0], 2, 1, INIT_VLC_USE_NEW_STATIC);
     }
 
     INIT_VLC_STATIC(&svq1_intra_mean, 8, 256,