History

Mark some arrays that never change as const.

Anton Khirnov committed 10 years ago

Commit fd9212f1 parent b420a2751 files · +129 −129Browse files

Unified · Split

51 files
  1. configure +1 −1
  2. libavcodec/aaccoder.c +2 −2
  3. libavcodec/aacenc.c +2 −2
  4. libavcodec/aacenc.h +2 −2
  5. libavcodec/aic.c +1 −1
  6. libavcodec/amrnbdata.h +2 −2
  7. libavcodec/amrwbdata.h +2 −2
  8. libavcodec/atrac3plus.c +19 −19
  9. libavcodec/dfa.c +1 −1
  10. libavcodec/g722dec.c +3 −3
  11. libavcodec/h263data.c +2 −2
  12. libavcodec/h263data.h +2 −2
  13. libavcodec/indeo3.c +2 −2
  14. libavcodec/indeo4data.h +1 −1
  15. libavcodec/mpeg4videodec.c +1 −1
  16. libavcodec/on2avc.c +2 −2
  17. libavcodec/on2avcdata.c +10 −10
  18. libavcodec/on2avcdata.h +10 −10
  19. libavcodec/opus_silk.c +3 −3
  20. libavcodec/qsvdec_h2645.c +2 −2
  21. libavcodec/qsvenc_hevc.c +2 −2
  22. libavcodec/sipr.c +1 −1
  23. libavcodec/sipr16k.c +1 −1
  24. libavcodec/sipr16kdata.h +1 −1
  25. libavcodec/siprdata.h +1 −1
  26. libavcodec/tscc2data.h +3 −3
  27. libavcodec/vaapi_encode.c +1 −1
  28. libavcodec/vaapi_encode_mjpeg.c +1 −1
  29. libavcodec/vp8.c +4 −4
  30. libavcodec/vp9block.c +2 −2
  31. libavcodec/vp9data.c +2 −2
  32. libavcodec/vp9data.h +2 −2
  33. libavcodec/x86/fdct.c +2 −2
  34. libavcodec/x86/mlpdsp.c +8 −8
  35. libavcodec/x86/videodsp_init.c +6 −6
  36. libavfilter/af_volume.c +1 −1
  37. libavfilter/vf_drawtext.c +1 −1
  38. libavfilter/vf_libopencv.c +2 −2
  39. libavfilter/vf_overlay.c +1 −1
  40. libavformat/hls.c +2 −2
  41. libavformat/id3v2.c +1 −1
  42. libavformat/id3v2.h +1 −1
  43. libavformat/mov_chan.c +1 −1
  44. libavformat/movenc.c +1 −1
  45. libavformat/mxfdec.c +1 −1
  46. libavresample/audio_mix.c +1 −1
  47. libavutil/hwcontext.c +1 −1
  48. libavutil/hwcontext_vaapi.c +1 −1
  49. libavutil/parseutils.c +1 −1
  50. libavutil/pixdesc.c +5 −5
  51. libavutil/stereo3d.c +1 −1
