annotate src/aac/libfaad2/structs.h @ 2611:e99d3e8653df

Remove the strange timeout function from ALSA plugin's mixer handling, this fixes problems with volume and balance setting in some cases where timeout caused pcm_element to become NULL prematurely. Not sure if there could be any adverse side-effects to this, though...
author Matti Hamalainen <ccr@tnsp.org>
date Wed, 21 May 2008 16:43:48 +0300
parents 22a470857579
children f1b6f1b2cdb3
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
1 /*
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
2 ** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding
691
e6c5fdae6e88 [svn] - oh yes, commit mplayer patches as well
nenolod
parents: 681
diff changeset
3 ** Copyright (C) 2003-2004 M. Bakker, Ahead Software AG, http://www.nero.com
e6c5fdae6e88 [svn] - oh yes, commit mplayer patches as well
nenolod
parents: 681
diff changeset
4 **
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
5 ** This program is free software; you can redistribute it and/or modify
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
6 ** it under the terms of the GNU General Public License as published by
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
7 ** the Free Software Foundation; either version 2 of the License, or
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
8 ** (at your option) any later version.
691
e6c5fdae6e88 [svn] - oh yes, commit mplayer patches as well
nenolod
parents: 681
diff changeset
9 **
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
10 ** This program is distributed in the hope that it will be useful,
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
11 ** but WITHOUT ANY WARRANTY; without even the implied warranty of
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
12 ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
13 ** GNU General Public License for more details.
691
e6c5fdae6e88 [svn] - oh yes, commit mplayer patches as well
nenolod
parents: 681
diff changeset
14 **
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
15 ** You should have received a copy of the GNU General Public License
691
e6c5fdae6e88 [svn] - oh yes, commit mplayer patches as well
nenolod
parents: 681
diff changeset
16 ** along with this program; if not, write to the Free Software
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
17 ** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
18 **
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
19 ** Any non-GPL usage of this software or parts of this software is strictly
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
20 ** forbidden.
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
21 **
691
e6c5fdae6e88 [svn] - oh yes, commit mplayer patches as well
nenolod
parents: 681
diff changeset
22 ** Commercial non-GPL licensing of this software is possible.
e6c5fdae6e88 [svn] - oh yes, commit mplayer patches as well
nenolod
parents: 681
diff changeset
23 ** For more info contact Ahead Software through Mpeg4AAClicense@nero.com.
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
24 **
691
e6c5fdae6e88 [svn] - oh yes, commit mplayer patches as well
nenolod
parents: 681
diff changeset
25 ** $Id: structs.h,v 1.42 2004/09/08 09:43:11 gcp Exp $
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
26 **/
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
27
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
28 #ifndef __STRUCTS_H__
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
29 #define __STRUCTS_H__
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
30
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
31 #ifdef __cplusplus
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
32 extern "C" {
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
33 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
34
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
35 #include "cfft.h"
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
36 #ifdef SBR_DEC
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
37 #include "sbr_dec.h"
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
38 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
39
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
40 #define MAX_CHANNELS 64
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
41 #define MAX_SYNTAX_ELEMENTS 48
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
42 #define MAX_WINDOW_GROUPS 8
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
43 #define MAX_SFB 51
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
44 #define MAX_LTP_SFB 40
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
45 #define MAX_LTP_SFB_S 8
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
46
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
47 /* used to save the prediction state */
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
48 typedef struct {
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
49 int16_t r[2];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
50 int16_t COR[2];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
51 int16_t VAR[2];
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
52 } pred_state;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
53
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
54 typedef struct {
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
55 uint16_t N;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
56 cfft_info *cfft;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
57 complex_t *sincos;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
58 #ifdef PROFILE
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
59 int64_t cycles;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
60 int64_t fft_cycles;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
61 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
62 } mdct_info;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
63
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
64 typedef struct
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
65 {
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
66 const real_t *long_window[2];
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
67 const real_t *short_window[2];
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
68 #ifdef LD_DEC
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
69 const real_t *ld_window[2];
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
70 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
71
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
72 mdct_info *mdct256;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
73 #ifdef LD_DEC
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
74 mdct_info *mdct1024;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
75 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
76 mdct_info *mdct2048;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
77 #ifdef PROFILE
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
78 int64_t cycles;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
79 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
80 } fb_info;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
81
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
82 typedef struct
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
83 {
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
84 uint8_t present;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
85
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
86 uint8_t num_bands;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
87 uint8_t pce_instance_tag;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
88 uint8_t excluded_chns_present;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
89 uint8_t band_top[17];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
90 uint8_t prog_ref_level;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
91 uint8_t dyn_rng_sgn[17];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
92 uint8_t dyn_rng_ctl[17];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
93 uint8_t exclude_mask[MAX_CHANNELS];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
94 uint8_t additional_excluded_chns[MAX_CHANNELS];
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
95
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
96 real_t ctrl1;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
97 real_t ctrl2;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
98 } drc_info;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
99
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
100 typedef struct
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
101 {
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
102 uint8_t element_instance_tag;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
103 uint8_t object_type;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
104 uint8_t sf_index;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
105 uint8_t num_front_channel_elements;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
106 uint8_t num_side_channel_elements;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
107 uint8_t num_back_channel_elements;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
108 uint8_t num_lfe_channel_elements;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
109 uint8_t num_assoc_data_elements;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
110 uint8_t num_valid_cc_elements;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
111 uint8_t mono_mixdown_present;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
112 uint8_t mono_mixdown_element_number;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
113 uint8_t stereo_mixdown_present;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
114 uint8_t stereo_mixdown_element_number;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
115 uint8_t matrix_mixdown_idx_present;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
116 uint8_t pseudo_surround_enable;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
117 uint8_t matrix_mixdown_idx;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
118 uint8_t front_element_is_cpe[16];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
119 uint8_t front_element_tag_select[16];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
120 uint8_t side_element_is_cpe[16];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
121 uint8_t side_element_tag_select[16];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
122 uint8_t back_element_is_cpe[16];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
123 uint8_t back_element_tag_select[16];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
124 uint8_t lfe_element_tag_select[16];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
125 uint8_t assoc_data_element_tag_select[16];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
126 uint8_t cc_element_is_ind_sw[16];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
127 uint8_t valid_cc_element_tag_select[16];
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
128
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
129 uint8_t channels;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
130
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
131 uint8_t comment_field_bytes;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
132 uint8_t comment_field_data[257];
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
133
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
134 /* extra added values */
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
135 uint8_t num_front_channels;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
136 uint8_t num_side_channels;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
137 uint8_t num_back_channels;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
138 uint8_t num_lfe_channels;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
139 uint8_t sce_channel[16];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
140 uint8_t cpe_channel[16];
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
141 } program_config;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
142
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
143 typedef struct
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
144 {
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
145 uint16_t syncword;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
146 uint8_t id;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
147 uint8_t layer;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
148 uint8_t protection_absent;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
149 uint8_t profile;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
150 uint8_t sf_index;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
151 uint8_t private_bit;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
152 uint8_t channel_configuration;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
153 uint8_t original;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
154 uint8_t home;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
155 uint8_t emphasis;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
156 uint8_t copyright_identification_bit;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
157 uint8_t copyright_identification_start;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
158 uint16_t aac_frame_length;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
159 uint16_t adts_buffer_fullness;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
160 uint8_t no_raw_data_blocks_in_frame;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
161 uint16_t crc_check;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
162
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
163 /* control param */
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
164 uint8_t old_format;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
165 } adts_header;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
166
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
167 typedef struct
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
168 {
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
169 uint8_t copyright_id_present;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
170 int8_t copyright_id[10];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
171 uint8_t original_copy;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
172 uint8_t home;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
173 uint8_t bitstream_type;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
174 uint32_t bitrate;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
175 uint8_t num_program_config_elements;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
176 uint32_t adif_buffer_fullness;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
177
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
178 /* maximum of 16 PCEs */
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
179 program_config pce[16];
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
180 } adif_header;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
181
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
182 #ifdef LTP_DEC
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
183 typedef struct
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
184 {
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
185 uint8_t last_band;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
186 uint8_t data_present;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
187 uint16_t lag;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
188 uint8_t lag_update;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
189 uint8_t coef;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
190 uint8_t long_used[MAX_SFB];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
191 uint8_t short_used[8];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
192 uint8_t short_lag_present[8];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
193 uint8_t short_lag[8];
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
194 } ltp_info;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
195 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
196
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
197 #ifdef MAIN_DEC
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
198 typedef struct
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
199 {
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
200 uint8_t limit;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
201 uint8_t predictor_reset;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
202 uint8_t predictor_reset_group_number;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
203 uint8_t prediction_used[MAX_SFB];
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
204 } pred_info;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
205 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
206
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
207 typedef struct
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
208 {
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
209 uint8_t number_pulse;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
210 uint8_t pulse_start_sfb;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
211 uint8_t pulse_offset[4];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
212 uint8_t pulse_amp[4];
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
213 } pulse_info;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
214
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
215 typedef struct
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
216 {
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
217 uint8_t n_filt[8];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
218 uint8_t coef_res[8];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
219 uint8_t length[8][4];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
220 uint8_t order[8][4];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
221 uint8_t direction[8][4];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
222 uint8_t coef_compress[8][4];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
223 uint8_t coef[8][4][32];
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
224 } tns_info;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
225
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
226 #ifdef SSR_DEC
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
227 typedef struct
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
228 {
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
229 uint8_t max_band;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
230
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
231 uint8_t adjust_num[4][8];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
232 uint8_t alevcode[4][8][8];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
233 uint8_t aloccode[4][8][8];
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
234 } ssr_info;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
235 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
236
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
237 typedef struct
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
238 {
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
239 uint8_t max_sfb;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
240
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
241 uint8_t num_swb;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
242 uint8_t num_window_groups;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
243 uint8_t num_windows;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
244 uint8_t window_sequence;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
245 uint8_t window_group_length[8];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
246 uint8_t window_shape;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
247 uint8_t scale_factor_grouping;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
248 uint16_t sect_sfb_offset[8][15*8];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
249 uint16_t swb_offset[52];
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
250
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
251 uint8_t sect_cb[8][15*8];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
252 uint16_t sect_start[8][15*8];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
253 uint16_t sect_end[8][15*8];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
254 uint8_t sfb_cb[8][8*15];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
255 uint8_t num_sec[8]; /* number of sections in a group */
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
256
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
257 uint8_t global_gain;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
258 int16_t scale_factors[8][51]; /* [0..255] */
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
259
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
260 uint8_t ms_mask_present;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
261 uint8_t ms_used[MAX_WINDOW_GROUPS][MAX_SFB];
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
262
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
263 uint8_t noise_used;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
264
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
265 uint8_t pulse_data_present;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
266 uint8_t tns_data_present;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
267 uint8_t gain_control_data_present;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
268 uint8_t predictor_data_present;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
269
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
270 pulse_info pul;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
271 tns_info tns;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
272 #ifdef MAIN_DEC
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
273 pred_info pred;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
274 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
275 #ifdef LTP_DEC
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
276 ltp_info ltp;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
277 ltp_info ltp2;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
278 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
279 #ifdef SSR_DEC
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
280 ssr_info ssr;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
281 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
282
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
283 #ifdef ERROR_RESILIENCE
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
284 /* ER HCR data */
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
285 uint16_t length_of_reordered_spectral_data;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
286 uint8_t length_of_longest_codeword;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
287 /* ER RLVC data */
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
288 uint8_t sf_concealment;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
289 uint8_t rev_global_gain;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
290 uint16_t length_of_rvlc_sf;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
291 uint16_t dpcm_noise_nrg;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
292 uint8_t sf_escapes_present;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
293 uint8_t length_of_rvlc_escapes;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
294 uint16_t dpcm_noise_last_position;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
295 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
296 } ic_stream; /* individual channel stream */
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
297
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
298 typedef struct
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
299 {
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
300 uint8_t channel;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
301 int16_t paired_channel;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
302
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
303 uint8_t element_instance_tag;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
304 uint8_t common_window;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
305
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
306 ic_stream ics1;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
307 ic_stream ics2;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
308 } element; /* syntax element (SCE, CPE, LFE) */
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
309
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
310 typedef struct mp4AudioSpecificConfig
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
311 {
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
312 /* Audio Specific Info */
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
313 /*uint8_t*/ unsigned char objectTypeIndex;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
314 /*uint8_t*/ unsigned char samplingFrequencyIndex;
1188
22a470857579 - fix the bug that aac plugin had failed to get proper playtime length on AMD64.
Yoshiki Yazawa <yaz@cc.rim.or.jp>
parents: 691
diff changeset
315 /*uint32_t*/ unsigned int samplingFrequency;
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
316 /*uint8_t*/ unsigned char channelsConfiguration;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
317
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
318 /* GA Specific Info */
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
319 /*uint8_t*/ unsigned char frameLengthFlag;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
320 /*uint8_t*/ unsigned char dependsOnCoreCoder;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
321 /*uint16_t*/ unsigned short coreCoderDelay;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
322 /*uint8_t*/ unsigned char extensionFlag;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
323 /*uint8_t*/ unsigned char aacSectionDataResilienceFlag;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
324 /*uint8_t*/ unsigned char aacScalefactorDataResilienceFlag;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
325 /*uint8_t*/ unsigned char aacSpectralDataResilienceFlag;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
326 /*uint8_t*/ unsigned char epConfig;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
327
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
328 /*uint8_t*/ char sbr_present_flag;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
329 /*uint8_t*/ char forceUpSampling;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
330 /*uint8_t*/ char downSampledSBR;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
331 } mp4AudioSpecificConfig;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
332
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
333 typedef struct NeAACDecConfiguration
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
334 {
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
335 /*uint8_t*/ unsigned char defObjectType;
1188
22a470857579 - fix the bug that aac plugin had failed to get proper playtime length on AMD64.
Yoshiki Yazawa <yaz@cc.rim.or.jp>
parents: 691
diff changeset
336 /*uint32_t*/ unsigned int defSampleRate;
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
337 /*uint8_t*/ unsigned char outputFormat;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
338 /*uint8_t*/ unsigned char downMatrix;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
339 /*uint8_t*/ unsigned char useOldADTSFormat;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
340 /*uint8_t*/ unsigned char dontUpSampleImplicitSBR;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
341 } NeAACDecConfiguration, *NeAACDecConfigurationPtr;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
342
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
343 typedef struct NeAACDecFrameInfo
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
344 {
1188
22a470857579 - fix the bug that aac plugin had failed to get proper playtime length on AMD64.
Yoshiki Yazawa <yaz@cc.rim.or.jp>
parents: 691
diff changeset
345 /*uint32_t*/ unsigned int bytesconsumed;
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
346 /*uint32_t*/ unsigned long samples;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
347 /*uint8_t*/ unsigned char channels;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
348 /*uint8_t*/ unsigned char error;
1188
22a470857579 - fix the bug that aac plugin had failed to get proper playtime length on AMD64.
Yoshiki Yazawa <yaz@cc.rim.or.jp>
parents: 691
diff changeset
349 /*uint32_t*/ unsigned int samplerate;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
350
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
351 /* SBR: 0: off, 1: on; normal, 2: on; downsampled */
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
352 /*uint8_t*/ unsigned char sbr;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
353
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
354 /* MPEG-4 ObjectType */
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
355 /*uint8_t*/ unsigned char object_type;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
356
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
357 /* AAC header type; MP4 will be signalled as RAW also */
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
358 /*uint8_t*/ unsigned char header_type;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
359
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
360 /* multichannel configuration */
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
361 /*uint8_t*/ unsigned char num_front_channels;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
362 /*uint8_t*/ unsigned char num_side_channels;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
363 /*uint8_t*/ unsigned char num_back_channels;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
364 /*uint8_t*/ unsigned char num_lfe_channels;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
365 /*uint8_t*/ unsigned char channel_position[MAX_CHANNELS];
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
366
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
367 /* PS: 0: off, 1: on */
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
368 /*uint8_t*/ unsigned char ps;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
369 } NeAACDecFrameInfo;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
370
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
371 typedef struct
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
372 {
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
373 uint8_t adts_header_present;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
374 uint8_t adif_header_present;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
375 uint8_t sf_index;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
376 uint8_t object_type;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
377 uint8_t channelConfiguration;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
378 #ifdef ERROR_RESILIENCE
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
379 uint8_t aacSectionDataResilienceFlag;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
380 uint8_t aacScalefactorDataResilienceFlag;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
381 uint8_t aacSpectralDataResilienceFlag;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
382 #endif
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
383 uint16_t frameLength;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
384 uint8_t postSeekResetFlag;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
385
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
386 uint32_t frame;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
387
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
388 uint8_t downMatrix;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
389 uint8_t upMatrix;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
390 uint8_t first_syn_ele;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
391 uint8_t has_lfe;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
392 /* number of channels in current frame */
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
393 uint8_t fr_channels;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
394 /* number of elements in current frame */
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
395 uint8_t fr_ch_ele;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
396
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
397 /* element_output_channels:
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
398 determines the number of channels the element will output
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
399 */
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
400 uint8_t element_output_channels[MAX_SYNTAX_ELEMENTS];
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
401 /* element_alloced:
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
402 determines whether the data needed for the element is allocated or not
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
403 */
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
404 uint8_t element_alloced[MAX_SYNTAX_ELEMENTS];
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
405 /* alloced_channels:
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
406 determines the number of channels where output data is allocated for
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
407 */
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
408 uint8_t alloced_channels;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
409
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
410 /* output data buffer */
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
411 void *sample_buffer;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
412
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
413 uint8_t window_shape_prev[MAX_CHANNELS];
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
414 #ifdef LTP_DEC
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
415 uint16_t ltp_lag[MAX_CHANNELS];
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
416 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
417 fb_info *fb;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
418 drc_info *drc;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
419
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
420 real_t *time_out[MAX_CHANNELS];
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
421 real_t *fb_intermed[MAX_CHANNELS];
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
422
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
423 #ifdef SBR_DEC
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
424 int8_t sbr_present_flag;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
425 int8_t forceUpSampling;
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
426 int8_t downSampledSBR;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
427 /* determines whether SBR data is allocated for the gives element */
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
428 uint8_t sbr_alloced[MAX_SYNTAX_ELEMENTS];
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
429
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
430 sbr_info *sbr[MAX_SYNTAX_ELEMENTS];
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
431 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
432 #if (defined(PS_DEC) || defined(DRM_PS))
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
433 uint8_t ps_used[MAX_SYNTAX_ELEMENTS];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
434 uint8_t ps_used_global;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
435 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
436
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
437 #ifdef SSR_DEC
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
438 real_t *ssr_overlap[MAX_CHANNELS];
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
439 real_t *prev_fmd[MAX_CHANNELS];
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
440 real_t ipqf_buffer[MAX_CHANNELS][4][96/4];
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
441 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
442
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
443 #ifdef MAIN_DEC
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
444 pred_state *pred_stat[MAX_CHANNELS];
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
445 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
446 #ifdef LTP_DEC
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
447 int16_t *lt_pred_stat[MAX_CHANNELS];
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
448 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
449
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
450 /* Program Config Element */
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
451 uint8_t pce_set;
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
452 program_config pce;
681
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
453 uint8_t element_id[MAX_CHANNELS];
1d8b08df98c3 [svn] - synchronise with FAAD 2.5
nenolod
parents: 12
diff changeset
454 uint8_t internal_channel[MAX_CHANNELS];
0
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
455
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
456 /* Configuration data */
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
457 NeAACDecConfiguration config;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
458
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
459 #ifdef PROFILE
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
460 int64_t cycles;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
461 int64_t spectral_cycles;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
462 int64_t output_cycles;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
463 int64_t scalefac_cycles;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
464 int64_t requant_cycles;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
465 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
466 } NeAACDecStruct, *NeAACDecHandle;
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
467
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
468
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
469
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
470 #ifdef __cplusplus
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
471 }
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
472 #endif
13389e613d67 [svn] - initial import of audacious-plugins tree (lots to do)
nenolod
parents:
diff changeset
473 #endif