[FFmpeg-cvslog] r13947 - in trunk/libavcodec: ac3enc.c atrac3data.h cookdata.h dcahuff.h dpcm.c eval.c faandct.c flac.c imcdata.h mpeg12decdata.h mpegaudiodata.c mpegaudiodata.h opt.c qdm2.c qdm2data.h qpeg.c ra144.h ratecontrol.c snow.c sonic.c truemotion1.c truemotion1data.h truespeech_data.h tta.c ulti.c utils.c vmdav.c vorbis.h vorbis_data.c vorbis_enc.c vp3data.h wnv1.c

stefang subversion
Tue Jun 24 22:01:31 CEST 2008


Author: stefang
Date: Tue Jun 24 22:01:31 2008
New Revision: 13947

Log:
mark read-only data as const



Modified:
   trunk/libavcodec/ac3enc.c
   trunk/libavcodec/atrac3data.h
   trunk/libavcodec/cookdata.h
   trunk/libavcodec/dcahuff.h
   trunk/libavcodec/dpcm.c
   trunk/libavcodec/eval.c
   trunk/libavcodec/faandct.c
   trunk/libavcodec/flac.c
   trunk/libavcodec/imcdata.h
   trunk/libavcodec/mpeg12decdata.h
   trunk/libavcodec/mpegaudiodata.c
   trunk/libavcodec/mpegaudiodata.h
   trunk/libavcodec/opt.c
   trunk/libavcodec/qdm2.c
   trunk/libavcodec/qdm2data.h
   trunk/libavcodec/qpeg.c
   trunk/libavcodec/ra144.h
   trunk/libavcodec/ratecontrol.c
   trunk/libavcodec/snow.c
   trunk/libavcodec/sonic.c
   trunk/libavcodec/truemotion1.c
   trunk/libavcodec/truemotion1data.h
   trunk/libavcodec/truespeech_data.h
   trunk/libavcodec/tta.c
   trunk/libavcodec/ulti.c
   trunk/libavcodec/utils.c
   trunk/libavcodec/vmdav.c
   trunk/libavcodec/vorbis.h
   trunk/libavcodec/vorbis_data.c
   trunk/libavcodec/vorbis_enc.c
   trunk/libavcodec/vp3data.h
   trunk/libavcodec/wnv1.c

Modified: trunk/libavcodec/ac3enc.c
==============================================================================
--- trunk/libavcodec/ac3enc.c	(original)
+++ trunk/libavcodec/ac3enc.c	Tue Jun 24 22:01:31 2008
@@ -490,7 +490,7 @@ static int compute_bit_allocation(AC3Enc
     uint8_t bap1[NB_BLOCKS][AC3_MAX_CHANNELS][N/2];
     int16_t psd[NB_BLOCKS][AC3_MAX_CHANNELS][N/2];
     int16_t mask[NB_BLOCKS][AC3_MAX_CHANNELS][50];
-    static int frame_bits_inc[8] = { 0, 0, 2, 2, 2, 4, 2, 4 };
+    static const int frame_bits_inc[8] = { 0, 0, 2, 2, 2, 4, 2, 4 };
 
     /* init default parameters */
     s->slow_decay_code = 2;

Modified: trunk/libavcodec/atrac3data.h
==============================================================================
--- trunk/libavcodec/atrac3data.h	(original)
+++ trunk/libavcodec/atrac3data.h	Tue Jun 24 22:01:31 2008
@@ -97,11 +97,11 @@ static const uint8_t huff_tab_sizes[7] =
   9, 5, 7, 9, 15, 31, 63,
 };
 
