History

Compact structures definitions.

lieff committed 8 years ago

Commit 08949ff1 parent 572cfae1 file · +12 −38Browse files

Unified · Split

minimp3.h+12−38
@@ -11,21 +11,14 @@ · 10 unmodified lines
1111
1212 typedef struct
1313 {
14− int frame_bytes;
15− int channels;
16− int hz;
17− int layer;
18− int bitrate_kbps;
14+ int frame_bytes, channels, hz, layer, bitrate_kbps;
1915 } mp3dec_frame_info_t;
2016
2117 typedef struct
2218 {
23− float mdct_overlap[2][9*32];
24− float qmf_state[15*2*32];
25− int reserv;
26− int free_format_bytes;
27− unsigned char header[4];
28− unsigned char reserv_buf[511];
19+ float mdct_overlap[2][9*32], qmf_state[15*2*32];
20+ int reserv, free_format_bytes;
21+ unsigned char header[4], reserv_buf[511];
2922 } mp3dec_t;
3023
3124 #ifdef __cplusplus
@@ -193,44 +186,27 @@ static int have_simd() · 161 unmodified lines
193186 typedef struct
194187 {
195188 const uint8_t *buf;
196− int pos;
197− int limit;
189+ int pos, limit;
198190 } bs_t;
199191
200192 typedef struct
201193 {
202− uint8_t total_bands;
203− uint8_t stereo_bands;
204− uint8_t bitalloc[64];
205− uint8_t scfcod[64];
194+ uint8_t total_bands, stereo_bands, bitalloc[64], scfcod[64];
206195 float scf[3*64];
207196 } L12_scale_info;
208197
209198 typedef struct
210199 {
211− uint8_t tab_offset;
212− uint8_t code_tab_width;
213− uint8_t band_count;
200+ uint8_t tab_offset, code_tab_width, band_count;
214201 } L12_subband_alloc_t;
215202
216203 typedef struct
217204 {
218205 const uint8_t *sfbtab;
219− uint16_t part_23_length;
220− uint16_t big_values;
221− uint16_t scalefac_compress;
222− uint8_t global_gain;
223− uint8_t block_type;
224− uint8_t mixed_block_flag;
225− uint8_t n_long_sfb;
226− uint8_t n_short_sfb;
227− uint8_t table_select[3];
228− uint8_t region_count[3];
229− uint8_t subblock_gain[3];
230− uint8_t preflag;
231− uint8_t scalefac_scale;
232− uint8_t count1_table;
233− uint8_t scfsi;
206+ uint16_t part_23_length, big_values, scalefac_compress;
207+ uint8_t global_gain, block_type, mixed_block_flag, n_long_sfb, n_short_sfb;
208+ uint8_t table_select[3], region_count[3], subblock_gain[3];
209+ uint8_t preflag, scalefac_scale, count1_table, scfsi;
234210 } L3_gr_info_t;
235211
236212 typedef struct
@@ -238,10 +214,8 @@ typedef struct · 1 unmodified line
238214 bs_t bs;
239215 uint8_t maindata[MAX_BITRESERVOIR_BYTES + MAX_L3_FRAME_PAYLOAD_BYTES];
240216 L3_gr_info_t gr_info[4];
241− float grbuf[2][576];
242− float scf[40];
217+ float grbuf[2][576], scf[40], syn[18 + 15][2*32];
243218 uint8_t ist_pos[2][39];
244− float syn[18 + 15][2*32];
245219 } mp3dec_scratch_t;
246220
247221 static void bs_init(bs_t *bs, const uint8_t *data, int bytes)

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

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

Repository code

Go to file
t