configure+1−1
@@ -5414,7 +5414,7 @@ print_enabled_components(){ · 5413 unmodified lines
5414 struct_name=$25414 struct_name=$2
5415 name=$35415 name=$3
5416 shift 35416 shift 3
5417 echo "static const $struct_name *$name[] = {" > $TMPH5417 echo "static const $struct_name * const $name[] = {" > $TMPH
5418 for c in $*; do5418 for c in $*; do
5419 enabled $c && printf " &ff_%s,\n" $c >> $TMPH5419 enabled $c && printf " &ff_%s,\n" $c >> $TMPH
5420 done5420 done
libavcodec/aaccoder.c+2−2
@@ -53,7 +53,7 @@ static const uint8_t run_value_bits_short[16] = { · 52 unmodified lines
53 3, 3, 3, 3, 3, 3, 3, 6, 6, 6, 6, 6, 6, 6, 6, 953 3, 3, 3, 3, 3, 3, 3, 6, 6, 6, 6, 6, 6, 6, 6, 9
54};54};
55 55
56static const uint8_t *run_value_bits[2] = {56static const uint8_t * const run_value_bits[2] = {
57 run_value_bits_long, run_value_bits_short57 run_value_bits_long, run_value_bits_short
58};58};
59 59
@@ -1112,7 +1112,7 @@ static void search_for_ms(AACEncContext *s, ChannelElement *cpe, · 1052 unmodified lines
1112 }1112 }
1113}1113}
1114 1114
1115AACCoefficientsEncoder ff_aac_coders[] = {1115const AACCoefficientsEncoder ff_aac_coders[] = {
1116 {1116 {
1117 search_for_quantizers_faac,1117 search_for_quantizers_faac,
1118 encode_window_bands_info,1118 encode_window_bands_info,
libavcodec/aacenc.c+2−2
@@ -98,7 +98,7 @@ static const uint8_t swb_size_1024_8[] = { · 97 unmodified lines
98 32, 36, 36, 40, 44, 48, 52, 56, 60, 64, 8098 32, 36, 36, 40, 44, 48, 52, 56, 60, 64, 80
99};99};
100 100
101static const uint8_t *swb_size_1024[] = {101static const uint8_t * const swb_size_1024[] = {
102 swb_size_1024_96, swb_size_1024_96, swb_size_1024_64,102 swb_size_1024_96, swb_size_1024_96, swb_size_1024_64,
103 swb_size_1024_48, swb_size_1024_48, swb_size_1024_32,103 swb_size_1024_48, swb_size_1024_48, swb_size_1024_32,
104 swb_size_1024_24, swb_size_1024_24, swb_size_1024_16,104 swb_size_1024_24, swb_size_1024_24, swb_size_1024_16,
@@ -125,7 +125,7 @@ static const uint8_t swb_size_128_8[] = { · 20 unmodified lines
125 4, 4, 4, 4, 4, 4, 4, 8, 8, 8, 8, 12, 16, 20, 20125 4, 4, 4, 4, 4, 4, 4, 8, 8, 8, 8, 12, 16, 20, 20
126};126};
127 127
128static const uint8_t *swb_size_128[] = {128static const uint8_t * const swb_size_128[] = {
129 /* the last entry on the following row is swb_size_128_64 but is a129 /* the last entry on the following row is swb_size_128_64 but is a
130 duplicate of swb_size_128_96 */130 duplicate of swb_size_128_96 */
131 swb_size_128_96, swb_size_128_96, swb_size_128_96,131 swb_size_128_96, swb_size_128_96, swb_size_128_96,
libavcodec/aacenc.h+2−2
@@ -46,7 +46,7 @@ typedef struct AACCoefficientsEncoder { · 45 unmodified lines
46 void (*search_for_ms)(struct AACEncContext *s, ChannelElement *cpe, const float lambda);46 void (*search_for_ms)(struct AACEncContext *s, ChannelElement *cpe, const float lambda);
47} AACCoefficientsEncoder;47} AACCoefficientsEncoder;
48 48
49extern AACCoefficientsEncoder ff_aac_coders[];49extern const AACCoefficientsEncoder ff_aac_coders[];
50 50
51/**51/**
52 * AAC encoder context52 * AAC encoder context
@@ -67,7 +67,7 @@ typedef struct AACEncContext { · 14 unmodified lines
67 ChannelElement *cpe; ///< channel elements67 ChannelElement *cpe; ///< channel elements
68 FFPsyContext psy;68 FFPsyContext psy;
69 struct FFPsyPreprocessContext* psypp;69 struct FFPsyPreprocessContext* psypp;
70 AACCoefficientsEncoder *coder;70 const AACCoefficientsEncoder *coder;
71 int cur_channel;71 int cur_channel;
72 int last_frame;72 int last_frame;
73 float lambda;73 float lambda;
libavcodec/aic.c+1−1
@@ -133,7 +133,7 @@ static const uint8_t aic_c_ext_scan[192] = { · 132 unmodified lines
133 177, 184, 176, 169, 162, 161, 168, 160,133 177, 184, 176, 169, 162, 161, 168, 160,
134};134};
135 135
136static const uint8_t *aic_scan[NUM_BANDS] = {136static const uint8_t * const aic_scan[NUM_BANDS] = {
137 aic_y_scan, aic_c_scan, aic_y_ext_scan, aic_c_ext_scan137 aic_y_scan, aic_c_scan, aic_y_ext_scan, aic_c_ext_scan
138};138};
139 139
libavcodec/amrnbdata.h+2−2
@@ -1655,10 +1655,10 @@ static const float ir_filter_medium[AMR_SUBFRAME_SIZE] = { · 1654 unmodified lines
1655 0.016998, 0.023804, -0.041779, 0.025696, 0.019989,1655 0.016998, 0.023804, -0.041779, 0.025696, 0.019989,
1656};1656};
1657 1657
1658static const float *ir_filters_lookup[2] = {1658static const float * const ir_filters_lookup[2] = {
1659 ir_filter_strong, ir_filter_medium1659 ir_filter_strong, ir_filter_medium
1660};1660};
1661static const float *ir_filters_lookup_MODE_7k95[2] = {1661static const float * const ir_filters_lookup_MODE_7k95[2] = {
1662 ir_filter_strong_MODE_7k95, ir_filter_medium1662 ir_filter_strong_MODE_7k95, ir_filter_medium
1663};1663};
1664 1664
libavcodec/amrwbdata.h+2−2
@@ -673,7 +673,7 @@ static const uint16_t order_MODE_23k85[] = { · 672 unmodified lines
673};673};
674 674
675/** Reordering array addresses for each mode */675/** Reordering array addresses for each mode */
676static const uint16_t* amr_bit_orderings_by_mode[] = {676static const uint16_t * const amr_bit_orderings_by_mode[] = {
677 order_MODE_6k60,677 order_MODE_6k60,
678 order_MODE_8k85,678 order_MODE_8k85,
679 order_MODE_12k65,679 order_MODE_12k65,
@@ -1805,7 +1805,7 @@ static const float ir_filter_mid[64] = { · 1125 unmodified lines
1805 -7.501221e-02, 2.920532e-02, 1.660156e-02, 7.751465e-021805 -7.501221e-02, 2.920532e-02, 1.660156e-02, 7.751465e-02
1806};1806};
1807 1807
1808static const float *ir_filters_lookup[2] = {1808static const float * const ir_filters_lookup[2] = {
1809 ir_filter_str, ir_filter_mid1809 ir_filter_str, ir_filter_mid
1810};1810};
1811 1811
libavcodec/atrac3plus.c+19−19
@@ -82,52 +82,52 @@ av_cold void ff_atrac3p_init_vlcs(AVCodec *codec) · 81 unmodified lines
82{82{
83 int i, wl_vlc_offs, ct_vlc_offs, sf_vlc_offs, tab_offset;83 int i, wl_vlc_offs, ct_vlc_offs, sf_vlc_offs, tab_offset;
84 84
85 static int wl_nb_bits[4] = { 2, 3, 5, 5 };85 static const int wl_nb_bits[4] = { 2, 3, 5, 5 };
86 static int wl_nb_codes[4] = { 3, 5, 8, 8 };86 static const int wl_nb_codes[4] = { 3, 5, 8, 8 };
87 static const uint8_t *wl_bits[4] = {87 static const uint8_t * const wl_bits[4] = {
88 atrac3p_wl_huff_bits1, atrac3p_wl_huff_bits2,88 atrac3p_wl_huff_bits1, atrac3p_wl_huff_bits2,
89 atrac3p_wl_huff_bits3, atrac3p_wl_huff_bits489 atrac3p_wl_huff_bits3, atrac3p_wl_huff_bits4
90 };90 };
91 static const uint8_t *wl_codes[4] = {91 static const uint8_t * const wl_codes[4] = {
92 atrac3p_wl_huff_code1, atrac3p_wl_huff_code2,92 atrac3p_wl_huff_code1, atrac3p_wl_huff_code2,
93 atrac3p_wl_huff_code3, atrac3p_wl_huff_code493 atrac3p_wl_huff_code3, atrac3p_wl_huff_code4
94 };94 };
95 static const uint8_t *wl_xlats[4] = {95 static const uint8_t * const wl_xlats[4] = {
96 atrac3p_wl_huff_xlat1, atrac3p_wl_huff_xlat2, NULL, NULL96 atrac3p_wl_huff_xlat1, atrac3p_wl_huff_xlat2, NULL, NULL
97 };97 };
98 98
99 static int ct_nb_bits[4] = { 3, 4, 4, 4 };99 static const int ct_nb_bits[4] = { 3, 4, 4, 4 };
100 static int ct_nb_codes[4] = { 4, 8, 8, 8 };100 static const int ct_nb_codes[4] = { 4, 8, 8, 8 };
101 static const uint8_t *ct_bits[4] = {101 static const uint8_t * const ct_bits[4] = {
102 atrac3p_ct_huff_bits1, atrac3p_ct_huff_bits2,102 atrac3p_ct_huff_bits1, atrac3p_ct_huff_bits2,
103 atrac3p_ct_huff_bits2, atrac3p_ct_huff_bits3103 atrac3p_ct_huff_bits2, atrac3p_ct_huff_bits3
104 };104 };
105 static const uint8_t *ct_codes[4] = {105 static const uint8_t * const ct_codes[4] = {
106 atrac3p_ct_huff_code1, atrac3p_ct_huff_code2,106 atrac3p_ct_huff_code1, atrac3p_ct_huff_code2,
107 atrac3p_ct_huff_code2, atrac3p_ct_huff_code3107 atrac3p_ct_huff_code2, atrac3p_ct_huff_code3
108 };108 };
109 static const uint8_t *ct_xlats[4] = {109 static const uint8_t * const ct_xlats[4] = {
110 NULL, NULL, atrac3p_ct_huff_xlat1, NULL110 NULL, NULL, atrac3p_ct_huff_xlat1, NULL
111 };111 };
112 112
113 static int sf_nb_bits[8] = { 9, 9, 9, 9, 6, 6, 7, 7 };113 static const int sf_nb_bits[8] = { 9, 9, 9, 9, 6, 6, 7, 7 };
114 static int sf_nb_codes[8] = { 64, 64, 64, 64, 16, 16, 16, 16 };114 static const int sf_nb_codes[8] = { 64, 64, 64, 64, 16, 16, 16, 16 };
115 static const uint8_t *sf_bits[8] = {115 static const uint8_t * const sf_bits[8] = {
116 atrac3p_sf_huff_bits1, atrac3p_sf_huff_bits1, atrac3p_sf_huff_bits2,116 atrac3p_sf_huff_bits1, atrac3p_sf_huff_bits1, atrac3p_sf_huff_bits2,
117 atrac3p_sf_huff_bits3, atrac3p_sf_huff_bits4, atrac3p_sf_huff_bits4,117 atrac3p_sf_huff_bits3, atrac3p_sf_huff_bits4, atrac3p_sf_huff_bits4,
118 atrac3p_sf_huff_bits5, atrac3p_sf_huff_bits6118 atrac3p_sf_huff_bits5, atrac3p_sf_huff_bits6
119 };119 };
120 static const uint16_t *sf_codes[8] = {120 static const uint16_t * const sf_codes[8] = {
121 atrac3p_sf_huff_code1, atrac3p_sf_huff_code1, atrac3p_sf_huff_code2,121 atrac3p_sf_huff_code1, atrac3p_sf_huff_code1, atrac3p_sf_huff_code2,
122 atrac3p_sf_huff_code3, atrac3p_sf_huff_code4, atrac3p_sf_huff_code4,122 atrac3p_sf_huff_code3, atrac3p_sf_huff_code4, atrac3p_sf_huff_code4,
123 atrac3p_sf_huff_code5, atrac3p_sf_huff_code6123 atrac3p_sf_huff_code5, atrac3p_sf_huff_code6
124 };124 };
125 static const uint8_t *sf_xlats[8] = {125 static const uint8_t * const sf_xlats[8] = {
126 atrac3p_sf_huff_xlat1, atrac3p_sf_huff_xlat2, NULL, NULL,126 atrac3p_sf_huff_xlat1, atrac3p_sf_huff_xlat2, NULL, NULL,
127 atrac3p_sf_huff_xlat4, atrac3p_sf_huff_xlat5, NULL, NULL127 atrac3p_sf_huff_xlat4, atrac3p_sf_huff_xlat5, NULL, NULL
128 };128 };
129 129
130 static const uint8_t *gain_cbs[11] = {130 static const uint8_t * const gain_cbs[11] = {
131 atrac3p_huff_gain_npoints1_cb, atrac3p_huff_gain_npoints1_cb,131 atrac3p_huff_gain_npoints1_cb, atrac3p_huff_gain_npoints1_cb,
132 atrac3p_huff_gain_lev1_cb, atrac3p_huff_gain_lev2_cb,132 atrac3p_huff_gain_lev1_cb, atrac3p_huff_gain_lev2_cb,
133 atrac3p_huff_gain_lev3_cb, atrac3p_huff_gain_lev4_cb,133 atrac3p_huff_gain_lev3_cb, atrac3p_huff_gain_lev4_cb,
@@ -135,7 +135,7 @@ av_cold void ff_atrac3p_init_vlcs(AVCodec *codec) · 1 unmodified line
135 atrac3p_huff_gain_loc4_cb, atrac3p_huff_gain_loc2_cb,135 atrac3p_huff_gain_loc4_cb, atrac3p_huff_gain_loc2_cb,
136 atrac3p_huff_gain_loc5_cb136 atrac3p_huff_gain_loc5_cb
137 };137 };
138 static const uint8_t *gain_xlats[11] = {138 static const uint8_t * const gain_xlats[11] = {
139 NULL, atrac3p_huff_gain_npoints2_xlat, atrac3p_huff_gain_lev1_xlat,139 NULL, atrac3p_huff_gain_npoints2_xlat, atrac3p_huff_gain_lev1_xlat,
140 atrac3p_huff_gain_lev2_xlat, atrac3p_huff_gain_lev3_xlat,140 atrac3p_huff_gain_lev2_xlat, atrac3p_huff_gain_lev3_xlat,
141 atrac3p_huff_gain_lev4_xlat, atrac3p_huff_gain_loc3_xlat,141 atrac3p_huff_gain_lev4_xlat, atrac3p_huff_gain_loc3_xlat,
@@ -143,13 +143,13 @@ av_cold void ff_atrac3p_init_vlcs(AVCodec *codec) · 1 unmodified line
143 atrac3p_huff_gain_loc2_xlat, atrac3p_huff_gain_loc5_xlat143 atrac3p_huff_gain_loc2_xlat, atrac3p_huff_gain_loc5_xlat
144 };144 };
145 145
146 static const uint8_t *tone_cbs[7] = {146 static const uint8_t * const tone_cbs[7] = {
147 atrac3p_huff_tonebands_cb, atrac3p_huff_numwavs1_cb,147 atrac3p_huff_tonebands_cb, atrac3p_huff_numwavs1_cb,
148 atrac3p_huff_numwavs2_cb, atrac3p_huff_wav_ampsf1_cb,148 atrac3p_huff_numwavs2_cb, atrac3p_huff_wav_ampsf1_cb,
149 atrac3p_huff_wav_ampsf2_cb, atrac3p_huff_wav_ampsf3_cb,149 atrac3p_huff_wav_ampsf2_cb, atrac3p_huff_wav_ampsf3_cb,
150 atrac3p_huff_freq_cb150 atrac3p_huff_freq_cb
151 };151 };
152 static const uint8_t *tone_xlats[7] = {152 static const uint8_t * const tone_xlats[7] = {
153 NULL, NULL, atrac3p_huff_numwavs2_xlat, atrac3p_huff_wav_ampsf1_xlat,153 NULL, NULL, atrac3p_huff_numwavs2_xlat, atrac3p_huff_wav_ampsf1_xlat,
154 atrac3p_huff_wav_ampsf2_xlat, atrac3p_huff_wav_ampsf3_xlat,154 atrac3p_huff_wav_ampsf2_xlat, atrac3p_huff_wav_ampsf3_xlat,
155 atrac3p_huff_freq_xlat155 atrac3p_huff_freq_xlat
libavcodec/dfa.c+1−1
@@ -322,7 +322,7 @@ static const chunk_decoder decoder[8] = { · 321 unmodified lines
322 decode_tdlt, decode_dsw1, decode_blck, decode_dds1,322 decode_tdlt, decode_dsw1, decode_blck, decode_dds1,
323};323};
324 324
325static const char* chunk_name[8] = {325static const char * const chunk_name[8] = {
326 "COPY", "TSW1", "BDLT", "WDLT", "TDLT", "DSW1", "BLCK", "DDS1"326 "COPY", "TSW1", "BDLT", "WDLT", "TDLT", "DSW1", "BLCK", "DDS1"
327};327};
328 328
libavcodec/g722dec.c+3−3
@@ -80,9 +80,9 @@ static const int16_t low_inv_quant5[32] = { · 79 unmodified lines
80 587, 473, 370, 276, 190, 110, 35, -3580 587, 473, 370, 276, 190, 110, 35, -35
81};81};
82 82
83static const int16_t *low_inv_quants[3] = { ff_g722_low_inv_quant6,83static const int16_t * const low_inv_quants[3] = { ff_g722_low_inv_quant6,
84 low_inv_quant5,84 low_inv_quant5,
85 ff_g722_low_inv_quant4 };85 ff_g722_low_inv_quant4 };
86 86
87static int g722_decode_frame(AVCodecContext *avctx, void *data,87static int g722_decode_frame(AVCodecContext *avctx, void *data,
88 int *got_frame_ptr, AVPacket *avpkt)88 int *got_frame_ptr, AVPacket *avpkt)
libavcodec/h263data.c+2−2
@@ -264,11 +264,11 @@ const uint8_t ff_h263_chroma_qscale_table[32] = { · 263 unmodified lines
264 0, 1, 2, 3, 4, 5, 6, 6, 7, 8, 9, 9, 10, 10, 11, 11, 12, 12, 12, 13, 13, 13, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15264 0, 1, 2, 3, 4, 5, 6, 6, 7, 8, 9, 9, 10, 10, 11, 11, 12, 12, 12, 13, 13, 13, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15
265};265};
266 266
267uint16_t ff_mba_max[6] = {267const uint16_t ff_mba_max[6] = {
268 47, 98, 395, 1583, 6335, 9215268 47, 98, 395, 1583, 6335, 9215
269};269};
270 270
271uint8_t ff_mba_length[7] = {271const uint8_t ff_mba_length[7] = {
272 6, 7, 9, 11, 13, 14, 14272 6, 7, 9, 11, 13, 14, 14
273};273};
274 274
libavcodec/h263data.h+2−2
@@ -71,7 +71,7 @@ extern const uint8_t ff_modified_quant_tab[2][32]; · 70 unmodified lines
71 71
72extern const uint8_t ff_h263_chroma_qscale_table[32];72extern const uint8_t ff_h263_chroma_qscale_table[32];
73 73
74extern uint16_t ff_mba_max[6];74extern const uint16_t ff_mba_max[6];
75extern uint8_t ff_mba_length[7];75extern const uint8_t ff_mba_length[7];
76 76
77#endif /* AVCODEC_H263DATA_H */77#endif /* AVCODEC_H263DATA_H */
libavcodec/indeo3.c+2−2
@@ -118,8 +118,8 @@ static uint8_t requant_tab[8][128]; · 117 unmodified lines
118 */118 */
119static av_cold void build_requant_tab(void)119static av_cold void build_requant_tab(void)
120{120{
121 static int8_t offsets[8] = { 1, 1, 2, -3, -3, 3, 4, 4 };121 static const int8_t offsets[8] = { 1, 1, 2, -3, -3, 3, 4, 4 };
122 static int8_t deltas [8] = { 0, 1, 0, 4, 4, 1, 0, 1 };122 static const int8_t deltas [8] = { 0, 1, 0, 4, 4, 1, 0, 1 };
123 123
124 int i, j, step;124 int i, j, step;
125 125
libavcodec/indeo4data.h+1−1
@@ -60,7 +60,7 @@ static const uint8_t ivi4_horizontal_scan_4x4[16] = { · 59 unmodified lines
60 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 1560 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15
61};61};
62 62
63static const uint8_t *scan_index_to_tab[15] = {63static const uint8_t * const scan_index_to_tab[15] = {
64 // for 8x8 transforms64 // for 8x8 transforms
65 ff_zigzag_direct,65 ff_zigzag_direct,
66 ivi4_alternate_scan_8x8,66 ivi4_alternate_scan_8x8,
libavcodec/mpeg4videodec.c+1−1
@@ -1274,7 +1274,7 @@ static int mpeg4_decode_mb(MpegEncContext *s, int16_t block[6][64]) · 1273 unmodified lines
1274 Mpeg4DecContext *ctx = (Mpeg4DecContext *)s;1274 Mpeg4DecContext *ctx = (Mpeg4DecContext *)s;
1275 int cbpc, cbpy, i, cbp, pred_x, pred_y, mx, my, dquant;1275 int cbpc, cbpy, i, cbp, pred_x, pred_y, mx, my, dquant;
1276 int16_t *mot_val;1276 int16_t *mot_val;
1277 static int8_t quant_tab[4] = { -1, -2, 1, 2 };1277 static const int8_t quant_tab[4] = { -1, -2, 1, 2 };
1278 const int xy = s->mb_x + s->mb_y * s->mb_stride;1278 const int xy = s->mb_x + s->mb_y * s->mb_stride;
1279 1279
1280 assert(s->h263_pred);1280 assert(s->h263_pred);
libavcodec/on2avc.c+2−2
@@ -320,7 +320,7 @@ static void zero_head_and_tail(float *src, int len, int order0, int order1) · 319 unmodified lines
320}320}
321 321
322static void pretwiddle(float *src, float *dst, int dst_len, int tab_step,322static void pretwiddle(float *src, float *dst, int dst_len, int tab_step,
323 int step, int order0, int order1, const double **tabs)323 int step, int order0, int order1, const double * const *tabs)
324{324{
325 float *src2, *out;325 float *src2, *out;
326 const double *tab;326 const double *tab;
@@ -348,7 +348,7 @@ static void pretwiddle(float *src, float *dst, int dst_len, int tab_step, · 21 unmodified lines
348 348
349static void twiddle(float *src1, float *src2, int src2_len,349static void twiddle(float *src1, float *src2, int src2_len,
350 const double *tab, int tab_len, int step,350 const double *tab, int tab_len, int step,
351 int order0, int order1, const double **tabs)351 int order0, int order1, const double * const *tabs)
352{352{
353 int steps;353 int steps;
354 int mask;354 int mask;
libavcodec/on2avcdata.c+10−10
@@ -7641,11 +7641,11 @@ static const double tabs_4_10[4 * 2][10] = { · 7640 unmodified lines
7641 -0.099339873, -0.041293536, 0.31028851, 0.17727433, -0.92756648 }7641 -0.099339873, -0.041293536, 0.31028851, 0.17727433, -0.92756648 }
7642};7642};
7643 7643
7644const double *ff_on2avc_tabs_4_10_1[4] = {7644const double * const ff_on2avc_tabs_4_10_1[4] = {
7645 tabs_4_10[0], tabs_4_10[1], tabs_4_10[2], tabs_4_10[3]7645 tabs_4_10[0], tabs_4_10[1], tabs_4_10[2], tabs_4_10[3]
7646};7646};
7647 7647
7648const double *ff_on2avc_tabs_4_10_2[4] = {7648const double * const ff_on2avc_tabs_4_10_2[4] = {
7649 tabs_4_10[4], tabs_4_10[5], tabs_4_10[6], tabs_4_10[7]7649 tabs_4_10[4], tabs_4_10[5], tabs_4_10[6], tabs_4_10[7]
7650};7650};
7651 7651
@@ -7724,12 +7724,12 @@ static const double tabs_9_20[9 * 2][20] = { · 72 unmodified lines
7724 0.22783, 0.058894795, -0.61350902, 0.69559873, -0.27013783, }7724 0.22783, 0.058894795, -0.61350902, 0.69559873, -0.27013783, }
7725};7725};
7726 7726
7727const double* ff_on2avc_tabs_9_20_1[9] = {7727const double * const ff_on2avc_tabs_9_20_1[9] = {
7728 tabs_9_20[0], tabs_9_20[1], tabs_9_20[2], tabs_9_20[3], tabs_9_20[4],7728 tabs_9_20[0], tabs_9_20[1], tabs_9_20[2], tabs_9_20[3], tabs_9_20[4],
7729 tabs_9_20[5], tabs_9_20[6], tabs_9_20[7], tabs_9_20[8]7729 tabs_9_20[5], tabs_9_20[6], tabs_9_20[7], tabs_9_20[8]
7730};7730};
7731 7731
7732const double* ff_on2avc_tabs_9_20_2[9] = {7732const double * const ff_on2avc_tabs_9_20_2[9] = {
7733 tabs_9_20[ 9], tabs_9_20[10], tabs_9_20[11], tabs_9_20[12], tabs_9_20[13],7733 tabs_9_20[ 9], tabs_9_20[10], tabs_9_20[11], tabs_9_20[12], tabs_9_20[13],
7734 tabs_9_20[14], tabs_9_20[15], tabs_9_20[16], tabs_9_20[17]7734 tabs_9_20[14], tabs_9_20[15], tabs_9_20[16], tabs_9_20[17]
7735};7735};
@@ -7927,7 +7927,7 @@ static const double tabs_19_40[19 * 2][40] = { · 191 unmodified lines
7927 0.019871848, -0.11989559, 0.036659135, 0.26632201, -0.3057397, -0.23220335, 0.68741352, -0.54024027, }7927 0.019871848, -0.11989559, 0.036659135, 0.26632201, -0.3057397, -0.23220335, 0.68741352, -0.54024027, }
7928};7928};
7929 7929
7930const double* ff_on2avc_tabs_19_40_1[19] = {7930const double * const ff_on2avc_tabs_19_40_1[19] = {
7931 tabs_19_40[ 0], tabs_19_40[ 1], tabs_19_40[ 2], tabs_19_40[ 3],7931 tabs_19_40[ 0], tabs_19_40[ 1], tabs_19_40[ 2], tabs_19_40[ 3],
7932 tabs_19_40[ 4], tabs_19_40[ 5], tabs_19_40[ 6], tabs_19_40[ 7],7932 tabs_19_40[ 4], tabs_19_40[ 5], tabs_19_40[ 6], tabs_19_40[ 7],
7933 tabs_19_40[ 8], tabs_19_40[ 9], tabs_19_40[10], tabs_19_40[11],7933 tabs_19_40[ 8], tabs_19_40[ 9], tabs_19_40[10], tabs_19_40[11],
@@ -7935,7 +7935,7 @@ const double* ff_on2avc_tabs_19_40_1[19] = { · 1 unmodified line
7935 tabs_19_40[16], tabs_19_40[17], tabs_19_40[18],7935 tabs_19_40[16], tabs_19_40[17], tabs_19_40[18],
7936};7936};
7937 7937
7938const double* ff_on2avc_tabs_19_40_2[19] = {7938const double * const ff_on2avc_tabs_19_40_2[19] = {
7939 tabs_19_40[19], tabs_19_40[20], tabs_19_40[21], tabs_19_40[22],7939 tabs_19_40[19], tabs_19_40[20], tabs_19_40[21], tabs_19_40[22],
7940 tabs_19_40[23], tabs_19_40[24], tabs_19_40[25], tabs_19_40[26],7940 tabs_19_40[23], tabs_19_40[24], tabs_19_40[25], tabs_19_40[26],
7941 tabs_19_40[27], tabs_19_40[28], tabs_19_40[29], tabs_19_40[30],7941 tabs_19_40[27], tabs_19_40[28], tabs_19_40[29], tabs_19_40[30],
@@ -8826,7 +8826,7 @@ static const double tabs_20_84[20 * 4][84] = { · 884 unmodified lines
8826 0.51434408, -0.41486443, 0.27672635, -0.10432054, },8826 0.51434408, -0.41486443, 0.27672635, -0.10432054, },
8827};8827};
8828 8828
8829const double* ff_on2avc_tabs_20_84_1[20] = {8829const double * const ff_on2avc_tabs_20_84_1[20] = {
8830 tabs_20_84[ 0], tabs_20_84[ 1], tabs_20_84[ 2], tabs_20_84[ 3],8830 tabs_20_84[ 0], tabs_20_84[ 1], tabs_20_84[ 2], tabs_20_84[ 3],
8831 tabs_20_84[ 4], tabs_20_84[ 5], tabs_20_84[ 6], tabs_20_84[ 7],8831 tabs_20_84[ 4], tabs_20_84[ 5], tabs_20_84[ 6], tabs_20_84[ 7],
8832 tabs_20_84[ 8], tabs_20_84[ 9], tabs_20_84[10], tabs_20_84[11],8832 tabs_20_84[ 8], tabs_20_84[ 9], tabs_20_84[10], tabs_20_84[11],
@@ -8834,7 +8834,7 @@ const double* ff_on2avc_tabs_20_84_1[20] = { · 1 unmodified line
8834 tabs_20_84[16], tabs_20_84[17], tabs_20_84[18], tabs_20_84[19]8834 tabs_20_84[16], tabs_20_84[17], tabs_20_84[18], tabs_20_84[19]
8835};8835};
8836 8836
8837const double* ff_on2avc_tabs_20_84_2[20] = {8837const double * const ff_on2avc_tabs_20_84_2[20] = {
8838 tabs_20_84[20], tabs_20_84[21], tabs_20_84[22], tabs_20_84[23],8838 tabs_20_84[20], tabs_20_84[21], tabs_20_84[22], tabs_20_84[23],
8839 tabs_20_84[24], tabs_20_84[25], tabs_20_84[26], tabs_20_84[27],8839 tabs_20_84[24], tabs_20_84[25], tabs_20_84[26], tabs_20_84[27],
8840 tabs_20_84[28], tabs_20_84[29], tabs_20_84[30], tabs_20_84[31],8840 tabs_20_84[28], tabs_20_84[29], tabs_20_84[30], tabs_20_84[31],
@@ -8842,7 +8842,7 @@ const double* ff_on2avc_tabs_20_84_2[20] = { · 1 unmodified line
8842 tabs_20_84[36], tabs_20_84[37], tabs_20_84[38], tabs_20_84[39]8842 tabs_20_84[36], tabs_20_84[37], tabs_20_84[38], tabs_20_84[39]
8843};8843};
8844 8844
8845const double* ff_on2avc_tabs_20_84_3[20] = {8845const double * const ff_on2avc_tabs_20_84_3[20] = {
8846 tabs_20_84[40], tabs_20_84[41], tabs_20_84[42], tabs_20_84[43],8846 tabs_20_84[40], tabs_20_84[41], tabs_20_84[42], tabs_20_84[43],
8847 tabs_20_84[44], tabs_20_84[45], tabs_20_84[46], tabs_20_84[47],8847 tabs_20_84[44], tabs_20_84[45], tabs_20_84[46], tabs_20_84[47],
8848 tabs_20_84[48], tabs_20_84[49], tabs_20_84[50], tabs_20_84[51],8848 tabs_20_84[48], tabs_20_84[49], tabs_20_84[50], tabs_20_84[51],
@@ -8850,7 +8850,7 @@ const double* ff_on2avc_tabs_20_84_3[20] = { · 1 unmodified line
8850 tabs_20_84[56], tabs_20_84[57], tabs_20_84[58], tabs_20_84[59]8850 tabs_20_84[56], tabs_20_84[57], tabs_20_84[58], tabs_20_84[59]
8851};8851};
8852 8852
8853const double* ff_on2avc_tabs_20_84_4[20] = {8853const double * const ff_on2avc_tabs_20_84_4[20] = {
8854 tabs_20_84[60], tabs_20_84[61], tabs_20_84[62], tabs_20_84[63],8854 tabs_20_84[60], tabs_20_84[61], tabs_20_84[62], tabs_20_84[63],
8855 tabs_20_84[64], tabs_20_84[65], tabs_20_84[66], tabs_20_84[67],8855 tabs_20_84[64], tabs_20_84[65], tabs_20_84[66], tabs_20_84[67],
8856 tabs_20_84[68], tabs_20_84[69], tabs_20_84[70], tabs_20_84[71],8856 tabs_20_84[68], tabs_20_84[69], tabs_20_84[70], tabs_20_84[71],
libavcodec/on2avcdata.h+10−10
@@ -64,16 +64,16 @@ extern const double ff_on2avc_tab_84_1[]; · 63 unmodified lines
64extern const double ff_on2avc_tab_84_2[];64extern const double ff_on2avc_tab_84_2[];
65extern const double ff_on2avc_tab_84_3[];65extern const double ff_on2avc_tab_84_3[];
66extern const double ff_on2avc_tab_84_4[];66extern const double ff_on2avc_tab_84_4[];
67extern const double* ff_on2avc_tabs_4_10_1[4];67extern const double * const ff_on2avc_tabs_4_10_1[4];
68extern const double* ff_on2avc_tabs_4_10_2[4];68extern const double * const ff_on2avc_tabs_4_10_2[4];
69extern const double* ff_on2avc_tabs_9_20_1[9];69extern const double * const ff_on2avc_tabs_9_20_1[9];
70extern const double* ff_on2avc_tabs_9_20_2[9];70extern const double * const ff_on2avc_tabs_9_20_2[9];
71extern const double* ff_on2avc_tabs_19_40_1[19];71extern const double * const ff_on2avc_tabs_19_40_1[19];
72extern const double* ff_on2avc_tabs_19_40_2[19];72extern const double * const ff_on2avc_tabs_19_40_2[19];
73extern const double* ff_on2avc_tabs_20_84_1[20];73extern const double * const ff_on2avc_tabs_20_84_1[20];
74extern const double* ff_on2avc_tabs_20_84_2[20];74extern const double * const ff_on2avc_tabs_20_84_2[20];
75extern const double* ff_on2avc_tabs_20_84_3[20];75extern const double * const ff_on2avc_tabs_20_84_3[20];
76extern const double* ff_on2avc_tabs_20_84_4[20];76extern const double * const ff_on2avc_tabs_20_84_4[20];
77extern const float ff_on2avc_ctab_1[2048];77extern const float ff_on2avc_ctab_1[2048];
78extern const float ff_on2avc_ctab_2[2048];78extern const float ff_on2avc_ctab_2[2048];
79extern const float ff_on2avc_ctab_3[2048];79extern const float ff_on2avc_ctab_3[2048];
libavcodec/opus_silk.c+3−3
@@ -1323,7 +1323,7 @@ static void silk_decode_frame(SilkContext *s, OpusRangeCoder *rc, · 1322 unmodified lines
1323 if (lag_absolute) {1323 if (lag_absolute) {
1324 /* primary lag is coded absolute */1324 /* primary lag is coded absolute */
1325 int highbits, lowbits;1325 int highbits, lowbits;
1326 static const uint16_t *model[] = {1326 static const uint16_t * const model[] = {
1327 silk_model_pitch_lowbits_nb, silk_model_pitch_lowbits_mb,1327 silk_model_pitch_lowbits_nb, silk_model_pitch_lowbits_mb,
1328 silk_model_pitch_lowbits_wb1328 silk_model_pitch_lowbits_wb
1329 };1329 };
@@ -1357,11 +1357,11 @@ static void silk_decode_frame(SilkContext *s, OpusRangeCoder *rc, · 27 unmodified lines
1357 ltpfilter = opus_rc_getsymbol(rc, silk_model_ltp_filter);1357 ltpfilter = opus_rc_getsymbol(rc, silk_model_ltp_filter);
1358 for (i = 0; i < s->subframes; i++) {1358 for (i = 0; i < s->subframes; i++) {
1359 int index, j;1359 int index, j;
1360 static const uint16_t *filter_sel[] = {1360 static const uint16_t * const filter_sel[] = {
1361 silk_model_ltp_filter0_sel, silk_model_ltp_filter1_sel,1361 silk_model_ltp_filter0_sel, silk_model_ltp_filter1_sel,
1362 silk_model_ltp_filter2_sel1362 silk_model_ltp_filter2_sel
1363 };1363 };
1364 static const int8_t (*filter_taps[])[5] = {1364 static const int8_t (* const filter_taps[])[5] = {
1365 silk_ltp_filter0_taps, silk_ltp_filter1_taps, silk_ltp_filter2_taps1365 silk_ltp_filter0_taps, silk_ltp_filter1_taps, silk_ltp_filter2_taps
1366 };1366 };
1367 index = opus_rc_getsymbol(rc, filter_sel[ltpfilter]);1367 index = opus_rc_getsymbol(rc, filter_sel[ltpfilter]);
libavcodec/qsvdec_h2645.c+2−2
@@ -84,8 +84,8 @@ static av_cold int qsv_decode_init(AVCodecContext *avctx) · 83 unmodified lines
84 int ret;84 int ret;
85 85
86 if (avctx->codec_id == AV_CODEC_ID_HEVC && s->load_plugin != LOAD_PLUGIN_NONE) {86 if (avctx->codec_id == AV_CODEC_ID_HEVC && s->load_plugin != LOAD_PLUGIN_NONE) {
87 static const char *uid_hevcdec_sw = "15dd936825ad475ea34e35f3f54217a6";87 static const char * const uid_hevcdec_sw = "15dd936825ad475ea34e35f3f54217a6";
88 static const char *uid_hevcdec_hw = "33a61c0b4c27454ca8d85dde757c6f8e";88 static const char * const uid_hevcdec_hw = "33a61c0b4c27454ca8d85dde757c6f8e";
89 89
90 if (s->qsv.load_plugins[0]) {90 if (s->qsv.load_plugins[0]) {
91 av_log(avctx, AV_LOG_WARNING,91 av_log(avctx, AV_LOG_WARNING,
libavcodec/qsvenc_hevc.c+2−2
@@ -161,8 +161,8 @@ static av_cold int qsv_enc_init(AVCodecContext *avctx) · 160 unmodified lines
161 int ret;161 int ret;
162 162
163 if (q->load_plugin != LOAD_PLUGIN_NONE) {163 if (q->load_plugin != LOAD_PLUGIN_NONE) {
164 static const char *uid_hevcenc_sw = "2fca99749fdb49aeb121a5b63ef568f7";164 static const char * const uid_hevcenc_sw = "2fca99749fdb49aeb121a5b63ef568f7";
165 static const char *uid_hevcenc_hw = "6fadc791a0c2eb479ab6dcd5ea9da347";165 static const char * const uid_hevcenc_hw = "6fadc791a0c2eb479ab6dcd5ea9da347";
166 166
167 if (q->qsv.load_plugins[0]) {167 if (q->qsv.load_plugins[0]) {
168 av_log(avctx, AV_LOG_WARNING,168 av_log(avctx, AV_LOG_WARNING,
libavcodec/sipr.c+1−1
@@ -139,7 +139,7 @@ const float ff_pow_0_5[] = { · 138 unmodified lines
139 1.0/(1 << 13), 1.0/(1 << 14), 1.0/(1 << 15), 1.0/(1 << 16)139 1.0/(1 << 13), 1.0/(1 << 14), 1.0/(1 << 15), 1.0/(1 << 16)
140};140};
141 141
142static void dequant(float *out, const int *idx, const float *cbs[])142static void dequant(float *out, const int *idx, const float * const cbs[])
143{143{
144 int i;144 int i;
145 int stride = 2;145 int stride = 2;
libavcodec/sipr16k.c+1−1
@@ -51,7 +51,7 @@ static void lsf2lsp(const float *lsf, double *lsp) · 50 unmodified lines
51 lsp[i] = cosf(lsf[i]);51 lsp[i] = cosf(lsf[i]);
52}52}
53 53
54static void dequant(float *out, const int *idx, const float *cbs[])54static void dequant(float *out, const int *idx, const float * const cbs[])
55{55{
56 int i;56 int i;
57 57
libavcodec/sipr16kdata.h+1−1
@@ -525,7 +525,7 @@ static const float lsf_cb5_16k[128][4] = { · 524 unmodified lines
525 { 0.124405, 0.009943, -0.148477, -0.205184}525 { 0.124405, 0.009943, -0.148477, -0.205184}
526};526};
527 527
528static const float *lsf_codebooks_16k[] = {528static const float * const lsf_codebooks_16k[] = {
529 lsf_cb1_16k[0], lsf_cb2_16k[0], lsf_cb3_16k[0], lsf_cb4_16k[0],529 lsf_cb1_16k[0], lsf_cb2_16k[0], lsf_cb3_16k[0], lsf_cb4_16k[0],
530 lsf_cb5_16k[0]530 lsf_cb5_16k[0]
531};531};
libavcodec/siprdata.h+1−1
@@ -206,7 +206,7 @@ static const float lsf_cb5[32][2] = { · 205 unmodified lines
206 { 0.150514, 0.034366}, { 0.186092, -0.069272}206 { 0.150514, 0.034366}, { 0.186092, -0.069272}
207};207};
208 208
209static const float *lsf_codebooks[] = {209static const float * const lsf_codebooks[] = {
210 lsf_cb1[0], lsf_cb2[0], lsf_cb3[0], lsf_cb4[0], lsf_cb5[0]210 lsf_cb1[0], lsf_cb2[0], lsf_cb3[0], lsf_cb4[0], lsf_cb5[0]
211};211};
212 212
libavcodec/tscc2data.h+3−3
@@ -903,14 +903,14 @@ static const int tscc2_ac_vlc_sizes[NUM_VLC_SETS] = { · 902 unmodified lines
903 172, 169, 165, 162, 131, 132, 130, 125, 121, 114, 110, 101, 96903 172, 169, 165, 162, 131, 132, 130, 125, 121, 114, 110, 101, 96
904};904};
905 905
906static const uint16_t *tscc2_ac_vlc_syms[NUM_VLC_SETS] = {906static const uint16_t * const tscc2_ac_vlc_syms[NUM_VLC_SETS] = {
907 ac_vlc_desc0_syms, ac_vlc_desc1_syms, ac_vlc_desc2_syms, ac_vlc_desc3_syms,907 ac_vlc_desc0_syms, ac_vlc_desc1_syms, ac_vlc_desc2_syms, ac_vlc_desc3_syms,
908 ac_vlc_desc4_syms, ac_vlc_desc5_syms, ac_vlc_desc6_syms, ac_vlc_desc7_syms,908 ac_vlc_desc4_syms, ac_vlc_desc5_syms, ac_vlc_desc6_syms, ac_vlc_desc7_syms,
909 ac_vlc_desc8_syms, ac_vlc_desc9_syms, ac_vlc_descA_syms, ac_vlc_descB_syms,909 ac_vlc_desc8_syms, ac_vlc_desc9_syms, ac_vlc_descA_syms, ac_vlc_descB_syms,
910 ac_vlc_descC_syms,910 ac_vlc_descC_syms,
911};911};
912 912
913static const uint16_t *tscc2_ac_vlc_codes[NUM_VLC_SETS] = {913static const uint16_t * const tscc2_ac_vlc_codes[NUM_VLC_SETS] = {
914 ac_vlc_desc0_codes, ac_vlc_desc1_codes, ac_vlc_desc2_codes,914 ac_vlc_desc0_codes, ac_vlc_desc1_codes, ac_vlc_desc2_codes,
915 ac_vlc_desc3_codes, ac_vlc_desc4_codes, ac_vlc_desc5_codes,915 ac_vlc_desc3_codes, ac_vlc_desc4_codes, ac_vlc_desc5_codes,
916 ac_vlc_desc6_codes, ac_vlc_desc7_codes, ac_vlc_desc8_codes,916 ac_vlc_desc6_codes, ac_vlc_desc7_codes, ac_vlc_desc8_codes,
@@ -918,7 +918,7 @@ static const uint16_t *tscc2_ac_vlc_codes[NUM_VLC_SETS] = { · 1 unmodified line
918 ac_vlc_descC_codes,918 ac_vlc_descC_codes,
919};919};
920 920
921static const uint8_t *tscc2_ac_vlc_bits[NUM_VLC_SETS] = {921static const uint8_t * const tscc2_ac_vlc_bits[NUM_VLC_SETS] = {
922 ac_vlc_desc0_bits, ac_vlc_desc1_bits, ac_vlc_desc2_bits, ac_vlc_desc3_bits,922 ac_vlc_desc0_bits, ac_vlc_desc1_bits, ac_vlc_desc2_bits, ac_vlc_desc3_bits,
923 ac_vlc_desc4_bits, ac_vlc_desc5_bits, ac_vlc_desc6_bits, ac_vlc_desc7_bits,923 ac_vlc_desc4_bits, ac_vlc_desc5_bits, ac_vlc_desc6_bits, ac_vlc_desc7_bits,
924 ac_vlc_desc8_bits, ac_vlc_desc9_bits, ac_vlc_descA_bits, ac_vlc_descB_bits,924 ac_vlc_desc8_bits, ac_vlc_desc9_bits, ac_vlc_descA_bits, ac_vlc_descB_bits,
libavcodec/vaapi_encode.c+1−1
@@ -27,7 +27,7 @@ · 26 unmodified lines
27#include "vaapi_encode.h"27#include "vaapi_encode.h"
28#include "avcodec.h"28#include "avcodec.h"
29 29
30static const char *picture_type_name[] = { "IDR", "I", "P", "B" };30static const char * const picture_type_name[] = { "IDR", "I", "P", "B" };
31 31
32static int vaapi_encode_make_packed_header(AVCodecContext *avctx,32static int vaapi_encode_make_packed_header(AVCodecContext *avctx,
33 VAAPIEncodePicture *pic,33 VAAPIEncodePicture *pic,
libavcodec/vaapi_encode_mjpeg.c+1−1
@@ -361,7 +361,7 @@ static av_cold int vaapi_encode_mjpeg_configure(AVCodecContext *avctx) · 360 unmodified lines
361 return 0;361 return 0;
362}362}
363 363
364static VAAPIEncodeType vaapi_encode_type_mjpeg = {364static const VAAPIEncodeType vaapi_encode_type_mjpeg = {
365 .priv_data_size = sizeof(VAAPIEncodeMJPEGContext),365 .priv_data_size = sizeof(VAAPIEncodeMJPEGContext),
366 366
367 .configure = &vaapi_encode_mjpeg_configure,367 .configure = &vaapi_encode_mjpeg_configure,
libavcodec/vp8.c+4−4
@@ -1166,10 +1166,10 @@ void decode_mb_mode(VP8Context *s, VP8Macroblock *mb, int mb_x, int mb_y, · 1165 unmodified lines
1166 uint8_t *segment, uint8_t *ref, int layout, int is_vp7)1166 uint8_t *segment, uint8_t *ref, int layout, int is_vp7)
1167{1167{
1168 VP56RangeCoder *c = &s->c;1168 VP56RangeCoder *c = &s->c;
1169 static const char *vp7_feature_name[] = { "q-index",1169 static const char * const vp7_feature_name[] = { "q-index",
1170 "lf-delta",1170 "lf-delta",
1171 "partial-golden-update",1171 "partial-golden-update",
1172 "blit-pitch" };1172 "blit-pitch" };
1173 if (is_vp7) {1173 if (is_vp7) {
1174 int i;1174 int i;
1175 *segment = 0;1175 *segment = 0;
libavcodec/vp9block.c+2−2
@@ -842,8 +842,8 @@ static int decode_coeffs(AVCodecContext *avctx) · 841 unmodified lines
842 int uvstep1d = 1 << b->uvtx, uvstep = 1 << (b->uvtx * 2), ret;842 int uvstep1d = 1 << b->uvtx, uvstep = 1 << (b->uvtx * 2), ret;
843 int16_t (*qmul)[2] = s->segmentation.feat[b->seg_id].qmul;843 int16_t (*qmul)[2] = s->segmentation.feat[b->seg_id].qmul;
844 int tx = 4 * s->lossless + b->tx;844 int tx = 4 * s->lossless + b->tx;
845 const int16_t **yscans = ff_vp9_scans[tx];845 const int16_t * const *yscans = ff_vp9_scans[tx];
846 const int16_t (**ynbs)[2] = ff_vp9_scans_nb[tx];846 const int16_t (* const * ynbs)[2] = ff_vp9_scans_nb[tx];
847 const int16_t *uvscan = ff_vp9_scans[b->uvtx][DCT_DCT];847 const int16_t *uvscan = ff_vp9_scans[b->uvtx][DCT_DCT];
848 const int16_t (*uvnb)[2] = ff_vp9_scans_nb[b->uvtx][DCT_DCT];848 const int16_t (*uvnb)[2] = ff_vp9_scans_nb[b->uvtx][DCT_DCT];
849 uint8_t *a = &s->above_y_nnz_ctx[col * 2];849 uint8_t *a = &s->above_y_nnz_ctx[col * 2];
libavcodec/vp9data.c+2−2
@@ -483,7 +483,7 @@ const int16_t ff_vp9_default_scan_32x32[1024] = { · 482 unmodified lines
483 924, 925, 956, 926, 957, 988, 927, 958, 989, 1020, 959, 990, 1021, 991, 1022, 1023,483 924, 925, 956, 926, 957, 988, 927, 958, 989, 1020, 959, 990, 1021, 991, 1022, 1023,
484};484};
485 485
486const int16_t *ff_vp9_scans[5][4] = {486const int16_t * const ff_vp9_scans[5][4] = {
487 {487 {
488 ff_vp9_default_scan_4x4, ff_vp9_col_scan_4x4,488 ff_vp9_default_scan_4x4, ff_vp9_col_scan_4x4,
489 ff_vp9_row_scan_4x4, ff_vp9_default_scan_4x4489 ff_vp9_row_scan_4x4, ff_vp9_default_scan_4x4
@@ -1040,7 +1040,7 @@ const int16_t ff_vp9_default_scan_32x32_nb[1024][2] = { · 550 unmodified lines
1040 { 990, 959 }, { 1021, 990 }, { 1022, 991 }, { 0, 0 },1040 { 990, 959 }, { 1021, 990 }, { 1022, 991 }, { 0, 0 },
1041};1041};
1042 1042
1043const int16_t (*ff_vp9_scans_nb[5][4])[2] = {1043const int16_t (* const ff_vp9_scans_nb[5][4])[2] = {
1044 {1044 {
1045 ff_vp9_default_scan_4x4_nb, ff_vp9_col_scan_4x4_nb,1045 ff_vp9_default_scan_4x4_nb, ff_vp9_col_scan_4x4_nb,
1046 ff_vp9_row_scan_4x4_nb, ff_vp9_default_scan_4x4_nb1046 ff_vp9_row_scan_4x4_nb, ff_vp9_default_scan_4x4_nb
libavcodec/vp9data.h+2−2
@@ -48,7 +48,7 @@ extern const int16_t ff_vp9_default_scan_16x16[256]; · 47 unmodified lines
48extern const int16_t ff_vp9_col_scan_16x16[256];48extern const int16_t ff_vp9_col_scan_16x16[256];
49extern const int16_t ff_vp9_row_scan_16x16[256];49extern const int16_t ff_vp9_row_scan_16x16[256];
50extern const int16_t ff_vp9_default_scan_32x32[1024];50extern const int16_t ff_vp9_default_scan_32x32[1024];
51extern const int16_t *ff_vp9_scans[5][4];51extern const int16_t * const ff_vp9_scans[5][4];
52extern const int16_t ff_vp9_default_scan_4x4_nb[16][2];52extern const int16_t ff_vp9_default_scan_4x4_nb[16][2];
53extern const int16_t ff_vp9_col_scan_4x4_nb[16][2];53extern const int16_t ff_vp9_col_scan_4x4_nb[16][2];
54extern const int16_t ff_vp9_row_scan_4x4_nb[16][2];54extern const int16_t ff_vp9_row_scan_4x4_nb[16][2];
@@ -59,7 +59,7 @@ extern const int16_t ff_vp9_default_scan_16x16_nb[256][2]; · 4 unmodified lines
59extern const int16_t ff_vp9_col_scan_16x16_nb[256][2];59extern const int16_t ff_vp9_col_scan_16x16_nb[256][2];
60extern const int16_t ff_vp9_row_scan_16x16_nb[256][2];60extern const int16_t ff_vp9_row_scan_16x16_nb[256][2];
61extern const int16_t ff_vp9_default_scan_32x32_nb[1024][2];61extern const int16_t ff_vp9_default_scan_32x32_nb[1024][2];
62extern const int16_t (*ff_vp9_scans_nb[5][4])[2];62extern const int16_t (* const ff_vp9_scans_nb[5][4])[2];
63extern const uint8_t ff_vp9_model_pareto8[256][8];63extern const uint8_t ff_vp9_model_pareto8[256][8];
64extern const ProbContext ff_vp9_default_probs;64extern const ProbContext ff_vp9_default_probs;
65extern const uint8_t ff_vp9_default_coef_probs[4][2][2][6][6][3];65extern const uint8_t ff_vp9_default_coef_probs[4][2][2][6][6][3];
libavcodec/x86/fdct.c+2−2
@@ -70,7 +70,7 @@ DECLARE_ALIGNED(16, static const int16_t, fdct_one_corr)[8] = { X8(1) }; · 69 unmodified lines
70 70
71DECLARE_ALIGNED(8, static const int32_t, fdct_r_row)[2] = {RND_FRW_ROW, RND_FRW_ROW };71DECLARE_ALIGNED(8, static const int32_t, fdct_r_row)[2] = {RND_FRW_ROW, RND_FRW_ROW };
72 72
73static struct73static const struct
74{74{
75 DECLARE_ALIGNED(16, const int32_t, fdct_r_row_sse2)[4];75 DECLARE_ALIGNED(16, const int32_t, fdct_r_row_sse2)[4];
76} fdct_r_row_sse2 =76} fdct_r_row_sse2 =
@@ -153,7 +153,7 @@ DECLARE_ALIGNED(8, static const int16_t, tab_frw_01234567)[] = { // forward_dct · 76 unmodified lines
153 29692, -12299, 26722, -31521,153 29692, -12299, 26722, -31521,
154};154};
155 155
156static struct156static const struct
157{157{
158 DECLARE_ALIGNED(16, const int16_t, tab_frw_01234567_sse2)[256];158 DECLARE_ALIGNED(16, const int16_t, tab_frw_01234567_sse2)[256];
159} tab_frw_01234567_sse2 =159} tab_frw_01234567_sse2 =
libavcodec/x86/mlpdsp.c+8−8
@@ -45,14 +45,14 @@ extern char ff_mlp_iirorder_2; · 44 unmodified lines
45extern char ff_mlp_iirorder_1;45extern char ff_mlp_iirorder_1;
46extern char ff_mlp_iirorder_0;46extern char ff_mlp_iirorder_0;
47 47
48static const void *firtable[9] = { &ff_mlp_firorder_0, &ff_mlp_firorder_1,48static const void * const firtable[9] = { &ff_mlp_firorder_0, &ff_mlp_firorder_1,
49 &ff_mlp_firorder_2, &ff_mlp_firorder_3,49 &ff_mlp_firorder_2, &ff_mlp_firorder_3,
50 &ff_mlp_firorder_4, &ff_mlp_firorder_5,50 &ff_mlp_firorder_4, &ff_mlp_firorder_5,
51 &ff_mlp_firorder_6, &ff_mlp_firorder_7,51 &ff_mlp_firorder_6, &ff_mlp_firorder_7,
52 &ff_mlp_firorder_8 };52 &ff_mlp_firorder_8 };
53static const void *iirtable[5] = { &ff_mlp_iirorder_0, &ff_mlp_iirorder_1,53static const void * const iirtable[5] = { &ff_mlp_iirorder_0, &ff_mlp_iirorder_1,
54 &ff_mlp_iirorder_2, &ff_mlp_iirorder_3,54 &ff_mlp_iirorder_2, &ff_mlp_iirorder_3,
55 &ff_mlp_iirorder_4 };55 &ff_mlp_iirorder_4 };
56 56
57#if ARCH_X86_6457#if ARCH_X86_64
58 58
libavcodec/x86/videodsp_init.c+6−6
@@ -59,7 +59,7 @@ extern emu_edge_vfix_func ff_emu_edge_vfix20_mmx; · 58 unmodified lines
59extern emu_edge_vfix_func ff_emu_edge_vfix21_mmx;59extern emu_edge_vfix_func ff_emu_edge_vfix21_mmx;
60extern emu_edge_vfix_func ff_emu_edge_vfix22_mmx;60extern emu_edge_vfix_func ff_emu_edge_vfix22_mmx;
61#if ARCH_X86_3261#if ARCH_X86_32
62static emu_edge_vfix_func *vfixtbl_mmx[22] = {62static emu_edge_vfix_func * const vfixtbl_mmx[22] = {
63 &ff_emu_edge_vfix1_mmx, &ff_emu_edge_vfix2_mmx, &ff_emu_edge_vfix3_mmx,63 &ff_emu_edge_vfix1_mmx, &ff_emu_edge_vfix2_mmx, &ff_emu_edge_vfix3_mmx,
64 &ff_emu_edge_vfix4_mmx, &ff_emu_edge_vfix5_mmx, &ff_emu_edge_vfix6_mmx,64 &ff_emu_edge_vfix4_mmx, &ff_emu_edge_vfix5_mmx, &ff_emu_edge_vfix6_mmx,
65 &ff_emu_edge_vfix7_mmx, &ff_emu_edge_vfix8_mmx, &ff_emu_edge_vfix9_mmx,65 &ff_emu_edge_vfix7_mmx, &ff_emu_edge_vfix8_mmx, &ff_emu_edge_vfix9_mmx,
@@ -78,7 +78,7 @@ extern emu_edge_vfix_func ff_emu_edge_vfix19_sse; · 12 unmodified lines
78extern emu_edge_vfix_func ff_emu_edge_vfix20_sse;78extern emu_edge_vfix_func ff_emu_edge_vfix20_sse;
79extern emu_edge_vfix_func ff_emu_edge_vfix21_sse;79extern emu_edge_vfix_func ff_emu_edge_vfix21_sse;
80extern emu_edge_vfix_func ff_emu_edge_vfix22_sse;80extern emu_edge_vfix_func ff_emu_edge_vfix22_sse;
81static emu_edge_vfix_func *vfixtbl_sse[22] = {81static emu_edge_vfix_func * const vfixtbl_sse[22] = {
82 ff_emu_edge_vfix1_mmx, ff_emu_edge_vfix2_mmx, ff_emu_edge_vfix3_mmx,82 ff_emu_edge_vfix1_mmx, ff_emu_edge_vfix2_mmx, ff_emu_edge_vfix3_mmx,
83 ff_emu_edge_vfix4_mmx, ff_emu_edge_vfix5_mmx, ff_emu_edge_vfix6_mmx,83 ff_emu_edge_vfix4_mmx, ff_emu_edge_vfix5_mmx, ff_emu_edge_vfix6_mmx,
84 ff_emu_edge_vfix7_mmx, ff_emu_edge_vfix8_mmx, ff_emu_edge_vfix9_mmx,84 ff_emu_edge_vfix7_mmx, ff_emu_edge_vfix8_mmx, ff_emu_edge_vfix9_mmx,
@@ -107,7 +107,7 @@ extern emu_edge_hfix_func ff_emu_edge_hfix18_mmx; · 22 unmodified lines
107extern emu_edge_hfix_func ff_emu_edge_hfix20_mmx;107extern emu_edge_hfix_func ff_emu_edge_hfix20_mmx;
108extern emu_edge_hfix_func ff_emu_edge_hfix22_mmx;108extern emu_edge_hfix_func ff_emu_edge_hfix22_mmx;
109#if ARCH_X86_32109#if ARCH_X86_32
110static emu_edge_hfix_func *hfixtbl_mmx[11] = {110static emu_edge_hfix_func * const hfixtbl_mmx[11] = {
111 ff_emu_edge_hfix2_mmx, ff_emu_edge_hfix4_mmx, ff_emu_edge_hfix6_mmx,111 ff_emu_edge_hfix2_mmx, ff_emu_edge_hfix4_mmx, ff_emu_edge_hfix6_mmx,
112 ff_emu_edge_hfix8_mmx, ff_emu_edge_hfix10_mmx, ff_emu_edge_hfix12_mmx,112 ff_emu_edge_hfix8_mmx, ff_emu_edge_hfix10_mmx, ff_emu_edge_hfix12_mmx,
113 ff_emu_edge_hfix14_mmx, ff_emu_edge_hfix16_mmx, ff_emu_edge_hfix18_mmx,113 ff_emu_edge_hfix14_mmx, ff_emu_edge_hfix16_mmx, ff_emu_edge_hfix18_mmx,
@@ -119,7 +119,7 @@ extern emu_edge_hfix_func ff_emu_edge_hfix16_sse2; · 5 unmodified lines
119extern emu_edge_hfix_func ff_emu_edge_hfix18_sse2;119extern emu_edge_hfix_func ff_emu_edge_hfix18_sse2;
120extern emu_edge_hfix_func ff_emu_edge_hfix20_sse2;120extern emu_edge_hfix_func ff_emu_edge_hfix20_sse2;
121extern emu_edge_hfix_func ff_emu_edge_hfix22_sse2;121extern emu_edge_hfix_func ff_emu_edge_hfix22_sse2;
122static emu_edge_hfix_func *hfixtbl_sse2[11] = {122static emu_edge_hfix_func * const hfixtbl_sse2[11] = {
123 ff_emu_edge_hfix2_mmx, ff_emu_edge_hfix4_mmx, ff_emu_edge_hfix6_mmx,123 ff_emu_edge_hfix2_mmx, ff_emu_edge_hfix4_mmx, ff_emu_edge_hfix6_mmx,
124 ff_emu_edge_hfix8_mmx, ff_emu_edge_hfix10_mmx, ff_emu_edge_hfix12_mmx,124 ff_emu_edge_hfix8_mmx, ff_emu_edge_hfix10_mmx, ff_emu_edge_hfix12_mmx,
125 ff_emu_edge_hfix14_mmx, ff_emu_edge_hfix16_sse2, ff_emu_edge_hfix18_sse2,125 ff_emu_edge_hfix14_mmx, ff_emu_edge_hfix16_sse2, ff_emu_edge_hfix18_sse2,
@@ -133,9 +133,9 @@ static av_always_inline void emulated_edge_mc(uint8_t *dst, const uint8_t *src, · 7 unmodified lines
133 x86_reg block_w, x86_reg block_h,133 x86_reg block_w, x86_reg block_h,
134 x86_reg src_x, x86_reg src_y,134 x86_reg src_x, x86_reg src_y,
135 x86_reg w, x86_reg h,135 x86_reg w, x86_reg h,
136 emu_edge_vfix_func **vfix_tbl,136 emu_edge_vfix_func * const *vfix_tbl,
137 emu_edge_vvar_func *v_extend_var,137 emu_edge_vvar_func *v_extend_var,
138 emu_edge_hfix_func **hfix_tbl,138 emu_edge_hfix_func * const *hfix_tbl,
139 emu_edge_hvar_func *h_extend_var)139 emu_edge_hvar_func *h_extend_var)
140{140{
141 x86_reg start_y, start_x, end_y, end_x, src_y_add = 0, p;141 x86_reg start_y, start_x, end_y, end_x, src_y_add = 0, p;
libavfilter/af_volume.c+1−1
@@ -38,7 +38,7 @@ · 37 unmodified lines
38#include "internal.h"38#include "internal.h"
39#include "af_volume.h"39#include "af_volume.h"
40 40
41static const char *precision_str[] = {41static const char * const precision_str[] = {
42 "fixed", "float", "double"42 "fixed", "float", "double"
43};43};
44 44
libavfilter/vf_drawtext.c+1−1
@@ -219,7 +219,7 @@ static const AVClass drawtext_class = { · 218 unmodified lines
219#define FT_ERRORDEF(e, v, s) { (e), (s) },219#define FT_ERRORDEF(e, v, s) { (e), (s) },
220#define FT_ERROR_END_LIST { 0, NULL } };220#define FT_ERROR_END_LIST { 0, NULL } };
221 221
222static struct ft_error {222static const struct ft_error {
223 int err;223 int err;
224 const char *err_msg;224 const char *err_msg;
225} ft_errors[] =225} ft_errors[] =
libavfilter/vf_libopencv.c+2−2
@@ -321,7 +321,7 @@ typedef struct OCVFilterEntry { · 320 unmodified lines
321 void (*end_frame_filter)(AVFilterContext *ctx, IplImage *inimg, IplImage *outimg);321 void (*end_frame_filter)(AVFilterContext *ctx, IplImage *inimg, IplImage *outimg);
322} OCVFilterEntry;322} OCVFilterEntry;
323 323
324static OCVFilterEntry ocv_filter_entries[] = {324static const OCVFilterEntry ocv_filter_entries[] = {
325 { "dilate", sizeof(DilateContext), dilate_init, dilate_uninit, dilate_end_frame_filter },325 { "dilate", sizeof(DilateContext), dilate_init, dilate_uninit, dilate_end_frame_filter },
326 { "erode", sizeof(DilateContext), dilate_init, dilate_uninit, erode_end_frame_filter },326 { "erode", sizeof(DilateContext), dilate_init, dilate_uninit, erode_end_frame_filter },
327 { "smooth", sizeof(SmoothContext), smooth_init, NULL, smooth_end_frame_filter },327 { "smooth", sizeof(SmoothContext), smooth_init, NULL, smooth_end_frame_filter },
@@ -333,7 +333,7 @@ static av_cold int init(AVFilterContext *ctx) · 5 unmodified lines
333 int i;333 int i;
334 334
335 for (i = 0; i < FF_ARRAY_ELEMS(ocv_filter_entries); i++) {335 for (i = 0; i < FF_ARRAY_ELEMS(ocv_filter_entries); i++) {
336 OCVFilterEntry *entry = &ocv_filter_entries[i];336 const OCVFilterEntry *entry = &ocv_filter_entries[i];
337 if (!strcmp(s->name, entry->name)) {337 if (!strcmp(s->name, entry->name)) {
338 s->init = entry->init;338 s->init = entry->init;
339 s->uninit = entry->uninit;339 s->uninit = entry->uninit;
libavfilter/vf_overlay.c+1−1
@@ -66,7 +66,7 @@ enum EOFAction { · 65 unmodified lines
66 EOF_ACTION_PASS66 EOF_ACTION_PASS
67};67};
68 68
69static const char *eof_action_str[] = {69static const char * const eof_action_str[] = {
70 "repeat", "endall", "pass"70 "repeat", "endall", "pass"
71};71};
72 72
libavformat/hls.c+2−2
@@ -477,8 +477,8 @@ reload: · 476 unmodified lines
477static int save_avio_options(AVFormatContext *s)477static int save_avio_options(AVFormatContext *s)
478{478{
479 HLSContext *c = s->priv_data;479 HLSContext *c = s->priv_data;
480 static const char *opts[] = { "headers", "user_agent", NULL };480 static const char * const opts[] = { "headers", "user_agent", NULL };
481 const char **opt = opts;481 const char * const *opt = opts;
482 uint8_t *buf;482 uint8_t *buf;
483 int ret = 0;483 int ret = 0;
484 484
libavformat/id3v2.c+1−1
@@ -86,7 +86,7 @@ const char ff_id3v2_3_tags[][4] = { · 85 unmodified lines
86 { 0 },86 { 0 },
87};87};
88 88
89const char *ff_id3v2_picture_types[21] = {89const char * const ff_id3v2_picture_types[21] = {
90 "Other",90 "Other",
91 "32x32 pixels 'file icon'",91 "32x32 pixels 'file icon'",
92 "Other file icon",92 "Other file icon",
libavformat/id3v2.h+1−1
@@ -158,6 +158,6 @@ extern const char ff_id3v2_3_tags[][4]; · 157 unmodified lines
158 158
159extern const CodecMime ff_id3v2_mime_tags[];159extern const CodecMime ff_id3v2_mime_tags[];
160 160
161extern const char *ff_id3v2_picture_types[21];161extern const char * const ff_id3v2_picture_types[21];
162 162
163#endif /* AVFORMAT_ID3V2_H */163#endif /* AVFORMAT_ID3V2_H */
libavformat/mov_chan.c+1−1
@@ -344,7 +344,7 @@ static const struct MovChannelLayoutMap mov_ch_layout_map_9ch[] = { · 343 unmodified lines
344 { 0, 0 },344 { 0, 0 },
345};345};
346 346
347static const struct MovChannelLayoutMap *mov_ch_layout_map[] = {347static const struct MovChannelLayoutMap * const mov_ch_layout_map[] = {
348 mov_ch_layout_map_misc,348 mov_ch_layout_map_misc,
349 mov_ch_layout_map_1ch,349 mov_ch_layout_map_1ch,
350 mov_ch_layout_map_2ch,350 mov_ch_layout_map_2ch,
libavformat/movenc.c+1−1
@@ -3529,7 +3529,7 @@ int ff_mov_write_packet(AVFormatContext *s, AVPacket *pkt) · 3528 unmodified lines
3529 3529
3530 if (par->codec_id == AV_CODEC_ID_AMR_NB) {3530 if (par->codec_id == AV_CODEC_ID_AMR_NB) {
3531 /* We must find out how many AMR blocks there are in one packet */3531 /* We must find out how many AMR blocks there are in one packet */
3532 static uint16_t packed_size[16] =3532 static const uint16_t packed_size[16] =
3533 {13, 14, 16, 18, 20, 21, 27, 32, 6, 0, 0, 0, 0, 0, 0, 1};3533 {13, 14, 16, 18, 20, 21, 27, 32, 6, 0, 0, 0, 0, 0, 0, 1};
3534 int len = 0;3534 int len = 0;
3535 3535
libavformat/mxfdec.c+1−1
@@ -981,7 +981,7 @@ static const MXFCodecUL mxf_data_essence_container_uls[] = { · 980 unmodified lines
981 { { 0x06,0x0e,0x2b,0x34,0x04,0x01,0x01,0x09,0x0d,0x01,0x03,0x01,0x02,0x0e,0x00,0x00 }, 16, AV_CODEC_ID_NONE },981 { { 0x06,0x0e,0x2b,0x34,0x04,0x01,0x01,0x09,0x0d,0x01,0x03,0x01,0x02,0x0e,0x00,0x00 }, 16, AV_CODEC_ID_NONE },
982};982};
983 983
984static const char* mxf_data_essence_descriptor[] = {984static const char * const mxf_data_essence_descriptor[] = {
985 "vbi_vanc_smpte_436M",985 "vbi_vanc_smpte_436M",
986};986};
987 987
libavresample/audio_mix.c+1−1
@@ -28,7 +28,7 @@ · 27 unmodified lines
28#include "audio_data.h"28#include "audio_data.h"
29#include "audio_mix.h"29#include "audio_mix.h"
30 30
31static const char *coeff_type_names[] = { "q8", "q15", "flt" };31static const char * const coeff_type_names[] = { "q8", "q15", "flt" };
32 32
33struct AudioMix {33struct AudioMix {
34 AVAudioResampleContext *avr;34 AVAudioResampleContext *avr;
libavutil/hwcontext.c+1−1
@@ -28,7 +28,7 @@ · 27 unmodified lines
28#include "pixdesc.h"28#include "pixdesc.h"
29#include "pixfmt.h"29#include "pixfmt.h"
30 30
31static const HWContextType *hw_table[] = {31static const HWContextType * const hw_table[] = {
32#if CONFIG_CUDA32#if CONFIG_CUDA
33 &ff_hwcontext_type_cuda,33 &ff_hwcontext_type_cuda,
34#endif34#endif
libavutil/hwcontext_vaapi.c+1−1
@@ -84,7 +84,7 @@ typedef struct VAAPIMapping { · 83 unmodified lines
84 }84 }
85// The map fourcc <-> pix_fmt isn't bijective because of the annoying U/V85// The map fourcc <-> pix_fmt isn't bijective because of the annoying U/V
86// plane swap cases. The frame handling below tries to hide these.86// plane swap cases. The frame handling below tries to hide these.
87static struct {87static const struct {
88 unsigned int fourcc;88 unsigned int fourcc;
89 unsigned int rt_format;89 unsigned int rt_format;
90 enum AVPixelFormat pix_fmt;90 enum AVPixelFormat pix_fmt;
libavutil/parseutils.c+1−1
@@ -152,7 +152,7 @@ typedef struct ColorEntry { · 151 unmodified lines
152 uint8_t rgb_color[3]; ///< RGB values for the color152 uint8_t rgb_color[3]; ///< RGB values for the color
153} ColorEntry;153} ColorEntry;
154 154
155static ColorEntry color_table[] = {155static const ColorEntry color_table[] = {
156 { "AliceBlue", { 0xF0, 0xF8, 0xFF } },156 { "AliceBlue", { 0xF0, 0xF8, 0xFF } },
157 { "AntiqueWhite", { 0xFA, 0xEB, 0xD7 } },157 { "AntiqueWhite", { 0xFA, 0xEB, 0xD7 } },
158 { "Aqua", { 0x00, 0xFF, 0xFF } },158 { "Aqua", { 0x00, 0xFF, 0xFF } },
libavutil/pixdesc.c+5−5
@@ -1764,13 +1764,13 @@ static const AVPixFmtDescriptor av_pix_fmt_descriptors[AV_PIX_FMT_NB] = { · 1763 unmodified lines
1764FF_ENABLE_DEPRECATION_WARNINGS1764FF_ENABLE_DEPRECATION_WARNINGS
1765#endif1765#endif
1766 1766
1767static const char *color_range_names[] = {1767static const char * const color_range_names[] = {
1768 [AVCOL_RANGE_UNSPECIFIED] = "unknown",1768 [AVCOL_RANGE_UNSPECIFIED] = "unknown",
1769 [AVCOL_RANGE_MPEG] = "tv",1769 [AVCOL_RANGE_MPEG] = "tv",
1770 [AVCOL_RANGE_JPEG] = "pc",1770 [AVCOL_RANGE_JPEG] = "pc",
1771};1771};
1772 1772
1773static const char *color_primaries_names[] = {1773static const char * const color_primaries_names[] = {
1774 [AVCOL_PRI_RESERVED0] = "reserved",1774 [AVCOL_PRI_RESERVED0] = "reserved",
1775 [AVCOL_PRI_BT709] = "bt709",1775 [AVCOL_PRI_BT709] = "bt709",
1776 [AVCOL_PRI_UNSPECIFIED] = "unknown",1776 [AVCOL_PRI_UNSPECIFIED] = "unknown",
@@ -1787,7 +1787,7 @@ static const char *color_primaries_names[] = { · 10 unmodified lines
1787 [AVCOL_PRI_JEDEC_P22] = "jedec-p22",1787 [AVCOL_PRI_JEDEC_P22] = "jedec-p22",
1788};1788};
1789 1789
1790static const char *color_transfer_names[] = {1790static const char * const color_transfer_names[] = {
1791 [AVCOL_TRC_RESERVED0] = "reserved",1791 [AVCOL_TRC_RESERVED0] = "reserved",
1792 [AVCOL_TRC_BT709] = "bt709",1792 [AVCOL_TRC_BT709] = "bt709",
1793 [AVCOL_TRC_UNSPECIFIED] = "unknown",1793 [AVCOL_TRC_UNSPECIFIED] = "unknown",
@@ -1809,7 +1809,7 @@ static const char *color_transfer_names[] = { · 15 unmodified lines
1809 [AVCOL_TRC_ARIB_STD_B67] = "arib-std-b67",1809 [AVCOL_TRC_ARIB_STD_B67] = "arib-std-b67",
1810};1810};
1811 1811
1812static const char *color_space_names[] = {1812static const char * const color_space_names[] = {
1813 [AVCOL_SPC_RGB] = "gbr",1813 [AVCOL_SPC_RGB] = "gbr",
1814 [AVCOL_SPC_BT709] = "bt709",1814 [AVCOL_SPC_BT709] = "bt709",
1815 [AVCOL_SPC_UNSPECIFIED] = "unknown",1815 [AVCOL_SPC_UNSPECIFIED] = "unknown",
@@ -1824,7 +1824,7 @@ static const char *color_space_names[] = { · 8 unmodified lines
1824 [AVCOL_SPC_SMPTE2085] = "smpte2085",1824 [AVCOL_SPC_SMPTE2085] = "smpte2085",
1825};1825};
1826 1826
1827static const char *chroma_location_names[] = {1827static const char * const chroma_location_names[] = {
1828 [AVCHROMA_LOC_UNSPECIFIED] = "unspecified",1828 [AVCHROMA_LOC_UNSPECIFIED] = "unspecified",
1829 [AVCHROMA_LOC_LEFT] = "left",1829 [AVCHROMA_LOC_LEFT] = "left",
1830 [AVCHROMA_LOC_CENTER] = "center",1830 [AVCHROMA_LOC_CENTER] = "center",
libavutil/stereo3d.c+1−1
@@ -43,7 +43,7 @@ AVStereo3D *av_stereo3d_create_side_data(AVFrame *frame) · 42 unmodified lines
43 return (AVStereo3D *)side_data->data;43 return (AVStereo3D *)side_data->data;
44}44}
45 45
46static const char *stereo3d_type_names[] = {46static const char * const stereo3d_type_names[] = {
47 [AV_STEREO3D_2D] = "2D",47 [AV_STEREO3D_2D] = "2D",
48 [AV_STEREO3D_SIDEBYSIDE] = "side by side",48 [AV_STEREO3D_SIDEBYSIDE] = "side by side",
49 [AV_STEREO3D_TOPBOTTOM] = "top and bottom",49 [AV_STEREO3D_TOPBOTTOM] = "top and bottom",

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t