/src/libxaac/decoder/ixheaacd_mps_mdct_2_qmf.c
Line | Count | Source |
1 | | /****************************************************************************** |
2 | | * |
3 | | * Copyright (C) 2023 The Android Open Source Project |
4 | | * |
5 | | * Licensed under the Apache License, Version 2.0 (the "License"); |
6 | | * you may not use this file except in compliance with the License. |
7 | | * You may obtain a copy of the License at: |
8 | | * |
9 | | * http://www.apache.org/licenses/LICENSE-2.0 |
10 | | * |
11 | | * Unless required by applicable law or agreed to in writing, software |
12 | | * distributed under the License is distributed on an "AS IS" BASIS, |
13 | | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
14 | | * See the License for the specific language governing permissions and |
15 | | * limitations under the License. |
16 | | * |
17 | | ***************************************************************************** |
18 | | * Originally developed and contributed by Ittiam Systems Pvt. Ltd, Bangalore |
19 | | */ |
20 | | #include <string.h> |
21 | | #include "ixheaac_type_def.h" |
22 | | #include "ixheaacd_mps_struct_def.h" |
23 | | #include "ixheaacd_error_codes.h" |
24 | | #include "ixheaacd_mps_res_rom.h" |
25 | | #include "ixheaacd_mps_aac_struct.h" |
26 | | #include "ixheaac_constants.h" |
27 | | #include "ixheaac_basic_ops32.h" |
28 | | #include "ixheaac_basic_ops40.h" |
29 | | #include "ixheaacd_bitbuffer.h" |
30 | | #include "ixheaacd_cnst.h" |
31 | | #include "ixheaacd_common_rom.h" |
32 | | #include "ixheaacd_sbrdecsettings.h" |
33 | | #include "ixheaacd_sbr_scale.h" |
34 | | #include "ixheaacd_env_extr_part.h" |
35 | | #include "ixheaacd_sbr_rom.h" |
36 | | #include "ixheaacd_hybrid.h" |
37 | | #include "ixheaacd_ps_dec.h" |
38 | | #include "ixheaac_error_standards.h" |
39 | | #include "ixheaacd_mps_polyphase.h" |
40 | | #include "ixheaacd_config.h" |
41 | | #include "ixheaacd_qmf_dec.h" |
42 | | #include "ixheaacd_mps_dec.h" |
43 | | #include "ixheaacd_mps_mdct_2_qmf.h" |
44 | | #include "ixheaacd_mps_macro_def.h" |
45 | | #include "ixheaacd_mps_basic_op.h" |
46 | | |
47 | 4.10k | IA_ERRORCODE ixheaacd_mdct2qmf_tables_init(ia_heaac_mps_state_struct *pstr_mps_state) { |
48 | 4.10k | WORD32 time_slots; |
49 | | |
50 | 4.10k | time_slots = pstr_mps_state->upd_qmf; |
51 | | |
52 | 4.10k | if (32 == time_slots) { |
53 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[0] = |
54 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_00; |
55 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[1] = |
56 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_01; |
57 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[2] = |
58 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_02; |
59 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[3] = |
60 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_03; |
61 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[4] = |
62 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_04; |
63 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[5] = |
64 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_05; |
65 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[6] = |
66 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_06; |
67 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[7] = |
68 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_07; |
69 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[8] = |
70 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_08; |
71 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[9] = |
72 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_09; |
73 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[10] = |
74 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_10; |
75 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[11] = |
76 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_11; |
77 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[12] = |
78 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_12; |
79 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[13] = |
80 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_13; |
81 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[14] = |
82 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_14; |
83 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[15] = |
84 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_15; |
85 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[16] = |
86 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_15; |
87 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[17] = |
88 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_14; |
89 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[18] = |
90 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_13; |
91 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[19] = |
92 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_12; |
93 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[20] = |
94 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_11; |
95 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[21] = |
96 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_10; |
97 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[22] = |
98 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_09; |
99 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[23] = |
100 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_08; |
101 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[24] = |
102 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_07; |
103 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[25] = |
104 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_06; |
105 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[26] = |
106 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_05; |
107 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[27] = |
108 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_04; |
109 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[28] = |
110 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_03; |
111 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[29] = |
112 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_02; |
113 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[30] = |
114 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_01; |
115 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[31] = |
116 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_00; |
117 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[32] = |
118 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_16; |
119 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[33] = |
120 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_17; |
121 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[34] = |
122 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_18; |
123 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[35] = |
124 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_19; |
125 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[36] = |
126 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_20; |
127 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[37] = |
128 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_21; |
129 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[38] = |
130 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_22; |
131 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[39] = |
132 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_23; |
133 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[40] = |
134 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_24; |
135 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[41] = |
136 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_25; |
137 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[42] = |
138 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_26; |
139 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[43] = |
140 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_27; |
141 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[44] = |
142 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_28; |
143 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[45] = |
144 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_29; |
145 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[46] = |
146 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_30; |
147 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[47] = |
148 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_31; |
149 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[48] = |
150 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_31; |
151 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[49] = |
152 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_30; |
153 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[50] = |
154 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_29; |
155 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[51] = |
156 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_28; |
157 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[52] = |
158 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_27; |
159 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[53] = |
160 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_26; |
161 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[54] = |
162 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_25; |
163 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[55] = |
164 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_24; |
165 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[56] = |
166 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_23; |
167 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[57] = |
168 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_22; |
169 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[58] = |
170 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_21; |
171 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[59] = |
172 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_20; |
173 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[60] = |
174 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_19; |
175 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[61] = |
176 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_18; |
177 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[62] = |
178 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_17; |
179 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[63] = |
180 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_32_16; |
181 | | |
182 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[0] = |
183 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_short_4_00; |
184 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[1] = |
185 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_short_4_01; |
186 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[2] = |
187 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_short_4_01; |
188 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[3] = |
189 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_short_4_00; |
190 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[4] = |
191 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_short_4_02; |
192 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[5] = |
193 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_short_4_03; |
194 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[6] = |
195 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_short_4_03; |
196 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[7] = |
197 | 2.15k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_short_4_02; |
198 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[8] = NULL; |
199 | 2.15k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[9] = NULL; |
200 | 2.15k | } else { |
201 | 1.95k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[0] = |
202 | 1.95k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_short_2_00; |
203 | 1.95k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[1] = |
204 | 1.95k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_short_2_00; |
205 | 1.95k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[2] = |
206 | 1.95k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_short_2_01; |
207 | 1.95k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[3] = |
208 | 1.95k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_short_2_01; |
209 | 1.95k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[4] = NULL; |
210 | 1.95k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[5] = NULL; |
211 | 1.95k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[6] = NULL; |
212 | 1.95k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[7] = NULL; |
213 | 1.95k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[8] = NULL; |
214 | 1.95k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[9] = NULL; |
215 | | |
216 | 1.95k | if (30 == time_slots) { |
217 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[0] = |
218 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_00; |
219 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[1] = |
220 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_01; |
221 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[2] = |
222 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_02; |
223 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[3] = |
224 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_03; |
225 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[4] = |
226 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_04; |
227 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[5] = |
228 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_05; |
229 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[6] = |
230 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_06; |
231 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[7] = |
232 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_07; |
233 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[8] = |
234 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_08; |
235 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[9] = |
236 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_09; |
237 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[10] = |
238 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_10; |
239 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[11] = |
240 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_11; |
241 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[12] = |
242 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_12; |
243 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[13] = |
244 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_13; |
245 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[14] = |
246 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_14; |
247 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[15] = |
248 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_14; |
249 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[16] = |
250 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_13; |
251 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[17] = |
252 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_12; |
253 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[18] = |
254 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_11; |
255 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[19] = |
256 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_10; |
257 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[20] = |
258 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_09; |
259 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[21] = |
260 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_08; |
261 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[22] = |
262 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_07; |
263 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[23] = |
264 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_06; |
265 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[24] = |
266 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_05; |
267 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[25] = |
268 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_04; |
269 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[26] = |
270 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_03; |
271 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[27] = |
272 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_02; |
273 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[28] = |
274 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_01; |
275 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[29] = |
276 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_00; |
277 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[30] = |
278 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_15; |
279 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[31] = |
280 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_16; |
281 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[32] = |
282 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_17; |
283 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[33] = |
284 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_18; |
285 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[34] = |
286 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_19; |
287 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[35] = |
288 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_20; |
289 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[36] = |
290 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_21; |
291 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[37] = |
292 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_22; |
293 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[38] = |
294 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_23; |
295 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[39] = |
296 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_24; |
297 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[40] = |
298 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_25; |
299 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[41] = |
300 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_26; |
301 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[42] = |
302 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_27; |
303 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[43] = |
304 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_28; |
305 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[44] = |
306 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_29; |
307 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[45] = |
308 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_29; |
309 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[46] = |
310 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_28; |
311 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[47] = |
312 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_27; |
313 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[48] = |
314 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_26; |
315 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[49] = |
316 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_25; |
317 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[50] = |
318 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_24; |
319 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[51] = |
320 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_23; |
321 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[52] = |
322 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_22; |
323 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[53] = |
324 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_21; |
325 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[54] = |
326 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_20; |
327 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[55] = |
328 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_19; |
329 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[56] = |
330 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_18; |
331 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[57] = |
332 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_17; |
333 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[58] = |
334 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_16; |
335 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[59] = |
336 | 26 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_30_15; |
337 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[60] = NULL; |
338 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[61] = NULL; |
339 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[62] = NULL; |
340 | 26 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[63] = NULL; |
341 | 1.92k | } else if (24 == time_slots) { |
342 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[0] = |
343 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_00; |
344 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[1] = |
345 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_01; |
346 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[2] = |
347 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_02; |
348 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[3] = |
349 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_03; |
350 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[4] = |
351 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_04; |
352 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[5] = |
353 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_05; |
354 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[6] = |
355 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_06; |
356 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[7] = |
357 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_07; |
358 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[8] = |
359 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_08; |
360 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[9] = |
361 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_09; |
362 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[10] = |
363 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_10; |
364 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[11] = |
365 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_11; |
366 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[12] = |
367 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_11; |
368 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[13] = |
369 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_10; |
370 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[14] = |
371 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_09; |
372 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[15] = |
373 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_08; |
374 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[16] = |
375 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_07; |
376 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[17] = |
377 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_06; |
378 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[18] = |
379 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_05; |
380 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[19] = |
381 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_04; |
382 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[20] = |
383 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_03; |
384 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[21] = |
385 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_02; |
386 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[22] = |
387 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_01; |
388 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[23] = |
389 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_00; |
390 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[24] = |
391 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_12; |
392 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[25] = |
393 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_13; |
394 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[26] = |
395 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_14; |
396 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[27] = |
397 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_15; |
398 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[28] = |
399 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_16; |
400 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[29] = |
401 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_17; |
402 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[30] = |
403 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_18; |
404 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[31] = |
405 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_19; |
406 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[32] = |
407 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_20; |
408 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[33] = |
409 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_21; |
410 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[34] = |
411 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_22; |
412 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[35] = |
413 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_23; |
414 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[36] = |
415 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_23; |
416 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[37] = |
417 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_22; |
418 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[38] = |
419 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_21; |
420 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[39] = |
421 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_20; |
422 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[40] = |
423 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_19; |
424 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[41] = |
425 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_18; |
426 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[42] = |
427 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_17; |
428 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[43] = |
429 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_16; |
430 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[44] = |
431 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_15; |
432 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[45] = |
433 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_14; |
434 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[46] = |
435 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_13; |
436 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[47] = |
437 | 581 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_24_12; |
438 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[48] = NULL; |
439 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[49] = NULL; |
440 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[50] = NULL; |
441 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[51] = NULL; |
442 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[52] = NULL; |
443 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[53] = NULL; |
444 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[54] = NULL; |
445 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[55] = NULL; |
446 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[56] = NULL; |
447 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[57] = NULL; |
448 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[58] = NULL; |
449 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[59] = NULL; |
450 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[60] = NULL; |
451 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[61] = NULL; |
452 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[62] = NULL; |
453 | 581 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[63] = NULL; |
454 | 1.34k | } else if (18 == time_slots) { |
455 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[0] = |
456 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_00; |
457 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[1] = |
458 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_01; |
459 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[2] = |
460 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_02; |
461 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[3] = |
462 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_03; |
463 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[4] = |
464 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_04; |
465 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[5] = |
466 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_05; |
467 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[6] = |
468 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_06; |
469 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[7] = |
470 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_07; |
471 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[8] = |
472 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_08; |
473 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[9] = |
474 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_08; |
475 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[10] = |
476 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_07; |
477 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[11] = |
478 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_06; |
479 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[12] = |
480 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_05; |
481 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[13] = |
482 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_04; |
483 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[14] = |
484 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_03; |
485 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[15] = |
486 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_02; |
487 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[16] = |
488 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_01; |
489 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[17] = |
490 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_00; |
491 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[18] = |
492 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_09; |
493 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[19] = |
494 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_10; |
495 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[20] = |
496 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_11; |
497 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[21] = |
498 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_12; |
499 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[22] = |
500 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_13; |
501 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[23] = |
502 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_14; |
503 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[24] = |
504 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_15; |
505 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[25] = |
506 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_16; |
507 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[26] = |
508 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_17; |
509 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[27] = |
510 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_17; |
511 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[28] = |
512 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_16; |
513 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[29] = |
514 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_15; |
515 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[30] = |
516 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_14; |
517 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[31] = |
518 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_13; |
519 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[32] = |
520 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_12; |
521 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[33] = |
522 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_11; |
523 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[34] = |
524 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_10; |
525 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[35] = |
526 | 41 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_18_09; |
527 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[36] = NULL; |
528 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[37] = NULL; |
529 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[38] = NULL; |
530 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[39] = NULL; |
531 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[40] = NULL; |
532 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[41] = NULL; |
533 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[42] = NULL; |
534 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[43] = NULL; |
535 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[44] = NULL; |
536 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[45] = NULL; |
537 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[46] = NULL; |
538 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[47] = NULL; |
539 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[48] = NULL; |
540 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[49] = NULL; |
541 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[50] = NULL; |
542 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[51] = NULL; |
543 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[52] = NULL; |
544 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[53] = NULL; |
545 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[54] = NULL; |
546 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[55] = NULL; |
547 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[56] = NULL; |
548 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[57] = NULL; |
549 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[58] = NULL; |
550 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[59] = NULL; |
551 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[60] = NULL; |
552 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[61] = NULL; |
553 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[62] = NULL; |
554 | 41 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[63] = NULL; |
555 | 1.30k | } else if (16 == time_slots) { |
556 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[0] = |
557 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_00; |
558 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[1] = |
559 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_01; |
560 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[2] = |
561 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_02; |
562 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[3] = |
563 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_03; |
564 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[4] = |
565 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_04; |
566 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[5] = |
567 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_05; |
568 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[6] = |
569 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_06; |
570 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[7] = |
571 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_07; |
572 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[8] = |
573 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_07; |
574 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[9] = |
575 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_06; |
576 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[10] = |
577 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_05; |
578 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[11] = |
579 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_04; |
580 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[12] = |
581 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_03; |
582 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[13] = |
583 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_02; |
584 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[14] = |
585 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_01; |
586 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[15] = |
587 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_00; |
588 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[16] = |
589 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_08; |
590 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[17] = |
591 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_09; |
592 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[18] = |
593 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_10; |
594 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[19] = |
595 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_11; |
596 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[20] = |
597 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_12; |
598 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[21] = |
599 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_13; |
600 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[22] = |
601 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_14; |
602 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[23] = |
603 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_15; |
604 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[24] = |
605 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_15; |
606 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[25] = |
607 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_14; |
608 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[26] = |
609 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_13; |
610 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[27] = |
611 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_12; |
612 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[28] = |
613 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_11; |
614 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[29] = |
615 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_10; |
616 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[30] = |
617 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_09; |
618 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[31] = |
619 | 1.28k | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_16_08; |
620 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[32] = NULL; |
621 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[33] = NULL; |
622 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[34] = NULL; |
623 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[35] = NULL; |
624 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[36] = NULL; |
625 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[37] = NULL; |
626 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[38] = NULL; |
627 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[39] = NULL; |
628 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[40] = NULL; |
629 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[41] = NULL; |
630 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[42] = NULL; |
631 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[43] = NULL; |
632 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[44] = NULL; |
633 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[45] = NULL; |
634 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[46] = NULL; |
635 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[47] = NULL; |
636 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[48] = NULL; |
637 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[49] = NULL; |
638 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[50] = NULL; |
639 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[51] = NULL; |
640 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[52] = NULL; |
641 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[53] = NULL; |
642 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[54] = NULL; |
643 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[55] = NULL; |
644 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[56] = NULL; |
645 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[57] = NULL; |
646 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[58] = NULL; |
647 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[59] = NULL; |
648 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[60] = NULL; |
649 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[61] = NULL; |
650 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[62] = NULL; |
651 | 1.28k | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[63] = NULL; |
652 | 1.28k | } else if (15 == time_slots) { |
653 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[0] = |
654 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_00; |
655 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[1] = |
656 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_01; |
657 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[2] = |
658 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_02; |
659 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[3] = |
660 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_03; |
661 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[4] = |
662 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_04; |
663 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[5] = |
664 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_05; |
665 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[6] = |
666 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_06; |
667 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[7] = |
668 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_06; |
669 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[8] = |
670 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_05; |
671 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[9] = |
672 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_04; |
673 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[10] = |
674 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_03; |
675 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[11] = |
676 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_02; |
677 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[12] = |
678 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_01; |
679 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[13] = |
680 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_00; |
681 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[14] = |
682 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_07; |
683 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[15] = |
684 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_08; |
685 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[16] = |
686 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_09; |
687 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[17] = |
688 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_10; |
689 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[18] = |
690 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_11; |
691 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[19] = |
692 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_12; |
693 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[20] = |
694 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_13; |
695 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[21] = |
696 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_14; |
697 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[22] = |
698 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_14; |
699 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[23] = |
700 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_13; |
701 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[24] = |
702 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_12; |
703 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[25] = |
704 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_11; |
705 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[26] = |
706 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_10; |
707 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[27] = |
708 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_09; |
709 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[28] = |
710 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_08; |
711 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[29] = |
712 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_long_15_07; |
713 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[30] = NULL; |
714 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[31] = NULL; |
715 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[32] = NULL; |
716 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[33] = NULL; |
717 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[34] = NULL; |
718 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[35] = NULL; |
719 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[36] = NULL; |
720 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[37] = NULL; |
721 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[38] = NULL; |
722 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[39] = NULL; |
723 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[40] = NULL; |
724 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[41] = NULL; |
725 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[42] = NULL; |
726 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[43] = NULL; |
727 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[44] = NULL; |
728 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[45] = NULL; |
729 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[46] = NULL; |
730 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[47] = NULL; |
731 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[48] = NULL; |
732 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[49] = NULL; |
733 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[50] = NULL; |
734 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[51] = NULL; |
735 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[52] = NULL; |
736 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[53] = NULL; |
737 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[54] = NULL; |
738 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[55] = NULL; |
739 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[56] = NULL; |
740 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[57] = NULL; |
741 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[58] = NULL; |
742 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[59] = NULL; |
743 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[60] = NULL; |
744 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[61] = NULL; |
745 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[62] = NULL; |
746 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_long[63] = NULL; |
747 | | |
748 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[4] = |
749 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_short_3_00; |
750 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[5] = |
751 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_short_3_00; |
752 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[6] = |
753 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_short_3_01; |
754 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[7] = |
755 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_short_3_02; |
756 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[8] = |
757 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_short_3_02; |
758 | 15 | pstr_mps_state->ia_mps_dec_mdct2qmfcos_table.cos_table_short[9] = |
759 | 15 | pstr_mps_state->ia_mps_dec_mps_table.mdct2qmfcos_table_ptr->cos_table_short_3_01; |
760 | 15 | } else { |
761 | 0 | if (pstr_mps_state->residual_coding) return IA_XHEAAC_MPS_DEC_EXE_FATAL_INVALID_TIMESLOTS; |
762 | 0 | } |
763 | 1.95k | } |
764 | | |
765 | 4.10k | return IA_NO_ERROR; |
766 | 4.10k | } |
767 | | |
768 | 4.10k | IA_ERRORCODE ixheaacd_mdct2qmf_create(ia_heaac_mps_state_struct *pstr_mps_state) { |
769 | 4.10k | IA_ERRORCODE error_code = IA_NO_ERROR; |
770 | | |
771 | 4.10k | WORD32 *qmf_residual_real = pstr_mps_state->array_struct->qmf_residual_real_pre; |
772 | 4.10k | WORD32 *qmf_residual_imag = pstr_mps_state->array_struct->qmf_residual_imag_pre; |
773 | | |
774 | 4.10k | memset(qmf_residual_real, 0, RES_CHXQMFXTSX4); |
775 | 4.10k | memset(qmf_residual_imag, 0, RES_CHXQMFXTSX4); |
776 | | |
777 | 4.10k | error_code = ixheaacd_mdct2qmf_tables_init(pstr_mps_state); |
778 | | |
779 | 4.10k | return error_code; |
780 | 4.10k | } |
781 | | |
782 | 2.15k | static VOID ixheaacd_local_zero(WORD32 const l, WORD32 *const b) { |
783 | 2.15k | WORD32 i; |
784 | | |
785 | 324k | for (i = 0; i < l; i++) { |
786 | 322k | b[i] = 0; |
787 | 322k | } |
788 | 2.15k | } |
789 | | |
790 | | ATTR_NO_SANITIZE_INTEGER |
791 | | static VOID ixheaacd_local_fold_out(WORD32 *const s, WORD32 const lv, WORD32 *const w, |
792 | | WORD32 const l_w, WORD32 *const v_main, |
793 | 2.51k | WORD32 *const v_slave) { |
794 | 2.51k | WORD32 n; |
795 | 2.51k | WORD32 i; |
796 | 2.51k | WORD32 j; |
797 | 2.51k | WORD32 k; |
798 | | |
799 | 2.51k | WORD32 temp_1; |
800 | | |
801 | 2.51k | WORD32 *w1; |
802 | 2.51k | WORD32 *w2; |
803 | 2.51k | WORD32 *w3; |
804 | 2.51k | WORD32 *w4; |
805 | 2.51k | WORD32 *ptr1, *ptr2, *ptr3; |
806 | | |
807 | 2.51k | WORD32 m = l_w >> 1; |
808 | 2.51k | WORD32 l = lv / m; |
809 | 2.51k | WORD32 m2w = m >> 1; |
810 | 2.51k | WORD32 m2a = m - m2w; |
811 | | |
812 | 42.7k | for (i = m; i < lv; i += l_w) { |
813 | 610k | for (n = i + l_w; i < n; i++) { |
814 | 569k | s[i] = -s[i]; |
815 | 569k | } |
816 | 40.2k | } |
817 | | |
818 | 2.51k | w1 = &w[-m2a]; |
819 | 2.51k | w2 = &w[m2w]; |
820 | 2.51k | w3 = &w[m2w]; |
821 | 2.51k | w4 = &w[m + m2w]; |
822 | | |
823 | 160k | for (n = 0, j = 0, k = m; n < l - 1; n++) { |
824 | 719k | for (i = 0; i < m2a; i++, j++, k++) { |
825 | 560k | v_main[k] = ixheaacd_mps_mult32_shr_30(w2[i], s[k]); |
826 | 560k | v_slave[j] = ixheaacd_mps_mult32_shr_30(w4[i], s[k]); |
827 | 560k | } |
828 | | |
829 | 719k | for (; i < m; i++, j++, k++) { |
830 | 560k | v_main[j] = ixheaacd_mps_mult32_shr_30(w3[i], s[j]); |
831 | 560k | v_slave[k] = ixheaacd_mps_mult32_shr_30(w1[i], s[j]); |
832 | 560k | } |
833 | 158k | } |
834 | | |
835 | 2.51k | ptr1 = v_main; |
836 | 2.51k | ptr2 = v_slave + m - 1; |
837 | 2.51k | ptr3 = s; |
838 | 11.4k | for (i = 0; i < m2a; i++) { |
839 | 8.90k | temp_1 = *ptr3++; |
840 | 8.90k | *ptr1++ = ixheaacd_mps_mult32_shr_30(*w2++, temp_1); |
841 | 8.90k | *ptr2-- = ixheaacd_mps_mult32_shr_30(*w4++, temp_1); |
842 | 8.90k | } |
843 | | |
844 | 2.51k | j = l * m - m2w; |
845 | 2.51k | k = l * m - m2a - 1; |
846 | 2.51k | ptr3 = s + l * m - m; |
847 | 2.51k | ptr1 = v_main + j; |
848 | 2.51k | ptr2 = v_slave + k; |
849 | | |
850 | 2.51k | w1 += m2a; |
851 | 11.4k | for (; i < m; i++, j++) { |
852 | 8.90k | temp_1 = *ptr3++; |
853 | 8.90k | *ptr1++ = ixheaacd_mps_mult32_shr_30(*w2++, temp_1); |
854 | 8.90k | *ptr2-- = ixheaacd_mps_mult32_shr_30(*w1++, temp_1); |
855 | 8.90k | } |
856 | 2.51k | } |
857 | | |
858 | | static VOID ixheaacd_local_imdet( |
859 | | WORD32 *x1, WORD32 *x2, WORD32 *const scale1, WORD32 const val, WORD32 *z_real, |
860 | | WORD32 *z_imag, const ia_mps_dec_mdct2qmf_cos_table_struct *ia_mps_dec_mdct2qmfcos_tab, |
861 | 2.51k | WORD32 is_long, VOID *scratch) { |
862 | 2.51k | WORD32 lw = val << 1; |
863 | 2.51k | WORD32 offset = val - (val >> 1); |
864 | | |
865 | 2.51k | WORD32 temp_1, temp3, temp_2; |
866 | 2.51k | WORD32 *z_real_2, *z_imag_2; |
867 | 2.51k | WORD32 *px1, *px2, *px3, *px4; |
868 | 2.51k | const WORD16 *cp, *sp; |
869 | 2.51k | WORD32 *scale; |
870 | 2.51k | WORD32 cnt = val + (val >> 1); |
871 | | |
872 | 2.51k | WORD32 k; |
873 | 2.51k | WORD32 n, j; |
874 | | |
875 | 2.51k | WORD32 l; |
876 | | |
877 | 2.51k | WORD32 *p_sum = scratch; |
878 | 2.51k | WORD32 *p_diff = |
879 | 2.51k | (WORD32 *)scratch + IXHEAAC_GET_SIZE_ALIGNED_TYPE(SUM_SIZE, sizeof(*p_diff), BYTE_ALIGN_8); |
880 | | |
881 | 2.51k | z_real_2 = z_real + lw; |
882 | 2.51k | z_imag_2 = z_imag + lw; |
883 | | |
884 | 82.9k | for (l = 0; l < LOOP_COUNTER; l++) { |
885 | 80.4k | WORD32 *sum = p_sum; |
886 | 80.4k | WORD32 *diff = p_diff; |
887 | | |
888 | 80.4k | px1 = x1; |
889 | 80.4k | px2 = x2 + val - 1; |
890 | 80.4k | px3 = x2 + val; |
891 | 80.4k | px4 = x1 + 2 * val - 1; |
892 | | |
893 | 650k | for (n = 0; n < val; n++) { |
894 | 569k | *sum++ = ixheaac_add32_sat(*px1, *px2); |
895 | 569k | *sum++ = ixheaac_add32_sat(*px3, *px4); |
896 | 569k | *diff++ = ixheaac_sub32_sat(*px1++, *px2--); |
897 | 569k | *diff++ = ixheaac_sub32_sat(*px3++, *px4--); |
898 | 569k | } |
899 | | |
900 | 80.4k | scale = scale1; |
901 | 935k | for (k = 0; k < cnt; k++) { |
902 | 854k | if (1 == is_long) { |
903 | 574k | cp = ia_mps_dec_mdct2qmfcos_tab->cos_table_long[k]; |
904 | 574k | sp = cp + val; |
905 | 574k | } else { |
906 | 280k | cp = ia_mps_dec_mdct2qmfcos_tab->cos_table_short[k + is_long]; |
907 | 280k | sp = cp + val; |
908 | 280k | } |
909 | | |
910 | 854k | sum = p_sum; |
911 | 854k | diff = p_diff; |
912 | | |
913 | 854k | temp_1 = *cp++; |
914 | 854k | temp_2 = ixheaacd_mps_mult32_shr_15(temp_1, *sum); |
915 | 854k | sum++; |
916 | 854k | *z_real = temp_2; |
917 | | |
918 | 854k | temp_2 = ixheaacd_mps_mult32_shr_15(temp_1, *sum); |
919 | 854k | sum++; |
920 | 854k | *z_real_2 = temp_2; |
921 | | |
922 | 854k | temp_1 = *--sp; |
923 | 854k | temp_2 = ixheaacd_mps_mult32_shr_15(temp_1, *diff); |
924 | 854k | diff++; |
925 | 854k | *z_imag = temp_2; |
926 | | |
927 | 854k | temp_2 = ixheaacd_mps_mult32_shr_15(temp_1, *diff); |
928 | 854k | diff++; |
929 | 854k | *z_imag_2 = temp_2; |
930 | 14.2M | for (n = 1; n < val; n++) { |
931 | 13.3M | temp_1 = *cp++; |
932 | 13.3M | temp_2 = ixheaacd_mps_mult32_shr_15(temp_1, *sum); |
933 | 13.3M | sum++; |
934 | 13.3M | *z_real = ixheaac_add32_sat(*z_real, temp_2); |
935 | | |
936 | 13.3M | temp_2 = ixheaacd_mps_mult32_shr_15(temp_1, *sum); |
937 | 13.3M | sum++; |
938 | 13.3M | *z_real_2 = ixheaac_add32_sat(*z_real_2, temp_2); |
939 | | |
940 | 13.3M | temp_1 = *--sp; |
941 | 13.3M | temp_2 = ixheaacd_mps_mult32_shr_15(temp_1, *diff); |
942 | 13.3M | diff++; |
943 | 13.3M | *z_imag = ixheaac_add32_sat(*z_imag, temp_2); |
944 | | |
945 | 13.3M | temp_2 = ixheaacd_mps_mult32_shr_15(temp_1, *diff); |
946 | 13.3M | diff++; |
947 | 13.3M | *z_imag_2 = ixheaac_add32_sat(*z_imag_2, temp_2); |
948 | 13.3M | } |
949 | 854k | z_real++; |
950 | 854k | z_imag++; |
951 | 854k | z_real_2++; |
952 | 854k | z_imag_2++; |
953 | 854k | } |
954 | 80.4k | z_real -= cnt; |
955 | 80.4k | z_real_2 -= cnt; |
956 | 80.4k | z_imag -= cnt; |
957 | 80.4k | z_imag_2 -= cnt; |
958 | | |
959 | 935k | for (j = 0; j < (cnt); j++) { |
960 | 854k | *z_real = ixheaacd_mps_mult32_shr_15(*z_real, *scale); |
961 | 854k | z_real++; |
962 | 854k | *z_imag = ixheaacd_mps_mult32_shr_15(*z_imag, *scale); |
963 | 854k | z_imag++; |
964 | 854k | *z_real_2 = ixheaacd_mps_mult32_shr_15(*z_real_2, *scale); |
965 | 854k | z_real_2++; |
966 | 854k | *z_imag_2 = ixheaacd_mps_mult32_shr_15(*z_imag_2, *scale); |
967 | 854k | scale++; |
968 | 854k | z_imag_2++; |
969 | 854k | } |
970 | | |
971 | 365k | for (; k < lw; k++) { |
972 | 284k | if (1 == is_long) { |
973 | 191k | cp = ia_mps_dec_mdct2qmfcos_tab->cos_table_long[k]; |
974 | 191k | sp = cp + val; |
975 | 191k | } else { |
976 | 93.4k | cp = ia_mps_dec_mdct2qmfcos_tab->cos_table_short[k + is_long]; |
977 | 93.4k | sp = cp + val; |
978 | 93.4k | } |
979 | | |
980 | 284k | sum = p_sum; |
981 | 284k | diff = p_diff; |
982 | | |
983 | 284k | temp_1 = *cp++; |
984 | | |
985 | 284k | temp3 = ixheaacd_mps_mult32_shr_15(temp_1, *sum); |
986 | 284k | sum++; |
987 | 284k | *z_real = temp3; |
988 | | |
989 | 284k | temp3 = ixheaacd_mps_mult32_shr_15(temp_1, *sum); |
990 | 284k | sum++; |
991 | 284k | *z_real_2 = temp3; |
992 | | |
993 | 284k | temp_1 = *--sp; |
994 | 284k | temp3 = ixheaacd_mps_mult32_shr_15(temp_1, *diff); |
995 | 284k | diff++; |
996 | 284k | *z_imag = temp3; |
997 | | |
998 | 284k | temp3 = ixheaacd_mps_mult32_shr_15(temp_1, *diff); |
999 | 284k | diff++; |
1000 | 284k | *z_imag_2 = temp3; |
1001 | | |
1002 | 4.74M | for (n = 1; n < val; n++) { |
1003 | 4.46M | temp_1 = *cp++; |
1004 | 4.46M | temp3 = ixheaacd_mps_mult32_shr_15(temp_1, *sum); |
1005 | 4.46M | sum++; |
1006 | 4.46M | *z_real = ixheaac_add32_sat(*z_real, temp3); |
1007 | | |
1008 | 4.46M | temp3 = ixheaacd_mps_mult32_shr_15(temp_1, *sum); |
1009 | 4.46M | sum++; |
1010 | 4.46M | *z_real_2 = ixheaac_add32_sat(*z_real_2, temp3); |
1011 | | |
1012 | 4.46M | temp_1 = *--sp; |
1013 | 4.46M | temp3 = ixheaacd_mps_mult32_shr_15(temp_1, *diff); |
1014 | 4.46M | diff++; |
1015 | 4.46M | *z_imag = ixheaac_add32_sat(*z_imag, temp3); |
1016 | | |
1017 | 4.46M | temp3 = ixheaacd_mps_mult32_shr_15(temp_1, *diff); |
1018 | 4.46M | diff++; |
1019 | 4.46M | *z_imag_2 = ixheaac_add32_sat(*z_imag_2, temp3); |
1020 | 4.46M | } |
1021 | | |
1022 | 284k | z_real++; |
1023 | 284k | z_imag++; |
1024 | 284k | z_real_2++; |
1025 | 284k | z_imag_2++; |
1026 | 284k | } |
1027 | 80.4k | z_real -= offset; |
1028 | 80.4k | z_real_2 -= offset; |
1029 | 80.4k | z_imag -= offset; |
1030 | 80.4k | z_imag_2 -= offset; |
1031 | | |
1032 | 365k | for (j = 0; j < (offset); j++) { |
1033 | 284k | temp_1 = (*scale++) * -1; |
1034 | 284k | *z_real = ixheaacd_mps_mult32_shr_15(*z_real, temp_1); |
1035 | 284k | z_real++; |
1036 | 284k | *z_imag = ixheaacd_mps_mult32_shr_15(*z_imag, temp_1); |
1037 | 284k | z_imag++; |
1038 | 284k | *z_real_2 = ixheaacd_mps_mult32_shr_15(*z_real_2, temp_1); |
1039 | 284k | z_real_2++; |
1040 | 284k | *z_imag_2 = ixheaacd_mps_mult32_shr_15(*z_imag_2, temp_1); |
1041 | 284k | z_imag_2++; |
1042 | 284k | } |
1043 | | |
1044 | 80.4k | x1 += lw; |
1045 | 80.4k | x2 += lw; |
1046 | | |
1047 | 80.4k | z_real += lw; |
1048 | 80.4k | z_imag += lw; |
1049 | 80.4k | z_imag_2 += lw; |
1050 | 80.4k | z_real_2 += lw; |
1051 | 80.4k | } |
1052 | 2.51k | } |
1053 | | |
1054 | | static VOID ixheaacd_local_hybcmdct2qmf( |
1055 | | WORD32 *const v_main, WORD32 *const v_slave, WORD32 *const w, WORD32 const lw, WORD32 *z_real, |
1056 | | WORD32 *z_imag, const ia_mps_dec_mdct2qmf_cos_table_struct *ia_mps_dec_mdct2qmfcos_tab, |
1057 | 2.51k | VOID *scratch, WORD32 is_long) { |
1058 | 2.51k | WORD32 i, start = 0; |
1059 | 2.51k | WORD32 m = lw >> 1; |
1060 | | |
1061 | 2.51k | switch (lw) { |
1062 | 999 | case TSX2_4: |
1063 | 999 | case TSX2_6: |
1064 | 999 | case TSX2_30: |
1065 | 1.04k | case TSX2_36: |
1066 | 1.04k | case TSX2_60: |
1067 | 1.04k | start = 1; |
1068 | 1.04k | break; |
1069 | | |
1070 | 960 | case TSX2_8: |
1071 | 1.18k | case TSX2_32: |
1072 | 1.37k | case TSX2_48: |
1073 | 1.46k | case TSX2_64: |
1074 | 1.46k | start = 0; |
1075 | 1.46k | break; |
1076 | | |
1077 | 0 | default: |
1078 | 0 | break; |
1079 | 2.51k | } |
1080 | | |
1081 | 2.51k | ixheaacd_local_imdet(v_slave, v_main, w, m, z_real, z_imag, ia_mps_dec_mdct2qmfcos_tab, is_long, |
1082 | 2.51k | scratch); |
1083 | | |
1084 | 1.14M | for (i = start; i < (m << 7); i += 2) { |
1085 | 1.13M | z_imag[i] = -(z_imag[i]); |
1086 | 1.13M | } |
1087 | | |
1088 | 2.51k | return; |
1089 | 2.51k | } |
1090 | | |
1091 | 0 | static VOID ixheaacd_local_p_zero_ts15(WORD32 *const b, WORD32 *src, WORD32 l) { |
1092 | 0 | WORD32 i; |
1093 | |
|
1094 | 0 | for (i = 0; i < 15; i++) { |
1095 | 0 | b[i] = *src++; |
1096 | 0 | } |
1097 | 0 | if (l != 15) { |
1098 | 0 | src--; |
1099 | 0 | for (; i < l; i++) { |
1100 | 0 | b[i] = *--src; |
1101 | 0 | } |
1102 | 0 | } |
1103 | 0 | } |
1104 | | |
1105 | 50 | static VOID ixheaacd_local_p_nonzero(WORD32 *const b, WORD32 *src, WORD32 l) { |
1106 | 50 | WORD32 i; |
1107 | | |
1108 | 938 | for (i = 0; i < l; i++) { |
1109 | 888 | b[i] = *src--; |
1110 | 888 | } |
1111 | 50 | } |
1112 | | |
1113 | 505 | static VOID ixheaacd_local_p_zero(WORD32 *const b, WORD32 *src, WORD32 l, WORD32 upd_qmf) { |
1114 | 505 | WORD32 i; |
1115 | | |
1116 | 11.5k | for (i = 0; i < upd_qmf; i++) { |
1117 | 11.0k | b[i] = *src++; |
1118 | 11.0k | } |
1119 | 505 | if (l != upd_qmf) { |
1120 | 8.78k | for (; i < l; i++) { |
1121 | 8.40k | b[i] = *--src; |
1122 | 8.40k | } |
1123 | 385 | } |
1124 | 505 | } |
1125 | | |
1126 | | static VOID ixheaacd_local_sin(WORD32 const t, WORD32 const p, WORD32 const l, WORD32 *const b, |
1127 | 959 | ia_mps_dec_mdct2qmf_table_struct *mdct2qmf_tab) { |
1128 | 959 | WORD32 *sin_ptr; |
1129 | | |
1130 | 959 | switch (t) { |
1131 | 264 | case TS_2: |
1132 | 264 | switch (p) { |
1133 | 162 | case ZERO: |
1134 | 162 | b[0] = 12540; |
1135 | 162 | b[1] = 30274; |
1136 | 162 | if (l == TSX2_4) { |
1137 | 114 | b[2] = b[1]; |
1138 | 114 | b[3] = b[0]; |
1139 | 114 | } |
1140 | 162 | break; |
1141 | 102 | case TS_2: |
1142 | 102 | b[0] = 30274; |
1143 | 102 | b[1] = 12540; |
1144 | 102 | break; |
1145 | 0 | default: |
1146 | 0 | break; |
1147 | 264 | } |
1148 | 264 | break; |
1149 | 264 | case TS_4: |
1150 | 140 | switch (p) { |
1151 | 122 | case ZERO: |
1152 | 122 | sin_ptr = mdct2qmf_tab->local_sin_4; |
1153 | 122 | b[0] = *sin_ptr++; |
1154 | 122 | b[1] = *sin_ptr++; |
1155 | 122 | b[2] = *sin_ptr++; |
1156 | 122 | b[3] = *sin_ptr; |
1157 | 122 | if (l == TSX2_8) { |
1158 | 120 | b[4] = *sin_ptr--; |
1159 | 120 | b[5] = *sin_ptr--; |
1160 | 120 | b[6] = *sin_ptr--; |
1161 | 120 | b[7] = *sin_ptr; |
1162 | 120 | } |
1163 | 122 | break; |
1164 | 18 | case TS_4: |
1165 | 18 | sin_ptr = &(mdct2qmf_tab->local_sin_4[TS_MINUS_ONE_4]); |
1166 | 18 | b[0] = *sin_ptr--; |
1167 | 18 | b[1] = *sin_ptr--; |
1168 | 18 | b[2] = *sin_ptr--; |
1169 | 18 | b[3] = *sin_ptr; |
1170 | 18 | break; |
1171 | 0 | default: |
1172 | 0 | break; |
1173 | 140 | } |
1174 | 140 | break; |
1175 | 140 | case UPD_QMF_15: |
1176 | 0 | switch (p) { |
1177 | 0 | case ZERO: |
1178 | 0 | sin_ptr = &(mdct2qmf_tab->local_sin_15[1]); |
1179 | 0 | ixheaacd_local_p_zero_ts15(b, sin_ptr, l); |
1180 | 0 | break; |
1181 | 0 | case UPD_QMF_15: |
1182 | 0 | sin_ptr = &(mdct2qmf_tab->local_sin_15[TS_MINUS_ONE_15]); |
1183 | 0 | ixheaacd_local_p_nonzero(b, sin_ptr, l); |
1184 | 0 | break; |
1185 | 0 | default: |
1186 | 0 | break; |
1187 | 0 | } |
1188 | 0 | break; |
1189 | 228 | case UPD_QMF_16: |
1190 | 228 | switch (p) { |
1191 | 190 | case ZERO: |
1192 | 190 | sin_ptr = mdct2qmf_tab->local_sin_16; |
1193 | 190 | ixheaacd_local_p_zero(b, sin_ptr, l, UPD_QMF_16); |
1194 | 190 | break; |
1195 | 38 | case UPD_QMF_16: |
1196 | 38 | sin_ptr = &(mdct2qmf_tab->local_sin_16[TS_MINUS_ONE_16]); |
1197 | 38 | ixheaacd_local_p_nonzero(b, sin_ptr, l); |
1198 | 38 | break; |
1199 | 0 | default: |
1200 | 0 | break; |
1201 | 228 | } |
1202 | 228 | break; |
1203 | 228 | case UPD_QMF_18: |
1204 | 49 | switch (p) { |
1205 | 45 | case ZERO: |
1206 | 45 | sin_ptr = mdct2qmf_tab->local_sin_18; |
1207 | 45 | ixheaacd_local_p_zero(b, sin_ptr, l, UPD_QMF_18); |
1208 | 45 | break; |
1209 | 4 | case UPD_QMF_18: |
1210 | 4 | sin_ptr = &(mdct2qmf_tab->local_sin_18[TS_MINUS_ONE_18]); |
1211 | 4 | ixheaacd_local_p_nonzero(b, sin_ptr, l); |
1212 | 4 | break; |
1213 | 0 | default: |
1214 | 0 | break; |
1215 | 49 | } |
1216 | 49 | break; |
1217 | 182 | case UPD_QMF_24: |
1218 | 182 | switch (p) { |
1219 | 176 | case ZERO: |
1220 | 176 | sin_ptr = mdct2qmf_tab->local_sin_24; |
1221 | 176 | ixheaacd_local_p_zero(b, sin_ptr, l, UPD_QMF_24); |
1222 | 176 | break; |
1223 | 6 | case UPD_QMF_24: |
1224 | 6 | sin_ptr = &(mdct2qmf_tab->local_sin_24[TS_MINUS_ONE_24]); |
1225 | 6 | ixheaacd_local_p_nonzero(b, sin_ptr, l); |
1226 | 6 | break; |
1227 | 0 | default: |
1228 | 0 | break; |
1229 | 182 | } |
1230 | 182 | break; |
1231 | 182 | case UPD_QMF_30: |
1232 | 0 | switch (p) { |
1233 | 0 | case ZERO: |
1234 | 0 | sin_ptr = mdct2qmf_tab->local_sin_30; |
1235 | 0 | ixheaacd_local_p_zero(b, sin_ptr, l, UPD_QMF_30); |
1236 | 0 | break; |
1237 | 0 | case UPD_QMF_30: |
1238 | 0 | sin_ptr = &(mdct2qmf_tab->local_sin_30[TS_MINUS_ONE_30]); |
1239 | 0 | ixheaacd_local_p_nonzero(b, sin_ptr, l); |
1240 | 0 | break; |
1241 | 0 | default: |
1242 | 0 | break; |
1243 | 0 | } |
1244 | 0 | break; |
1245 | 96 | case UPD_QMF_32: |
1246 | 96 | switch (p) { |
1247 | 94 | case ZERO: |
1248 | 94 | sin_ptr = mdct2qmf_tab->local_sin_32; |
1249 | 94 | ixheaacd_local_p_zero(b, sin_ptr, l, UPD_QMF_32); |
1250 | 94 | break; |
1251 | 2 | case UPD_QMF_32: |
1252 | 2 | sin_ptr = &(mdct2qmf_tab->local_sin_32[TS_MINUS_ONE_32]); |
1253 | 2 | ixheaacd_local_p_nonzero(b, sin_ptr, l); |
1254 | | |
1255 | 2 | break; |
1256 | 0 | default: |
1257 | 0 | break; |
1258 | 96 | } |
1259 | 96 | break; |
1260 | 96 | default: |
1261 | 0 | break; |
1262 | 959 | } |
1263 | 959 | return; |
1264 | 959 | } |
1265 | | |
1266 | 170 | static VOID ixheaacd_local_one(WORD32 const l, WORD32 *const b) { |
1267 | 170 | WORD32 i; |
1268 | | |
1269 | 1.76k | for (i = 0; i < l; i++) { |
1270 | 1.59k | b[i] = ONE_IN_Q15; |
1271 | 1.59k | } |
1272 | 170 | } |
1273 | | |
1274 | 789 | static VOID ixheaacd_local_freq_win(WORD32 const l, WORD32 *const b, const WORD32 **wf) { |
1275 | 789 | WORD32 i; |
1276 | 789 | WORD32 odd_length = (l & ONE_BIT_MASK); |
1277 | 789 | WORD32 temp_1; |
1278 | 789 | WORD32 *b_start, *b_end; |
1279 | 789 | b_start = b; |
1280 | 789 | b_end = b + 2 * l - 1 - odd_length; |
1281 | | |
1282 | 13.4k | for (i = 0; i < l - odd_length; i++) { |
1283 | 12.6k | temp_1 = wf[l - 1][i]; |
1284 | 12.6k | *b_start++ = temp_1; |
1285 | 12.6k | *b_end-- = temp_1; |
1286 | 12.6k | } |
1287 | | |
1288 | 789 | if (odd_length == 1) { |
1289 | 0 | *b_start = wf[l - 1][l - 1]; |
1290 | 0 | *(b_start + l) = 0; |
1291 | 0 | } |
1292 | 789 | } |
1293 | | |
1294 | | static VOID ixheaacd_local_mdct_win(WORD32 upd_qmf, WORD32 const window_type, WORD32 *const wf, |
1295 | | WORD32 const **wf_tab, WORD32 *const wt, |
1296 | 789 | ia_mps_dec_mdct2qmf_table_struct *mdct2qmf_tab) { |
1297 | 789 | WORD32 length = 0; |
1298 | 789 | WORD32 length_right = 0; |
1299 | 789 | WORD32 length_left = 0; |
1300 | 789 | WORD32 length_const1 = 0; |
1301 | 789 | WORD32 length_const2 = 0; |
1302 | | |
1303 | 789 | switch (window_type) { |
1304 | 385 | case ONLY_LONG_SEQUENCE: |
1305 | 385 | length = upd_qmf; |
1306 | 385 | ixheaacd_local_sin(upd_qmf, 0, (length << 1), &wt[0], mdct2qmf_tab); |
1307 | 385 | break; |
1308 | 120 | case LONG_START_SEQUENCE: |
1309 | 120 | switch (upd_qmf) { |
1310 | 0 | case UPD_QMF_15: |
1311 | 0 | length_const1 = 6; |
1312 | 0 | length_const2 = 7; |
1313 | 0 | length_right = 2; |
1314 | 0 | break; |
1315 | 37 | case UPD_QMF_16: |
1316 | 55 | case UPD_QMF_32: |
1317 | 55 | length_const1 = 7 * (upd_qmf >> 4); |
1318 | 55 | length_const2 = length_const1; |
1319 | 55 | length_right = upd_qmf >> 3; |
1320 | 55 | break; |
1321 | 8 | case UPD_QMF_18: |
1322 | 8 | length_const1 = 8; |
1323 | 8 | length_const2 = length_const1; |
1324 | 8 | length_right = 2; |
1325 | 8 | break; |
1326 | 57 | case UPD_QMF_24: |
1327 | 57 | length_const1 = 11; |
1328 | 57 | length_const2 = length_const1; |
1329 | 57 | length_right = 2; |
1330 | 57 | break; |
1331 | 0 | case UPD_QMF_30: |
1332 | 0 | length_const1 = 14; |
1333 | 0 | length_const2 = length_const1; |
1334 | 0 | length_right = 2; |
1335 | 0 | break; |
1336 | 0 | default: |
1337 | 0 | length_const1 = 6; |
1338 | 0 | length_const2 = 7; |
1339 | 0 | length_right = 2; |
1340 | 0 | break; |
1341 | 120 | } |
1342 | | |
1343 | 120 | ixheaacd_local_sin(upd_qmf, 0, upd_qmf, &wt[0], mdct2qmf_tab); |
1344 | 120 | ixheaacd_local_one(length_const1, &wt[upd_qmf]); |
1345 | 120 | ixheaacd_local_sin(length_right, length_right, length_right, &wt[upd_qmf + length_const1], |
1346 | 120 | mdct2qmf_tab); |
1347 | | |
1348 | 120 | ixheaacd_local_zero(length_const2, &wt[upd_qmf + length_const1 + length_right]); |
1349 | 120 | length = upd_qmf; |
1350 | 120 | break; |
1351 | 234 | case EIGHT_SHORT_SEQUENCE: |
1352 | 234 | switch (upd_qmf) { |
1353 | 87 | case UPD_QMF_16: |
1354 | 207 | case UPD_QMF_32: |
1355 | 207 | length = upd_qmf >> 3; |
1356 | 207 | break; |
1357 | 0 | case UPD_QMF_15: |
1358 | 7 | case UPD_QMF_18: |
1359 | 7 | case UPD_QMF_30: |
1360 | 27 | case UPD_QMF_24: |
1361 | 27 | length = 2; |
1362 | 27 | break; |
1363 | 0 | default: |
1364 | 0 | break; |
1365 | 234 | } |
1366 | 234 | ixheaacd_local_sin(length, 0, 2 * length, &wt[0], mdct2qmf_tab); |
1367 | 234 | break; |
1368 | 50 | case LONG_STOP_SEQUENCE: |
1369 | 50 | switch (upd_qmf) { |
1370 | 0 | case UPD_QMF_15: |
1371 | 0 | length_const1 = 6; |
1372 | 0 | length_const2 = 7; |
1373 | 0 | length_left = 2; |
1374 | 0 | break; |
1375 | 38 | case UPD_QMF_16: |
1376 | 40 | case UPD_QMF_32: |
1377 | 40 | length_const1 = 7 * (upd_qmf >> 4); |
1378 | 40 | length_const2 = length_const1; |
1379 | 40 | length_left = upd_qmf >> 3; |
1380 | 40 | break; |
1381 | 4 | case UPD_QMF_18: |
1382 | 4 | length_const1 = 8; |
1383 | 4 | length_const2 = length_const1; |
1384 | 4 | length_left = 2; |
1385 | 4 | break; |
1386 | 6 | case UPD_QMF_24: |
1387 | 6 | length_const1 = 11; |
1388 | 6 | length_const2 = length_const1; |
1389 | 6 | length_left = 2; |
1390 | 6 | break; |
1391 | 0 | case UPD_QMF_30: |
1392 | 0 | length_const1 = 14; |
1393 | 0 | length_const2 = length_const1; |
1394 | 0 | length_left = 2; |
1395 | 0 | break; |
1396 | 0 | default: |
1397 | 0 | break; |
1398 | 50 | } |
1399 | | |
1400 | 50 | ixheaacd_local_zero(length_const1, &wt[0]); |
1401 | 50 | ixheaacd_local_sin(length_left, 0, length_left, &wt[length_const1], mdct2qmf_tab); |
1402 | 50 | ixheaacd_local_one(length_const2, &wt[length_const1 + length_left]); |
1403 | 50 | ixheaacd_local_sin(upd_qmf, upd_qmf, upd_qmf, |
1404 | 50 | &wt[length_const1 + length_left + length_const2], mdct2qmf_tab); |
1405 | 50 | length = upd_qmf; |
1406 | 50 | break; |
1407 | 0 | default: |
1408 | 0 | break; |
1409 | 789 | } |
1410 | | |
1411 | 789 | ixheaacd_local_freq_win(length, &wf[0], wf_tab); |
1412 | | |
1413 | 789 | if ((upd_qmf == UPD_QMF_15) && (window_type == EIGHT_SHORT_SEQUENCE)) { |
1414 | 0 | WORD32 length2 = 3; |
1415 | |
|
1416 | 0 | ixheaacd_local_sin(length, 0, length, &wt[(length << 1)], mdct2qmf_tab); |
1417 | 0 | ixheaacd_local_one(1, &wt[3 * length]); |
1418 | 0 | ixheaacd_local_sin(length, length, length, &wt[3 * length + 1], mdct2qmf_tab); |
1419 | 0 | ixheaacd_local_zero(1, &wt[(length << 2) + 1]); |
1420 | |
|
1421 | 0 | ixheaacd_local_freq_win(length2, &wf[(length << 1)], wf_tab); |
1422 | 0 | } |
1423 | 789 | return; |
1424 | 789 | } |
1425 | | |
1426 | 789 | static VOID ixheaacd_get_gain(WORD32 l, WORD32 *gain) { |
1427 | 789 | switch (l) { |
1428 | 114 | case TSX2_4: |
1429 | 114 | *gain = 16384; |
1430 | 114 | break; |
1431 | | |
1432 | 0 | case TSX2_6: |
1433 | 0 | *gain = 13377; |
1434 | 0 | break; |
1435 | | |
1436 | 120 | case TSX2_8: |
1437 | 120 | *gain = 11585; |
1438 | 120 | break; |
1439 | | |
1440 | 0 | case TSX2_30: |
1441 | 0 | *gain = 5982; |
1442 | 0 | break; |
1443 | | |
1444 | 228 | case TSX2_32: |
1445 | 228 | *gain = 5792; |
1446 | 228 | break; |
1447 | | |
1448 | 49 | case TSX2_36: |
1449 | 49 | *gain = 5461; |
1450 | 49 | break; |
1451 | | |
1452 | 182 | case TSX2_48: |
1453 | 182 | *gain = 4729; |
1454 | 182 | break; |
1455 | | |
1456 | 0 | case TSX2_60: |
1457 | 0 | *gain = 4230; |
1458 | 0 | break; |
1459 | | |
1460 | 96 | case TSX2_64: |
1461 | 96 | *gain = 4096; |
1462 | 96 | break; |
1463 | | |
1464 | 0 | default: |
1465 | 0 | break; |
1466 | 789 | } |
1467 | | |
1468 | 789 | return; |
1469 | 789 | } |
1470 | | |
1471 | | VOID ixheaacd_mdct2qmf_process(WORD32 upd_qmf, WORD32 *const mdct_in, WORD32 *qmf_real_pre, |
1472 | | WORD32 *qmf_real_post, WORD32 *qmf_imag_pre, WORD32 *qmf_imag_post, |
1473 | | WORD32 const window_type, WORD32 qmf_global_offset, |
1474 | | ia_mps_dec_mps_tables_struct *ia_mps_dec_mps_table_ptr, |
1475 | 789 | VOID *scratch, WORD32 time_slots) { |
1476 | 789 | WORD32 i; |
1477 | 789 | WORD32 j; |
1478 | 789 | WORD32 k; |
1479 | | |
1480 | 789 | WORD32 l = (upd_qmf << 1); |
1481 | | |
1482 | 789 | WORD32 n = 0; |
1483 | 789 | WORD32 *wf; |
1484 | 789 | WORD32 *wt; |
1485 | | |
1486 | 789 | WORD32 *v1; |
1487 | 789 | WORD32 *v2; |
1488 | | |
1489 | 789 | WORD32 *z1_real; |
1490 | 789 | WORD32 *z1_imag; |
1491 | | |
1492 | 789 | WORD32 *twipost_real; |
1493 | 789 | WORD32 *twipost_imag; |
1494 | | |
1495 | 789 | WORD32 *mdct_sf, *mdct_sf_ptr; |
1496 | 789 | WORD32 *mdct_p, *mdct_p2; |
1497 | | |
1498 | 789 | WORD32 temp_2, temp3, temp4; |
1499 | | |
1500 | 789 | WORD32 *p_qmf_real_pre = qmf_real_pre; |
1501 | 789 | WORD32 *p_qmf_real_post = qmf_real_post; |
1502 | 789 | WORD32 *p_qmf_imag_pre = qmf_imag_pre; |
1503 | 789 | WORD32 *p_qmf_imag_post = qmf_imag_post; |
1504 | | |
1505 | 789 | VOID *free_scratch; |
1506 | | |
1507 | 789 | WORD32 const **wf_tab = ia_mps_dec_mps_table_ptr->wf_tab_ptr->wf; |
1508 | | |
1509 | 789 | WORD32 window_offset = 0; |
1510 | | |
1511 | 789 | WORD32 mdct_offset = 0; |
1512 | 789 | WORD32 mdct_shift = AAC_SHORT_FRAME_LENGTH; |
1513 | | |
1514 | 789 | WORD32 qmf_offset = 0; |
1515 | 789 | WORD32 qmf_shift = 0; |
1516 | | |
1517 | 789 | WORD32 n_windows = 0; |
1518 | | |
1519 | 789 | WORD32 mdct_length = MDCT_LENGTH_LO; |
1520 | | |
1521 | 789 | WORD32 qmf_bands = 64; |
1522 | 789 | const WORD32 *ptr1, *ptr2; |
1523 | 789 | WORD32 is_long; |
1524 | 789 | WORD32 *zr, *zi; |
1525 | | |
1526 | 789 | WORD32 *a, *scale; |
1527 | 789 | WORD32 gain = 0; |
1528 | 789 | WORD32 *wp; |
1529 | 789 | WORD64 temp_prod = 0; |
1530 | | |
1531 | 789 | wf = scratch; |
1532 | 789 | wt = wf + IXHEAAC_GET_SIZE_ALIGNED_TYPE(MAX_TIMESLOTSX2, sizeof(*wt), BYTE_ALIGN_8); |
1533 | 789 | v1 = wt + IXHEAAC_GET_SIZE_ALIGNED_TYPE(MAX_TIMESLOTSX2, sizeof(*v1), BYTE_ALIGN_8); |
1534 | 789 | v2 = v1 + IXHEAAC_GET_SIZE_ALIGNED_TYPE(MDCT_LENGTH_HI, sizeof(*v2), BYTE_ALIGN_8); |
1535 | 789 | twipost_real = |
1536 | 789 | v2 + IXHEAAC_GET_SIZE_ALIGNED_TYPE(MDCT_LENGTH_HI, sizeof(*twipost_real), BYTE_ALIGN_8); |
1537 | 789 | twipost_imag = twipost_real + IXHEAAC_GET_SIZE_ALIGNED_TYPE( |
1538 | 789 | MAX_NUM_QMF_BANDS, sizeof(*twipost_imag), BYTE_ALIGN_8); |
1539 | 789 | mdct_sf = twipost_imag + |
1540 | 789 | IXHEAAC_GET_SIZE_ALIGNED_TYPE(MAX_NUM_QMF_BANDS, sizeof(*mdct_sf), BYTE_ALIGN_8); |
1541 | 789 | z1_real = |
1542 | 789 | mdct_sf + IXHEAAC_GET_SIZE_ALIGNED_TYPE(MDCT_LENGTH_SF, sizeof(*z1_real), BYTE_ALIGN_8); |
1543 | 789 | z1_imag = z1_real + IXHEAAC_GET_SIZE_ALIGNED_TYPE(QBXTSX2, sizeof(*z1_imag), BYTE_ALIGN_8); |
1544 | 789 | a = z1_imag + IXHEAAC_GET_SIZE_ALIGNED_TYPE(QBXTSX2, sizeof(*a), BYTE_ALIGN_8); |
1545 | 789 | free_scratch = (VOID *)((WORD32 *)a + IXHEAAC_GET_SIZE_ALIGNED_TYPE(MAX_NUM_QMF_BANDS, |
1546 | 789 | sizeof(*a), BYTE_ALIGN_8)); |
1547 | | |
1548 | 789 | scale = a; |
1549 | | |
1550 | 789 | ixheaacd_local_mdct_win(upd_qmf, window_type, wf, wf_tab, wt, |
1551 | 789 | ia_mps_dec_mps_table_ptr->mdct2qmf_table_ptr); |
1552 | | |
1553 | 789 | switch (window_type) { |
1554 | 385 | case ONLY_LONG_SEQUENCE: |
1555 | 505 | case LONG_START_SEQUENCE: |
1556 | 555 | case LONG_STOP_SEQUENCE: |
1557 | | |
1558 | 555 | n = upd_qmf * qmf_bands - MDCT_LENGTH_LO; |
1559 | | |
1560 | 555 | if (n > 0) { |
1561 | 327 | ixheaacd_local_zero(n, &mdct_in[MDCT_LENGTH_LO]); |
1562 | 327 | } |
1563 | 555 | mdct_length += n; |
1564 | | |
1565 | 555 | ixheaacd_local_fold_out(mdct_in, mdct_length, wf, l, v1, v2); |
1566 | | |
1567 | 555 | wp = wt; |
1568 | | |
1569 | 555 | ixheaacd_get_gain(l, &gain); |
1570 | | |
1571 | 24.4k | for (k = 0; k < l; k++) { |
1572 | 23.9k | *scale++ = ixheaacd_mps_mult32_shr_15(gain, *wp); |
1573 | 23.9k | wp++; |
1574 | 23.9k | } |
1575 | 555 | ixheaacd_local_hybcmdct2qmf(v1, v2, a, l, z1_real, z1_imag, |
1576 | 555 | ia_mps_dec_mps_table_ptr->mdct2qmfcos_tab_ptr, free_scratch, 1); |
1577 | | |
1578 | 555 | ptr1 = ia_mps_dec_mps_table_ptr->mdct2qmf_table_ptr->twi_post_cos; |
1579 | 555 | ptr2 = ia_mps_dec_mps_table_ptr->mdct2qmf_table_ptr->twi_post_sin; |
1580 | | |
1581 | 555 | if (qmf_global_offset < time_slots) { |
1582 | 555 | if (qmf_global_offset + l < time_slots) { |
1583 | 0 | for (i = 0; i < qmf_bands; i++) { |
1584 | 0 | WORD32 cos_twi = *ptr1++; |
1585 | 0 | WORD32 sin_twi = *ptr2++; |
1586 | 0 | for (j = 0; j < l; j++) { |
1587 | 0 | temp3 = *z1_real++; |
1588 | 0 | temp4 = *z1_imag++; |
1589 | |
|
1590 | 0 | temp_2 = j + qmf_global_offset; |
1591 | 0 | temp_prod = (WORD64)(p_qmf_real_pre[temp_2]); |
1592 | 0 | temp_prod = ixheaac_mac32x32in64(temp_prod, cos_twi, temp3); |
1593 | 0 | temp_prod = ixheaac_mac32x32in64(temp_prod, -sin_twi, temp4); |
1594 | 0 | p_qmf_real_pre[temp_2] = ixheaac_sat64_32(temp_prod); |
1595 | 0 | temp_prod = (WORD64)(p_qmf_imag_pre[temp_2]); |
1596 | 0 | temp_prod = ixheaac_mac32x32in64(temp_prod, cos_twi, temp4); |
1597 | 0 | temp_prod = ixheaac_mac32x32in64(temp_prod, sin_twi, temp3); |
1598 | 0 | p_qmf_imag_pre[temp_2] = ixheaac_sat64_32(temp_prod); |
1599 | 0 | } |
1600 | 0 | p_qmf_real_pre += MAX_TIME_SLOTS; |
1601 | 0 | p_qmf_imag_pre += MAX_TIME_SLOTS; |
1602 | 0 | } |
1603 | 555 | } else { |
1604 | 36.0k | for (i = 0; i < qmf_bands; i++) { |
1605 | 35.5k | WORD32 cos_twi = *ptr1++; |
1606 | 35.5k | WORD32 sin_twi = *ptr2++; |
1607 | 1.56M | for (j = 0; j < l; j++) { |
1608 | 1.53M | temp3 = *z1_real++; |
1609 | 1.53M | temp4 = *z1_imag++; |
1610 | | |
1611 | 1.53M | temp_2 = j + qmf_global_offset; |
1612 | 1.53M | if (temp_2 < time_slots) { |
1613 | 800k | temp_prod = (WORD64)(p_qmf_real_pre[temp_2]); |
1614 | 800k | temp_prod = ixheaac_mac32x32in64(temp_prod, cos_twi, temp3); |
1615 | 800k | temp_prod = ixheaac_mac32x32in64(temp_prod, -sin_twi, temp4); |
1616 | 800k | p_qmf_real_pre[temp_2] = ixheaac_sat64_32(temp_prod); |
1617 | 800k | temp_prod = (WORD64)(p_qmf_imag_pre[temp_2]); |
1618 | 800k | temp_prod = ixheaac_mac32x32in64(temp_prod, cos_twi, temp4); |
1619 | 800k | temp_prod = ixheaac_mac32x32in64(temp_prod, sin_twi, temp3); |
1620 | 800k | p_qmf_imag_pre[temp_2] = ixheaac_sat64_32(temp_prod); |
1621 | 800k | } else { |
1622 | 731k | temp_prod = (WORD64)(p_qmf_real_post[temp_2 - time_slots]); |
1623 | 731k | temp_prod = ixheaac_mac32x32in64(temp_prod, cos_twi, temp3); |
1624 | 731k | temp_prod = ixheaac_mac32x32in64(temp_prod, -sin_twi, temp4); |
1625 | 731k | p_qmf_real_post[temp_2 - time_slots] = ixheaac_sat64_32(temp_prod); |
1626 | 731k | temp_prod = (WORD64)(p_qmf_imag_post[temp_2 - time_slots]); |
1627 | 731k | temp_prod = ixheaac_mac32x32in64(temp_prod, cos_twi, temp4); |
1628 | 731k | temp_prod = ixheaac_mac32x32in64(temp_prod, sin_twi, temp3); |
1629 | 731k | p_qmf_imag_post[temp_2 - time_slots] = ixheaac_sat64_32(temp_prod); |
1630 | 731k | } |
1631 | 1.53M | } |
1632 | 35.5k | p_qmf_real_pre += MAX_TIME_SLOTS; |
1633 | 35.5k | p_qmf_real_post += MAX_TIME_SLOTS; |
1634 | | |
1635 | 35.5k | p_qmf_imag_pre += MAX_TIME_SLOTS; |
1636 | 35.5k | p_qmf_imag_post += MAX_TIME_SLOTS; |
1637 | 35.5k | } |
1638 | 555 | } |
1639 | 555 | } else { |
1640 | 0 | for (i = 0; i < qmf_bands; i++) { |
1641 | 0 | WORD32 cos_twi = *ptr1++; |
1642 | 0 | WORD32 sin_twi = *ptr2++; |
1643 | 0 | for (j = 0; j < l; j++) { |
1644 | 0 | temp3 = *z1_real++; |
1645 | 0 | temp4 = *z1_imag++; |
1646 | |
|
1647 | 0 | temp_2 = j + qmf_global_offset; |
1648 | |
|
1649 | 0 | temp_prod = (WORD64)(p_qmf_real_post[temp_2 - time_slots]); |
1650 | 0 | temp_prod = ixheaac_mac32x32in64(temp_prod, cos_twi, temp3); |
1651 | 0 | temp_prod = ixheaac_mac32x32in64(temp_prod, -sin_twi, temp4); |
1652 | 0 | p_qmf_real_post[temp_2 - time_slots] = ixheaac_sat64_32(temp_prod); |
1653 | 0 | temp_prod = (WORD64)(p_qmf_imag_post[temp_2 - time_slots]); |
1654 | 0 | temp_prod = ixheaac_mac32x32in64(temp_prod, cos_twi, temp4); |
1655 | 0 | temp_prod = ixheaac_mac32x32in64(temp_prod, sin_twi, temp3); |
1656 | 0 | p_qmf_imag_post[temp_2 - time_slots] = ixheaac_sat64_32(temp_prod); |
1657 | 0 | } |
1658 | 0 | p_qmf_real_post += MAX_TIME_SLOTS; |
1659 | 0 | p_qmf_imag_post += MAX_TIME_SLOTS; |
1660 | 0 | } |
1661 | 0 | } |
1662 | 555 | break; |
1663 | 234 | case EIGHT_SHORT_SEQUENCE: |
1664 | | |
1665 | 234 | switch (upd_qmf) { |
1666 | 0 | case UPD_QMF_15: |
1667 | 0 | l = 4; |
1668 | 0 | mdct_length = AAC_SHORT_FRAME_LENGTH; |
1669 | 0 | qmf_offset = 6; |
1670 | 0 | qmf_shift = 2; |
1671 | 0 | n_windows = 7; |
1672 | 0 | break; |
1673 | 87 | case UPD_QMF_16: |
1674 | 207 | case UPD_QMF_32: |
1675 | 207 | n = (upd_qmf - UPD_QMF_16) * 8; |
1676 | 207 | mdct_length = AAC_SHORT_FRAME_LENGTH + n; |
1677 | 207 | l = 2 * (upd_qmf >> 3); |
1678 | 207 | qmf_offset = 7 * upd_qmf >> 4; |
1679 | 207 | qmf_shift = upd_qmf >> 3; |
1680 | 207 | n_windows = 8; |
1681 | 207 | break; |
1682 | 7 | case UPD_QMF_18: |
1683 | 7 | l = 4; |
1684 | 7 | mdct_length = AAC_SHORT_FRAME_LENGTH; |
1685 | 7 | qmf_offset = 8; |
1686 | 7 | qmf_shift = 2; |
1687 | 7 | n_windows = 9; |
1688 | 7 | break; |
1689 | 20 | case UPD_QMF_24: |
1690 | 20 | l = 4; |
1691 | 20 | mdct_length = AAC_SHORT_FRAME_LENGTH; |
1692 | 20 | qmf_offset = 11; |
1693 | 20 | qmf_shift = 2; |
1694 | 20 | n_windows = 12; |
1695 | 20 | break; |
1696 | 0 | case UPD_QMF_30: |
1697 | 0 | l = 4; |
1698 | 0 | mdct_length = AAC_SHORT_FRAME_LENGTH; |
1699 | 0 | qmf_offset = 14; |
1700 | 0 | qmf_shift = 2; |
1701 | 0 | n_windows = 15; |
1702 | 0 | break; |
1703 | 0 | default: |
1704 | 0 | l = 4; |
1705 | 0 | mdct_length = AAC_SHORT_FRAME_LENGTH; |
1706 | 0 | qmf_offset = 6; |
1707 | 0 | qmf_shift = 2; |
1708 | 0 | n_windows = 7; |
1709 | 0 | break; |
1710 | 234 | } |
1711 | | |
1712 | 234 | wp = wt; |
1713 | 234 | ixheaacd_get_gain(l, &gain); |
1714 | | |
1715 | 1.65k | for (k = 0; k < l; k++) { |
1716 | 1.41k | *scale++ = ixheaacd_mps_mult32_shr_15(gain, *wp); |
1717 | 1.41k | wp++; |
1718 | 1.41k | } |
1719 | | |
1720 | 2.19k | for (k = 0; k < n_windows; k++) { |
1721 | 1.95k | is_long = 0; |
1722 | 1.95k | mdct_sf_ptr = mdct_sf; |
1723 | 1.95k | switch (upd_qmf) { |
1724 | 696 | case UPD_QMF_16: |
1725 | 1.65k | case UPD_QMF_32: |
1726 | 1.65k | mdct_p = mdct_in + mdct_offset; |
1727 | 213k | for (i = 0; i < AAC_SHORT_FRAME_LENGTH; i++) { |
1728 | 211k | *mdct_sf_ptr++ = *mdct_p++; |
1729 | 211k | } |
1730 | | |
1731 | 1.65k | ixheaacd_local_zero(n, &mdct_sf[AAC_SHORT_FRAME_LENGTH]); |
1732 | 1.65k | break; |
1733 | 0 | case UPD_QMF_15: |
1734 | 0 | if (k < n_windows - 1) { |
1735 | 0 | mdct_p = mdct_in + mdct_offset; |
1736 | 0 | for (i = 0; i < AAC_SHORT_FRAME_LENGTH; i++) { |
1737 | 0 | *mdct_sf_ptr++ = *mdct_p++; |
1738 | 0 | } |
1739 | 0 | } else { |
1740 | 0 | window_offset = l; |
1741 | 0 | l = 6; |
1742 | 0 | mdct_length = 192; |
1743 | 0 | is_long = 4; |
1744 | 0 | gain = 13377; |
1745 | 0 | scale = a; |
1746 | 0 | wp = wt + window_offset; |
1747 | |
|
1748 | 0 | for (k = 0; k < l; k++) { |
1749 | 0 | *scale++ = ixheaacd_mps_mult32_shr_15(gain, *wp); |
1750 | 0 | wp++; |
1751 | 0 | } |
1752 | |
|
1753 | 0 | mdct_p = mdct_in + mdct_offset; |
1754 | 0 | mdct_p2 = mdct_in + mdct_offset + AAC_SHORT_FRAME_LENGTH; |
1755 | |
|
1756 | 0 | for (i = 0, j = 0; i < mdct_length / 2; i++) { |
1757 | 0 | *mdct_sf_ptr++ = *mdct_p++; |
1758 | 0 | *mdct_sf_ptr++ = *mdct_p2++; |
1759 | 0 | } |
1760 | 0 | } |
1761 | 0 | break; |
1762 | 63 | case UPD_QMF_18: |
1763 | 303 | case UPD_QMF_24: |
1764 | 303 | case UPD_QMF_30: |
1765 | | |
1766 | 303 | mdct_p = mdct_in + mdct_offset; |
1767 | 39.0k | for (i = 0; i < AAC_SHORT_FRAME_LENGTH; i++) { |
1768 | 38.7k | *mdct_sf_ptr++ = *mdct_p++; |
1769 | 38.7k | } |
1770 | 303 | break; |
1771 | 0 | default: |
1772 | 0 | break; |
1773 | 1.95k | } |
1774 | 1.95k | ixheaacd_local_fold_out(mdct_sf, mdct_length, &wf[window_offset], l, v1, v2); |
1775 | | |
1776 | 1.95k | ixheaacd_local_hybcmdct2qmf(v1, v2, a, l, z1_real, z1_imag, |
1777 | 1.95k | ia_mps_dec_mps_table_ptr->mdct2qmfcos_tab_ptr, free_scratch, |
1778 | 1.95k | is_long); |
1779 | | |
1780 | 1.95k | zr = z1_real; |
1781 | 1.95k | zi = z1_imag; |
1782 | | |
1783 | 1.95k | ptr1 = ia_mps_dec_mps_table_ptr->mdct2qmf_table_ptr->twi_post_cos; |
1784 | 1.95k | ptr2 = ia_mps_dec_mps_table_ptr->mdct2qmf_table_ptr->twi_post_sin; |
1785 | 1.95k | temp_2 = qmf_offset + qmf_global_offset; |
1786 | | |
1787 | 1.95k | if (temp_2 < time_slots) { |
1788 | 1.21k | if ((temp_2 + l) < time_slots) { |
1789 | 748 | p_qmf_real_pre = qmf_real_pre; |
1790 | 748 | p_qmf_imag_pre = qmf_imag_pre; |
1791 | | |
1792 | 48.6k | for (i = 0; i < qmf_bands; i++) { |
1793 | 47.8k | WORD32 cos_twi = *ptr1++; |
1794 | 47.8k | WORD32 sin_twi = *ptr2++; |
1795 | | |
1796 | 331k | for (j = 0; j < l; j++) { |
1797 | 283k | temp3 = *zr++; |
1798 | 283k | temp4 = (*zi++); |
1799 | | |
1800 | 283k | temp_prod = (WORD64)(p_qmf_real_pre[temp_2 + j]); |
1801 | 283k | temp_prod = ixheaac_mac32x32in64(temp_prod, cos_twi, temp3); |
1802 | 283k | temp_prod = ixheaac_mac32x32in64(temp_prod, -sin_twi, temp4); |
1803 | 283k | p_qmf_real_pre[temp_2 + j] = ixheaac_sat64_32(temp_prod); |
1804 | 283k | temp_prod = (WORD64)(p_qmf_imag_pre[temp_2 + j]); |
1805 | 283k | temp_prod = ixheaac_mac32x32in64(temp_prod, cos_twi, temp4); |
1806 | 283k | temp_prod = ixheaac_mac32x32in64(temp_prod, sin_twi, temp3); |
1807 | 283k | p_qmf_imag_pre[temp_2 + j] = ixheaac_sat64_32(temp_prod); |
1808 | 283k | } |
1809 | 47.8k | p_qmf_real_pre += MAX_TIME_SLOTS; |
1810 | 47.8k | p_qmf_imag_pre += MAX_TIME_SLOTS; |
1811 | 47.8k | } |
1812 | 748 | } else { |
1813 | 466 | p_qmf_real_pre = qmf_real_pre; |
1814 | 466 | p_qmf_real_post = qmf_real_post; |
1815 | 466 | p_qmf_imag_pre = qmf_imag_pre; |
1816 | 466 | p_qmf_imag_post = qmf_imag_post; |
1817 | | |
1818 | 30.2k | for (i = 0; i < qmf_bands; i++) { |
1819 | 29.8k | WORD32 cos_twi = *ptr1++; |
1820 | 29.8k | WORD32 sin_twi = *ptr2++; |
1821 | | |
1822 | 210k | for (j = 0; j < l; j++) { |
1823 | 180k | temp3 = *zr++; |
1824 | 180k | temp4 = (*zi++); |
1825 | | |
1826 | 180k | if ((temp_2 + j) < time_slots) { |
1827 | 91.1k | temp_prod = (WORD64)(p_qmf_real_pre[temp_2 + j]); |
1828 | 91.1k | temp_prod = ixheaac_mac32x32in64(temp_prod, cos_twi, temp3); |
1829 | 91.1k | temp_prod = ixheaac_mac32x32in64(temp_prod, -sin_twi, temp4); |
1830 | 91.1k | p_qmf_real_pre[temp_2 + j] = ixheaac_sat64_32(temp_prod); |
1831 | 91.1k | temp_prod = (WORD64)(p_qmf_imag_pre[temp_2 + j]); |
1832 | 91.1k | temp_prod = ixheaac_mac32x32in64(temp_prod, cos_twi, temp4); |
1833 | 91.1k | temp_prod = ixheaac_mac32x32in64(temp_prod, sin_twi, temp3); |
1834 | 91.1k | p_qmf_imag_pre[temp_2 + j] = ixheaac_sat64_32(temp_prod); |
1835 | 91.1k | } else { |
1836 | 89.6k | temp_prod = (WORD64)(p_qmf_real_post[temp_2 + j - time_slots]); |
1837 | 89.6k | temp_prod = ixheaac_mac32x32in64(temp_prod, cos_twi, temp3); |
1838 | 89.6k | temp_prod = ixheaac_mac32x32in64(temp_prod, -sin_twi, temp4); |
1839 | 89.6k | p_qmf_real_post[temp_2 + j - time_slots] = ixheaac_sat64_32(temp_prod); |
1840 | 89.6k | temp_prod = (WORD64)(p_qmf_imag_post[temp_2 + j - time_slots]); |
1841 | 89.6k | temp_prod = ixheaac_mac32x32in64(temp_prod, cos_twi, temp4); |
1842 | 89.6k | temp_prod = ixheaac_mac32x32in64(temp_prod, sin_twi, temp3); |
1843 | 89.6k | p_qmf_imag_post[temp_2 + j - time_slots] = ixheaac_sat64_32(temp_prod); |
1844 | 89.6k | } |
1845 | 180k | } |
1846 | 29.8k | p_qmf_real_pre += MAX_TIME_SLOTS; |
1847 | 29.8k | p_qmf_imag_pre += MAX_TIME_SLOTS; |
1848 | | |
1849 | 29.8k | p_qmf_real_post += MAX_TIME_SLOTS; |
1850 | 29.8k | p_qmf_imag_post += MAX_TIME_SLOTS; |
1851 | 29.8k | } |
1852 | 466 | } |
1853 | 1.21k | } else { |
1854 | 745 | p_qmf_real_post = qmf_real_post; |
1855 | 745 | p_qmf_imag_post = qmf_imag_post; |
1856 | | |
1857 | 48.4k | for (i = 0; i < qmf_bands; i++) { |
1858 | 47.6k | WORD32 cos_twi = *ptr1++; |
1859 | 47.6k | WORD32 sin_twi = *ptr2++; |
1860 | | |
1861 | 330k | for (j = 0; j < l; j++) { |
1862 | 282k | temp3 = *zr++; |
1863 | 282k | temp4 = (*zi++); |
1864 | 282k | { |
1865 | 282k | temp_prod = (WORD64)(p_qmf_real_post[temp_2 + j - time_slots]); |
1866 | 282k | temp_prod = ixheaac_mac32x32in64(temp_prod, cos_twi, temp3); |
1867 | 282k | temp_prod = ixheaac_mac32x32in64(temp_prod, -sin_twi, temp4); |
1868 | 282k | p_qmf_real_post[temp_2 + j - time_slots] = ixheaac_sat64_32(temp_prod); |
1869 | 282k | temp_prod = (WORD64)(p_qmf_imag_post[temp_2 + j - time_slots]); |
1870 | 282k | temp_prod = ixheaac_mac32x32in64(temp_prod, cos_twi, temp4); |
1871 | 282k | temp_prod = ixheaac_mac32x32in64(temp_prod, sin_twi, temp3); |
1872 | 282k | p_qmf_imag_post[temp_2 + j - time_slots] = ixheaac_sat64_32(temp_prod); |
1873 | 282k | } |
1874 | 282k | } |
1875 | 47.6k | p_qmf_real_post += MAX_TIME_SLOTS; |
1876 | 47.6k | p_qmf_imag_post += MAX_TIME_SLOTS; |
1877 | 47.6k | } |
1878 | 745 | } |
1879 | | |
1880 | 1.95k | mdct_offset += mdct_shift; |
1881 | 1.95k | qmf_offset += qmf_shift; |
1882 | 1.95k | } |
1883 | 234 | break; |
1884 | 234 | default: |
1885 | 0 | break; |
1886 | 789 | } |
1887 | 789 | return; |
1888 | 789 | } |