-static const uint8_t* huff_codes[7] = {
+static const uint8_t* const huff_codes[7] = {
   huffcode1,huffcode2,huffcode3,huffcode4,huffcode5,huffcode6,huffcode7,
 };
 
-static const uint8_t* huff_bits[7] = {
+static const uint8_t* const huff_bits[7] = {
   huffbits1,huffbits2,huffbits3,huffbits4,huffbits5,huffbits6,huffbits7,
 };
 

Modified: trunk/libavcodec/cookdata.h
==============================================================================
--- trunk/libavcodec/cookdata.h	(original)
+++ trunk/libavcodec/cookdata.h	Tue Jun 24 22:01:31 2008
@@ -422,12 +422,12 @@ static const uint16_t cvh_huffcodes6[32]
     0x003c,0x01fc,0x00fb,0x03fd,0x00fc,0x03fe,0x01fd,0x07ff,
 };
 
-static const uint16_t* cvh_huffcodes[7] = {
+static const uint16_t* const cvh_huffcodes[7] = {
     cvh_huffcodes0, cvh_huffcodes1, cvh_huffcodes2, cvh_huffcodes3,
     cvh_huffcodes4, cvh_huffcodes5, cvh_huffcodes6,
 };
 
-static const uint8_t* cvh_huffbits[7] = {
+static const uint8_t* const cvh_huffbits[7] = {
     cvh_huffbits0, cvh_huffbits1, cvh_huffbits2, cvh_huffbits3,
     cvh_huffbits4, cvh_huffbits5, cvh_huffbits6,
 };
@@ -488,12 +488,12 @@ static const uint8_t ccpl_huffbits6[63] 
     14,14,16,
 };
 
-static const uint16_t* ccpl_huffcodes[5] = {
+static const uint16_t* const ccpl_huffcodes[5] = {
     ccpl_huffcodes2,ccpl_huffcodes3,
     ccpl_huffcodes4,ccpl_huffcodes5,ccpl_huffcodes6
 };
 
-static const uint8_t* ccpl_huffbits[5] = {
+static const uint8_t* const ccpl_huffbits[5] = {
     ccpl_huffbits2,ccpl_huffbits3,
     ccpl_huffbits4,ccpl_huffbits5,ccpl_huffbits6
 };
@@ -556,7 +556,7 @@ static const float cplscale6[63] = {
 0.142307326197624,0.109772264957428,0.0631198287010193,
 };
 
-static const float* cplscales[5] = {
+static const float* const cplscales[5] = {
     cplscale2, cplscale3, cplscale4, cplscale5, cplscale6,
 };
 

Modified: trunk/libavcodec/dcahuff.h
==============================================================================
--- trunk/libavcodec/dcahuff.h	(original)
+++ trunk/libavcodec/dcahuff.h	Tue Jun 24 22:01:31 2008
@@ -1037,7 +1037,7 @@ static const uint8_t bitalloc_maxbits[10
     { 9, 9, 9, 9, 9, 9, 9 }
 };
 
-static const uint16_t* bitalloc_codes[10][8] = {
+static const uint16_t* const bitalloc_codes[10][8] = {
   { bitalloc_3_codes, NULL },
   { bitalloc_5_codes_a,  bitalloc_5_codes_b,  bitalloc_5_codes_c,  NULL },
   { bitalloc_7_codes_a,  bitalloc_7_codes_b,  bitalloc_7_codes_c,  NULL },
@@ -1055,7 +1055,7 @@ static const uint16_t* bitalloc_codes[10
     bitalloc_129_codes_e, bitalloc_129_codes_f, bitalloc_129_codes_g, NULL }
 };
 
-static const uint8_t* bitalloc_bits[10][8] = {
+static const uint8_t* const bitalloc_bits[10][8] = {
   { bitalloc_3_bits, NULL },
   { bitalloc_5_bits_a,  bitalloc_5_bits_b,  bitalloc_5_bits_c,  NULL },
   { bitalloc_7_bits_a,  bitalloc_7_bits_b,  bitalloc_7_bits_c,  NULL },

Modified: trunk/libavcodec/dpcm.c
==============================================================================
--- trunk/libavcodec/dpcm.c	(original)
+++ trunk/libavcodec/dpcm.c	Tue Jun 24 22:01:31 2008
@@ -48,7 +48,7 @@ typedef struct DPCMContext {
 
 #define SE_16BIT(x)  if (x & 0x8000) x -= 0x10000;
 
-static int interplay_delta_table[] = {
+static const int interplay_delta_table[] = {
          0,      1,      2,      3,      4,      5,      6,      7,
          8,      9,     10,     11,     12,     13,     14,     15,
         16,     17,     18,     19,     20,     21,     22,     23,

Modified: trunk/libavcodec/eval.c
==============================================================================
--- trunk/libavcodec/eval.c	(original)
+++ trunk/libavcodec/eval.c	Tue Jun 24 22:01:31 2008
@@ -59,7 +59,7 @@ typedef struct Parser{
     double var[VARS];
 } Parser;
 
-static int8_t si_prefixes['z' - 'E' + 1]={
+static const int8_t si_prefixes['z' - 'E' + 1]={
     ['y'-'E']= -24,
     ['z'-'E']= -21,
     ['a'-'E']= -18,

Modified: trunk/libavcodec/faandct.c
==============================================================================
--- trunk/libavcodec/faandct.c	(original)
+++ trunk/libavcodec/faandct.c	Tue Jun 24 22:01:31 2008
@@ -62,7 +62,7 @@ for(i=0; i<8; i++){
 #define A5 0.38268343236508977170 // cos(pi*6/16)
 #define A4 1.30656296487637652774 // cos(pi*2/16)sqrt(2)
 
-static FLOAT postscale[64]={
+static const FLOAT postscale[64]={
 B0*B0, B0*B1, B0*B2, B0*B3, B0*B4, B0*B5, B0*B6, B0*B7,
 B1*B0, B1*B1, B1*B2, B1*B3, B1*B4, B1*B5, B1*B6, B1*B7,
 B2*B0, B2*B1, B2*B2, B2*B3, B2*B4, B2*B5, B2*B6, B2*B7,

Modified: trunk/libavcodec/flac.c
==============================================================================
--- trunk/libavcodec/flac.c	(original)
+++ trunk/libavcodec/flac.c	Tue Jun 24 22:01:31 2008
@@ -75,15 +75,15 @@ typedef struct FLACContext {
 
 #define METADATA_TYPE_STREAMINFO 0
 
-static int sample_rate_table[] =
+static const int sample_rate_table[] =
 { 0, 0, 0, 0,
   8000, 16000, 22050, 24000, 32000, 44100, 48000, 96000,
   0, 0, 0, 0 };
 
-static int sample_size_table[] =
+static const int sample_size_table[] =
 { 0, 8, 12, 0, 16, 20, 24, 0 };
 
-static int blocksize_table[] = {
+static const int blocksize_table[] = {
      0,    192, 576<<0, 576<<1, 576<<2, 576<<3,      0,      0,
 256<<0, 256<<1, 256<<2, 256<<3, 256<<4, 256<<5, 256<<6, 256<<7
 };

Modified: trunk/libavcodec/imcdata.h
==============================================================================
--- trunk/libavcodec/imcdata.h	(original)
+++ trunk/libavcodec/imcdata.h	Tue Jun 24 22:01:31 2008
@@ -94,7 +94,7 @@ static const float imc_exp_tab[32] = {
     1.778280e02, 3.162278e02, 5.623413e02, 1.000000e03,
     1.778280e03, 3.162278e03, 5.623413e03, 1.000000e04
 };
-static const float *imc_exp_tab2 = imc_exp_tab + 8;
+static const float * const imc_exp_tab2 = imc_exp_tab + 8;
 
 
 static const uint8_t imc_cb_select[4][32] = {

Modified: trunk/libavcodec/mpeg12decdata.h
==============================================================================
--- trunk/libavcodec/mpeg12decdata.h	(original)
+++ trunk/libavcodec/mpeg12decdata.h	Tue Jun 24 22:01:31 2008
@@ -114,7 +114,7 @@ static const uint8_t mpeg2_dc_scale_tabl
     1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
 };
 
-static const uint8_t *mpeg2_dc_scale_table[4]={
+static const uint8_t * const mpeg2_dc_scale_table[4]={
     ff_mpeg1_dc_scale_table,
     mpeg2_dc_scale_table1,
     mpeg2_dc_scale_table2,

Modified: trunk/libavcodec/mpegaudiodata.c
==============================================================================
--- trunk/libavcodec/mpegaudiodata.c	(original)
+++ trunk/libavcodec/mpegaudiodata.c	Tue Jun 24 22:01:31 2008
@@ -221,5 +221,5 @@ static const unsigned char alloc_table_4
  2,  0,  1,  3,
 };
 
-const unsigned char *ff_mpa_alloc_tables[5] =
+const unsigned char * const ff_mpa_alloc_tables[5] =
 { alloc_table_0, alloc_table_1, alloc_table_2, alloc_table_3, alloc_table_4, };

Modified: trunk/libavcodec/mpegaudiodata.h
==============================================================================
--- trunk/libavcodec/mpegaudiodata.h	(original)
+++ trunk/libavcodec/mpegaudiodata.h	Tue Jun 24 22:01:31 2008
@@ -38,6 +38,6 @@ extern const int32_t ff_mpa_enwindow[257
 extern const int ff_mpa_sblimit_table[5];
 extern const int ff_mpa_quant_steps[17];
 extern const int ff_mpa_quant_bits[17];
-extern const unsigned char *ff_mpa_alloc_tables[5];
+extern const unsigned char * const ff_mpa_alloc_tables[5];
 
 #endif /* FFMPEG_MPEGAUDIODATA_H */

Modified: trunk/libavcodec/opt.c
==============================================================================
--- trunk/libavcodec/opt.c	(original)
+++ trunk/libavcodec/opt.c	Tue Jun 24 22:01:31 2008
@@ -94,14 +94,14 @@ static const AVOption *set_all_opt(void 
     return ret;
 }
 
-static double const_values[]={
+static const double const_values[]={
     M_PI,
     M_E,
     FF_QP2LAMBDA,
     0
 };
 
-static const char *const_names[]={
+static const char * const const_names[]={
     "PI",
     "E",
     "QP2LAMBDA",

Modified: trunk/libavcodec/qdm2.c
==============================================================================
--- trunk/libavcodec/qdm2.c	(original)
+++ trunk/libavcodec/qdm2.c	Tue Jun 24 22:01:31 2008
@@ -361,7 +361,7 @@ static void qdm2_init_vlc(void)
 
 
 /* for floating point to fixed point conversion */
-static float f2i_scale = (float) (1 << (FRAC_BITS - 15));
+static const float f2i_scale = (float) (1 << (FRAC_BITS - 15));
 
 
 static int qdm2_get_vlc (GetBitContext *gb, VLC *vlc, int flag, int depth)

Modified: trunk/libavcodec/qdm2data.h
==============================================================================
--- trunk/libavcodec/qdm2data.h	(original)
+++ trunk/libavcodec/qdm2data.h	Tue Jun 24 22:01:31 2008
@@ -254,17 +254,17 @@ static const int16_t fft_level_index_tab
     5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
 };
 
-static uint8_t last_coeff[3] = {
+static const uint8_t last_coeff[3] = {
     4, 7, 10
 };
 
-static uint8_t coeff_per_sb_for_avg[3][30] = {
+static const uint8_t coeff_per_sb_for_avg[3][30] = {
     { 0, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3 },
     { 0, 1, 2, 2, 3, 3, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6 },
     { 0, 1, 2, 3, 4, 4, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9 }
 };
 
-static uint32_t dequant_table[3][10][30] = {
+static const uint32_t dequant_table[3][10][30] = {
     { { 256, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
       { 0, 256, 256, 205, 154, 102, 51, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
       { 0, 0, 0, 51, 102, 154, 205, 256, 238, 219, 201, 183, 165, 146, 128, 110, 91, 73, 55, 37, 18, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
@@ -297,14 +297,14 @@ static uint32_t dequant_table[3][10][30]
       { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 43, 85, 128, 171, 213, 256, 213, 171, 128, 85, 43 } }
 };
 
-static uint8_t coeff_per_sb_for_dequant[3][30] = {
+static const uint8_t coeff_per_sb_for_dequant[3][30] = {
     { 0, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3 },
     { 0, 1, 2, 2, 2, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6 },
     { 0, 1, 2, 3, 4, 4, 5, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9 }
 };
 
 /* first index is subband, 2nd index is 0, 1 or 3 (2 is unused) */
-static int8_t tone_level_idx_offset_table[30][4] = {
+static const int8_t tone_level_idx_offset_table[30][4] = {
     { -50, -50,  0, -50 },
     { -50, -50,  0, -50 },
     { -50,  -9,  0, -19 },
@@ -339,7 +339,7 @@ static int8_t tone_level_idx_offset_tabl
 
 /* all my samples have 1st index 0 or 1 */
 /* second index is subband, only indexes 0-29 seem to be used */
-static int8_t coding_method_table[5][30] = {
+static const int8_t coding_method_table[5][30] = {
     { 34, 30, 24, 24, 16, 16, 16, 16, 10, 10, 10, 10, 10, 10, 10,
       10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10
     },
@@ -513,7 +513,7 @@ static const uint8_t fft_subpackets[32] 
 };
 
 /* first index is joined_stereo, second index is 0 or 2 (1 is unused) */
-static float dequant_1bit[2][3] = {
+static const float dequant_1bit[2][3] = {
     {-0.920000f, 0.000000f, 0.920000f },
     {-0.890000f, 0.000000f, 0.890000f }
 };

Modified: trunk/libavcodec/qpeg.c
==============================================================================
--- trunk/libavcodec/qpeg.c	(original)
+++ trunk/libavcodec/qpeg.c	Tue Jun 24 22:01:31 2008
@@ -108,9 +108,9 @@ static void qpeg_decode_intra(const uint
     }
 }
 
-static int qpeg_table_h[16] =
+static const int qpeg_table_h[16] =
  { 0x00, 0x20, 0x20, 0x20, 0x18, 0x10, 0x10, 0x20, 0x10, 0x08, 0x18, 0x08, 0x08, 0x18, 0x10, 0x04};
-static int qpeg_table_w[16] =
+static const int qpeg_table_w[16] =
  { 0x00, 0x20, 0x18, 0x08, 0x18, 0x10, 0x20, 0x10, 0x08, 0x10, 0x20, 0x20, 0x08, 0x10, 0x18, 0x04};
 
 /* Decodes delta frames */

Modified: trunk/libavcodec/ra144.h
==============================================================================
--- trunk/libavcodec/ra144.h	(original)
+++ trunk/libavcodec/ra144.h	Tue Jun 24 22:01:31 2008
@@ -1547,7 +1547,7 @@ static const int16_t lpc_refl_cb10[4]={
      -617,   190,   802,  1483
 };
 
-static const int16_t *lpc_refl_cb[10]={
+static const int16_t * const lpc_refl_cb[10]={
     lpc_refl_cb1, lpc_refl_cb2, lpc_refl_cb3, lpc_refl_cb4, lpc_refl_cb5,
     lpc_refl_cb6, lpc_refl_cb7, lpc_refl_cb8, lpc_refl_cb9, lpc_refl_cb10
 };

Modified: trunk/libavcodec/ratecontrol.c
==============================================================================
--- trunk/libavcodec/ratecontrol.c	(original)
+++ trunk/libavcodec/ratecontrol.c	Tue Jun 24 22:01:31 2008
@@ -67,7 +67,7 @@ int ff_rate_control_init(MpegEncContext 
     RateControlContext *rcc= &s->rc_context;
     int i;
     const char *error = NULL;
-    static const char *const_names[]={
+    static const char * const const_names[]={
         "PI",
         "E",
         "iTex",
@@ -99,7 +99,7 @@ int ff_rate_control_init(MpegEncContext 
         (void *)qp2bits,
         NULL
     };
-    static const char *func1_names[]={
+    static const char * const func1_names[]={
         "bits2qp",
         "qp2bits",
         NULL

Modified: trunk/libavcodec/snow.c
==============================================================================
--- trunk/libavcodec/snow.c	(original)
+++ trunk/libavcodec/snow.c	Tue Jun 24 22:01:31 2008
@@ -363,7 +363,7 @@ static const uint8_t obmc4[16]={
 //error:0.000000
 };
 
-static const uint8_t *obmc_tab[4]={
+static const uint8_t * const obmc_tab[4]={
     obmc32, obmc16, obmc8, obmc4
 };
 

Modified: trunk/libavcodec/sonic.c
==============================================================================
--- trunk/libavcodec/sonic.c	(original)
+++ trunk/libavcodec/sonic.c	Tue Jun 24 22:01:31 2008
@@ -481,7 +481,7 @@ static void modified_levinson_durbin(int
 }
 #endif /* CONFIG_ENCODERS */
 
-static int samplerate_table[] =
+static const int samplerate_table[] =
     { 44100, 22050, 11025, 96000, 48000, 32000, 24000, 16000, 8000 };
 
 #ifdef CONFIG_ENCODERS

Modified: trunk/libavcodec/truemotion1.c
==============================================================================
--- trunk/libavcodec/truemotion1.c	(original)
+++ trunk/libavcodec/truemotion1.c	Tue Jun 24 22:01:31 2008
@@ -117,7 +117,7 @@ typedef struct comp_types {
 } comp_types;
 
 /* { valid for metatype }, algorithm, num of deltas, vert res, horiz res */
-static comp_types compression_types[17] = {
+static const comp_types compression_types[17] = {
     { ALGO_NOP,    0, 0, 0 },
 
     { ALGO_RGB16V, 4, 4, BLOCK_4x4 },

Modified: trunk/libavcodec/truemotion1data.h
==============================================================================
--- trunk/libavcodec/truemotion1data.h	(original)
+++ trunk/libavcodec/truemotion1data.h	Tue Jun 24 22:01:31 2008
@@ -46,10 +46,10 @@ static const int16_t cdt3[8] = { 0, -2, 
 static const int16_t fat_cdt3[8] = { 0, 40, 80, -76, 160, -154, 236, -236 };
 
 /* all the delta tables to choose from, at all 4 delta levels */
-static const int16_t *ydts[] = { ydt1, ydt2, ydt3, ydt4, NULL };
-static const int16_t *fat_ydts[] = { fat_ydt3, fat_ydt3, fat_ydt3, fat_ydt4, NULL };
-static const int16_t *cdts[] = { cdt1, cdt1, cdt2, cdt3, NULL };
-static const int16_t *fat_cdts[] = { fat_cdt2, fat_cdt2, fat_cdt2, fat_cdt3, NULL };
+static const int16_t * const ydts[] = { ydt1, ydt2, ydt3, ydt4, NULL };
+static const int16_t * const fat_ydts[] = { fat_ydt3, fat_ydt3, fat_ydt3, fat_ydt4, NULL };
+static const int16_t * const cdts[] = { cdt1, cdt1, cdt2, cdt3, NULL };
+static const int16_t * const fat_cdts[] = { fat_cdt2, fat_cdt2, fat_cdt2, fat_cdt3, NULL };
 
 static const uint8_t pc_tbl2[] = {
 0x8,0x00,0x00,0x00,0x00,
@@ -828,6 +828,6 @@ static const uint8_t pc_tbl4[] = {
 0x2,0x77
 };
 
-static const uint8_t *tables[] = { pc_tbl2, pc_tbl3, pc_tbl4 };
+static const uint8_t * const tables[] = { pc_tbl2, pc_tbl3, pc_tbl4 };
 
 #endif /* FFMPEG_TRUEMOTION1DATA_H */

Modified: trunk/libavcodec/truespeech_data.h
==============================================================================
--- trunk/libavcodec/truespeech_data.h	(original)
+++ trunk/libavcodec/truespeech_data.h	Tue Jun 24 22:01:31 2008
@@ -66,7 +66,7 @@ static const int16_t ts_cb_7[8] = {
     0xCEF0, 0xE4F9, 0xF6BB, 0x0646, 0x14F5, 0x23FF, 0x356F, 0x4A8D,
 };
 
-static const int16_t *ts_codebook[8] = {
+static const int16_t * const ts_codebook[8] = {
     ts_cb_0, ts_cb_1, ts_cb_2, ts_cb_3, ts_cb_4, ts_cb_5, ts_cb_6, ts_cb_7
 };
 

Modified: trunk/libavcodec/tta.c
==============================================================================
--- trunk/libavcodec/tta.c	(original)
+++ trunk/libavcodec/tta.c	Tue Jun 24 22:01:31 2008
@@ -76,7 +76,7 @@ static const uint32_t shift_1[] = {
     0x80000000, 0x80000000, 0x80000000, 0x80000000
 };
 
-static const uint32_t *shift_16 = shift_1 + 4;
+static const uint32_t * const shift_16 = shift_1 + 4;
 #endif
 
 #define MAX_ORDER 16
@@ -87,7 +87,7 @@ typedef struct TTAFilter {
     int32_t dl[MAX_ORDER];
 } TTAFilter;
 
-static int32_t ttafilter_configs[4][2] = {
+static const int32_t ttafilter_configs[4][2] = {
     {10, 1},
     {9, 1},
     {10, 1},

Modified: trunk/libavcodec/ulti.c
==============================================================================
--- trunk/libavcodec/ulti.c	(original)
+++ trunk/libavcodec/ulti.c	Tue Jun 24 22:01:31 2008
@@ -56,13 +56,13 @@ static av_cold int ulti_decode_init(AVCo
     return 0;
 }
 
-static int block_coords[8] = // 4x4 block coords in 8x8 superblock
+static const int block_coords[8] = // 4x4 block coords in 8x8 superblock
     { 0, 0, 0, 4, 4, 4, 4, 0};
 
-static int angle_by_index[4] = { 0, 2, 6, 12};
+static const int angle_by_index[4] = { 0, 2, 6, 12};
 
 /* Lookup tables for luma and chroma - used by ulti_convert_yuv() */
-static uint8_t ulti_lumas[64] =
+static const uint8_t ulti_lumas[64] =
     { 0x10, 0x13, 0x17, 0x1A, 0x1E, 0x21, 0x25, 0x28,
       0x2C, 0x2F, 0x33, 0x36, 0x3A, 0x3D, 0x41, 0x44,
       0x48, 0x4B, 0x4F, 0x52, 0x56, 0x59, 0x5C, 0x60,
@@ -72,7 +72,7 @@ static uint8_t ulti_lumas[64] =
       0xB7, 0xBA, 0xBE, 0xC1, 0xC5, 0xC8, 0xCC, 0xCF,
       0xD3, 0xD6, 0xDA, 0xDD, 0xE1, 0xE4, 0xE8, 0xEB};
 
-static uint8_t ulti_chromas[16] =
+static const uint8_t ulti_chromas[16] =
     { 0x60, 0x67, 0x6D, 0x73, 0x7A, 0x80, 0x86, 0x8D,
       0x93, 0x99, 0xA0, 0xA6, 0xAC, 0xB3, 0xB9, 0xC0};
 

Modified: trunk/libavcodec/utils.c
==============================================================================
--- trunk/libavcodec/utils.c	(original)
+++ trunk/libavcodec/utils.c	Tue Jun 24 22:01:31 2008
@@ -1369,7 +1369,7 @@ typedef struct {
     int rate_num, rate_den;
 } VideoFrameRateAbbr;
 
-static VideoFrameSizeAbbr video_frame_size_abbrs[] = {
+static const VideoFrameSizeAbbr video_frame_size_abbrs[] = {
     { "ntsc",      720, 480 },
     { "pal",       720, 576 },
     { "qntsc",     352, 240 }, /* VCD compliant NTSC */
@@ -1408,7 +1408,7 @@ static VideoFrameSizeAbbr video_frame_si
     { "hd1080",   1920,1080 },
 };
 
-static VideoFrameRateAbbr video_frame_rate_abbrs[]= {
+static const VideoFrameRateAbbr video_frame_rate_abbrs[]= {
     { "ntsc",      30000, 1001 },
     { "pal",          25,    1 },
     { "qntsc",     30000, 1001 }, /* VCD compliant NTSC */

Modified: trunk/libavcodec/vmdav.c
==============================================================================
--- trunk/libavcodec/vmdav.c	(original)
+++ trunk/libavcodec/vmdav.c	Tue Jun 24 22:01:31 2008
@@ -422,7 +422,7 @@ typedef struct VmdAudioContext {
     int predictors[2];
 } VmdAudioContext;
 
-static uint16_t vmdaudio_table[128] = {
+static const uint16_t vmdaudio_table[128] = {
     0x000, 0x008, 0x010, 0x020, 0x030, 0x040, 0x050, 0x060, 0x070, 0x080,
     0x090, 0x0A0, 0x0B0, 0x0C0, 0x0D0, 0x0E0, 0x0F0, 0x100, 0x110, 0x120,
     0x130, 0x140, 0x150, 0x160, 0x170, 0x180, 0x190, 0x1A0, 0x1B0, 0x1C0,

Modified: trunk/libavcodec/vorbis.h
==============================================================================
--- trunk/libavcodec/vorbis.h	(original)
+++ trunk/libavcodec/vorbis.h	Tue Jun 24 22:01:31 2008
@@ -24,7 +24,7 @@
 #include "avcodec.h"
 
 extern const float ff_vorbis_floor1_inverse_db_table[256];
-extern const float * ff_vorbis_vwin[8];
+extern const float * const ff_vorbis_vwin[8];
 
 typedef struct {
     uint_fast16_t x;

Modified: trunk/libavcodec/vorbis_data.c
==============================================================================
--- trunk/libavcodec/vorbis_data.c	(original)
+++ trunk/libavcodec/vorbis_data.c	Tue Jun 24 22:01:31 2008
@@ -2151,5 +2151,5 @@ const float ff_vorbis_floor1_inverse_db_
   0.82788260F, 0.88168307F, 0.9389798F, 1.F,
 };
 
-const float * ff_vorbis_vwin[8] = { vwin64, vwin128, vwin256, vwin512, vwin1024, vwin2048, vwin4096, vwin8192 };
+const float * const ff_vorbis_vwin[8] = { vwin64, vwin128, vwin256, vwin512, vwin1024, vwin2048, vwin4096, vwin8192 };
 

Modified: trunk/libavcodec/vorbis_enc.c
==============================================================================
--- trunk/libavcodec/vorbis_enc.c	(original)
+++ trunk/libavcodec/vorbis_enc.c	Tue Jun 24 22:01:31 2008
@@ -1075,7 +1075,7 @@ static av_cold int vorbis_encode_close(A
     return 0 ;
 }
 
-AVCodec vorbis_encoder = {
+const AVCodec vorbis_encoder = {
     "vorbis",
     CODEC_TYPE_AUDIO,
     CODEC_ID_VORBIS,

Modified: trunk/libavcodec/vp3data.h
==============================================================================
--- trunk/libavcodec/vp3data.h	(original)
+++ trunk/libavcodec/vp3data.h	Tue Jun 24 22:01:31 2008
@@ -405,7 +405,7 @@ static const int16_t coeff_table_token_2
     -573, -574, -575, -576, -577, -578, -579, -580
 };
 
-static const int16_t *coeff_tables[32] = {
+static const int16_t *const coeff_tables[32] = {
     NULL,
     NULL,
     NULL,

Modified: trunk/libavcodec/wnv1.c
==============================================================================
--- trunk/libavcodec/wnv1.c	(original)
+++ trunk/libavcodec/wnv1.c	Tue Jun 24 22:01:31 2008
@@ -36,7 +36,7 @@ typedef struct WNV1Context{
     GetBitContext gb;
 } WNV1Context;
 
-static uint16_t code_tab[16][2]={
+static const uint16_t code_tab[16][2]={
 {0x1FD,9}, {0xFD,8}, {0x7D,7}, {0x3D,6}, {0x1D,5}, {0x0D,4}, {0x005,3},
 {0x000,1},
 {0x004,3}, {0x0C,4}, {0x1C,5}, {0x3C,6}, {0x7C,7}, {0xFC,8}, {0x1FC,9}, {0xFF,8}




More information about the ffmpeg-cvslog mailing list