diff options
author | Diego Elio Pettenò <flameeyes@flameeyes.eu> | 2012-09-10 12:48:19 +0400 |
---|---|---|
committer | Jean-Marc Valin <jmvalin@jmvalin.ca> | 2012-09-12 23:54:10 +0400 |
commit | d509e9f2a82ed39465b9ae864c69e4fde70c3042 (patch) | |
tree | 4220a3d2dba9408bba59d01dd999a9ef5739e298 /src/opus_demo.c | |
parent | 1d13ff6a974dad72d398d2c2db2fc8ce3724a4d0 (diff) |
opus_demo: mark tables as static constants.
While this is not making a huge difference it still makes the code
more consistent.
Signed-off-by: Diego Elio Pettenò <flameeyes@flameeyes.eu>
Diffstat (limited to 'src/opus_demo.c')
-rw-r--r-- | src/opus_demo.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/opus_demo.c b/src/opus_demo.c index 20bebba3..1cb153a8 100644 --- a/src/opus_demo.c +++ b/src/opus_demo.c @@ -95,7 +95,7 @@ static void check_encoder_option(int decode_only, const char *opt) } } -int silk8_test[][4] = { +static const int silk8_test[][4] = { {MODE_SILK_ONLY, OPUS_BANDWIDTH_NARROWBAND, 960*3, 1}, {MODE_SILK_ONLY, OPUS_BANDWIDTH_NARROWBAND, 960*2, 1}, {MODE_SILK_ONLY, OPUS_BANDWIDTH_NARROWBAND, 960, 1}, @@ -106,7 +106,7 @@ int silk8_test[][4] = { {MODE_SILK_ONLY, OPUS_BANDWIDTH_NARROWBAND, 480, 2} }; -int silk12_test[][4] = { +static const int silk12_test[][4] = { {MODE_SILK_ONLY, OPUS_BANDWIDTH_MEDIUMBAND, 960*3, 1}, {MODE_SILK_ONLY, OPUS_BANDWIDTH_MEDIUMBAND, 960*2, 1}, {MODE_SILK_ONLY, OPUS_BANDWIDTH_MEDIUMBAND, 960, 1}, @@ -117,7 +117,7 @@ int silk12_test[][4] = { {MODE_SILK_ONLY, OPUS_BANDWIDTH_MEDIUMBAND, 480, 2} }; -int silk16_test[][4] = { +static const int silk16_test[][4] = { {MODE_SILK_ONLY, OPUS_BANDWIDTH_WIDEBAND, 960*3, 1}, {MODE_SILK_ONLY, OPUS_BANDWIDTH_WIDEBAND, 960*2, 1}, {MODE_SILK_ONLY, OPUS_BANDWIDTH_WIDEBAND, 960, 1}, @@ -128,21 +128,21 @@ int silk16_test[][4] = { {MODE_SILK_ONLY, OPUS_BANDWIDTH_WIDEBAND, 480, 2} }; -int hybrid24_test[][4] = { +static const int hybrid24_test[][4] = { {MODE_SILK_ONLY, OPUS_BANDWIDTH_SUPERWIDEBAND, 960, 1}, {MODE_SILK_ONLY, OPUS_BANDWIDTH_SUPERWIDEBAND, 480, 1}, {MODE_SILK_ONLY, OPUS_BANDWIDTH_SUPERWIDEBAND, 960, 2}, {MODE_SILK_ONLY, OPUS_BANDWIDTH_SUPERWIDEBAND, 480, 2} }; -int hybrid48_test[][4] = { +static const int hybrid48_test[][4] = { {MODE_SILK_ONLY, OPUS_BANDWIDTH_FULLBAND, 960, 1}, {MODE_SILK_ONLY, OPUS_BANDWIDTH_FULLBAND, 480, 1}, {MODE_SILK_ONLY, OPUS_BANDWIDTH_FULLBAND, 960, 2}, {MODE_SILK_ONLY, OPUS_BANDWIDTH_FULLBAND, 480, 2} }; -int celt_test[][4] = { +static const int celt_test[][4] = { {MODE_CELT_ONLY, OPUS_BANDWIDTH_FULLBAND, 960, 1}, {MODE_CELT_ONLY, OPUS_BANDWIDTH_SUPERWIDEBAND, 960, 1}, {MODE_CELT_ONLY, OPUS_BANDWIDTH_WIDEBAND, 960, 1}, @@ -185,7 +185,7 @@ int celt_test[][4] = { }; -int celt_hq_test[][4] = { +static const int celt_hq_test[][4] = { {MODE_CELT_ONLY, OPUS_BANDWIDTH_FULLBAND, 960, 2}, {MODE_CELT_ONLY, OPUS_BANDWIDTH_FULLBAND, 480, 2}, {MODE_CELT_ONLY, OPUS_BANDWIDTH_FULLBAND, 240, 2}, @@ -234,7 +234,7 @@ int main(int argc, char *argv[]) int random_framesize=0, newsize=0, delayed_celt=0; int sweep_max=0, sweep_min=0; int random_fec=0; - int (*mode_list)[4]=NULL; + const int (*mode_list)[4]=NULL; int nb_modes_in_list=0; int curr_mode=0; int curr_mode_count=0; |