00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00027 #include "mpegaudiodata.h"
00028
00029
00030 const uint16_t avpriv_mpa_bitrate_tab[2][3][15] = {
00031 { {0, 32, 64, 96, 128, 160, 192, 224, 256, 288, 320, 352, 384, 416, 448 },
00032 {0, 32, 48, 56, 64, 80, 96, 112, 128, 160, 192, 224, 256, 320, 384 },
00033 {0, 32, 40, 48, 56, 64, 80, 96, 112, 128, 160, 192, 224, 256, 320 } },
00034 { {0, 32, 48, 56, 64, 80, 96, 112, 128, 144, 160, 176, 192, 224, 256},
00035 {0, 8, 16, 24, 32, 40, 48, 56, 64, 80, 96, 112, 128, 144, 160},
00036 {0, 8, 16, 24, 32, 40, 48, 56, 64, 80, 96, 112, 128, 144, 160}
00037 }
00038 };
00039
00040 const uint16_t avpriv_mpa_freq_tab[3] = { 44100, 48000, 32000 };
00041
00042
00043
00044
00045 const int ff_mpa_sblimit_table[5] = { 27 , 30 , 8, 12 , 30 };
00046
00047 const int ff_mpa_quant_steps[17] = {
00048 3, 5, 7, 9, 15,
00049 31, 63, 127, 255, 511,
00050 1023, 2047, 4095, 8191, 16383,
00051 32767, 65535
00052 };
00053
00054
00055 const int ff_mpa_quant_bits[17] = {
00056 -5, -7, 3, -10, 4,
00057 5, 6, 7, 8, 9,
00058 10, 11, 12, 13, 14,
00059 15, 16
00060 };
00061
00062
00063
00064 static const unsigned char alloc_table_1[] = {
00065 4, 0, 2, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16,
00066 4, 0, 2, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16,
00067 4, 0, 2, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16,
00068 4, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 16,
00069 4, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 16,
00070 4, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 16,
00071 4, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 16,
00072 4, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 16,
00073 4, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 16,
00074 4, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 16,
00075 4, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 16,
00076 3, 0, 1, 2, 3, 4, 5, 16,
00077 3, 0, 1, 2, 3, 4, 5, 16,
00078 3, 0, 1, 2, 3, 4, 5, 16,
00079 3, 0, 1, 2, 3, 4, 5, 16,
00080 3, 0, 1, 2, 3, 4, 5, 16,
00081 3, 0, 1, 2, 3, 4, 5, 16,
00082 3, 0, 1, 2, 3, 4, 5, 16,
00083 3, 0, 1, 2, 3, 4, 5, 16,
00084 3, 0, 1, 2, 3, 4, 5, 16,
00085 3, 0, 1, 2, 3, 4, 5, 16,
00086 3, 0, 1, 2, 3, 4, 5, 16,
00087 3, 0, 1, 2, 3, 4, 5, 16,
00088 2, 0, 1, 16,
00089 2, 0, 1, 16,
00090 2, 0, 1, 16,
00091 2, 0, 1, 16,
00092 2, 0, 1, 16,
00093 2, 0, 1, 16,
00094 2, 0, 1, 16,
00095 };
00096
00097 static const unsigned char alloc_table_3[] = {
00098 4, 0, 1, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
00099 4, 0, 1, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
00100 3, 0, 1, 3, 4, 5, 6, 7,
00101 3, 0, 1, 3, 4, 5, 6, 7,
00102 3, 0, 1, 3, 4, 5, 6, 7,
00103 3, 0, 1, 3, 4, 5, 6, 7,
00104 3, 0, 1, 3, 4, 5, 6, 7,
00105 3, 0, 1, 3, 4, 5, 6, 7,
00106 3, 0, 1, 3, 4, 5, 6, 7,
00107 3, 0, 1, 3, 4, 5, 6, 7,
00108 3, 0, 1, 3, 4, 5, 6, 7,
00109 3, 0, 1, 3, 4, 5, 6, 7,
00110 };
00111
00112 static const unsigned char alloc_table_4[] = {
00113 4, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
00114 4, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
00115 4, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
00116 4, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
00117 3, 0, 1, 3, 4, 5, 6, 7,
00118 3, 0, 1, 3, 4, 5, 6, 7,
00119 3, 0, 1, 3, 4, 5, 6, 7,
00120 3, 0, 1, 3, 4, 5, 6, 7,
00121 3, 0, 1, 3, 4, 5, 6, 7,
00122 3, 0, 1, 3, 4, 5, 6, 7,
00123 3, 0, 1, 3, 4, 5, 6, 7,
00124 2, 0, 1, 3,
00125 2, 0, 1, 3,
00126 2, 0, 1, 3,
00127 2, 0, 1, 3,
00128 2, 0, 1, 3,
00129 2, 0, 1, 3,
00130 2, 0, 1, 3,
00131 2, 0, 1, 3,
00132 2, 0, 1, 3,
00133 2, 0, 1, 3,
00134 2, 0, 1, 3,
00135 2, 0, 1, 3,
00136 2, 0, 1, 3,
00137 2, 0, 1, 3,
00138 2, 0, 1, 3,
00139 2, 0, 1, 3,
00140 2, 0, 1, 3,
00141 2, 0, 1, 3,
00142 2, 0, 1, 3,
00143 };
00144
00145 const unsigned char * const ff_mpa_alloc_tables[5] =
00146 { alloc_table_1, alloc_table_1, alloc_table_3, alloc_table_3, alloc_table_4, };