Go to the documentation of this file.
30 #ifndef AVCODEC_AAC_AACDEC_H
31 #define AVCODEC_AAC_AACDEC_H
72 #define RENAME_FIXED(name) name ## _fixed
74 #define INTFLOAT_UNION(name, elems) \
76 int RENAME_FIXED(name) elems; \
80 #define INTFLOAT_ALIGNED_UNION(alignment, name, nb_elems) \
82 DECLARE_ALIGNED(alignment, int, RENAME_FIXED(name))[nb_elems]; \
83 DECLARE_ALIGNED(alignment, float, name)[nb_elems]; \
338 #if defined(USE_FIXED) && USE_FIXED
339 #define fdsp RENAME_FIXED(fdsp)
enum RawDataBlockType type[8]
Type of channel element to be coupled - SCE or CPE.
CouplingPoint
The point during decoding at which channel coupling is applied.
int(* decode_spectrum_and_dequant)(AACDecContext *ac, GetBitContext *gb, const Pulse *pulse, SingleChannelElement *sce)
struct PredictorState * predictor_state
void(* apply_intensity_stereo)(AACDecContext *ac, ChannelElement *cpe, int ms_present)
const AACDecProc aac_proc_fixed
int8_t used[MAX_LTP_LONG_SFB]
@ OC_TRIAL_PCE
Output configuration under trial specified by an inband PCE.
This structure describes decoded (raw) audio or video data.
ChannelElement * tag_che_map[4][MAX_ELEM_ID]
void(* apply_tns)(void *_coef_param, TemporalNoiseShaping *tns, IndividualChannelStream *ics, int decode)
int warned_remapping_once
void(* apply_prediction)(AACDecContext *ac, SingleChannelElement *sce)
SingleChannelElement ch[2]
int dmono_mode
0->not dmono, 1->use first channel, 2->use second channel
Dynamic Range Control - decoded from the bitstream but not processed further.
int num_swb
number of scalefactor window bands
INTFLOAT_UNION(gain, [16][120])
enum CouplingPoint coupling_point
The point during decoding at which coupling is applied.
float coeffs[1024]
coefficients for IMDCT, maybe processed
int force_dmono_mode
0->not dmono, 1->use first channel, 2->use second channel
int id_select[8]
element id
float ret_buf[2048]
PCM output buffer.
uint8_t window_clipping[8]
set if a certain window is near clipping
it s the only field you need to keep assuming you have a context There is some magic you don t need to care about around this just let it vf type
DynamicRangeControl che_drc
IndividualChannelStream ics
const AACDecDSP aac_dsp_fixed
void(* dequant_scalefactors)(SingleChannelElement *sce)
int exclude_mask[MAX_CHANNELS]
Channels to be excluded from DRC processing.
void(* av_tx_fn)(AVTXContext *s, void *out, void *in, ptrdiff_t stride)
Function pointer to a function to perform the transform.
@ OC_GLOBAL_HDR
Output configuration set in a global header but not yet locked.
float ltp_state[3072]
time signal for LTP
static void decode(AVCodecContext *dec_ctx, AVPacket *pkt, AVFrame *frame, FILE *outfile)
void(* apply_mid_side_stereo)(AACDecContext *ac, ChannelElement *cpe)
int num_coupled
number of target elements
int(* decode_cce)(AACDecContext *ac, GetBitContext *gb, ChannelElement *che)
void(* imdct_and_windowing_ld)(AACDecContext *ac, SingleChannelElement *sce)
Individual Channel Stream.
ChannelElement * che[4][MAX_ELEM_ID]
const AACDecProc aac_proc
int warned_num_aac_frames
int(* init)(AACDecContext *ac)
Describe the class of an AVClass context structure.
uint8_t use_kb_window[2]
If set, use Kaiser-Bessel window, otherwise use a sine window.
uint8_t ms_mask[128]
Set if mid/side stereo is used for each scalefactor window band.
int band_top[17]
Indicates the top of the i-th DRC band in units of 4 spectral lines.
@ OC_LOCKED
Output configuration locked in place.
int band_type_run_end[120]
band type run end points
uint8_t layout_map[MAX_ELEM_ID *4][3]
void(* update_ltp)(AACDecContext *ac, SingleChannelElement *sce)
void(* apply_independent_coupling)(AACDecContext *ac, SingleChannelElement *target, ChannelElement *cce, int index)
enum WindowSequence window_sequence[2]
void(* clip_output)(AACDecContext *ac, ChannelElement *che, int type, int samples)
@ OC_NONE
Output unconfigured.
void(* apply_dependent_coupling)(AACDecContext *ac, SingleChannelElement *target, ChannelElement *cce, int index)
An AVChannelLayout holds information about the channel layout of audio data.
void(* imdct_and_windowing)(AACDecContext *ac, SingleChannelElement *sce)
OCStatus
Output configuration status.
int prog_ref_level
A reference level for the long-term program audio level for all channels combined.
SingleChannelElement * output_element[MAX_CHANNELS]
Points to each SingleChannelElement.
enum AACOutputChannelOrder output_channel_order
int sfo[120]
scalefactor offsets
INTFLOAT_ALIGNED_UNION(32, buf_mdct, 1024)
enum BandType band_type[128]
band types
int dyn_rng_ctl[17]
DRC magnitude information.
void(* apply_ltp)(AACDecContext *ac, SingleChannelElement *sce)
float * output
PCM output.
void(* imdct_and_windowing_960)(AACDecContext *ac, SingleChannelElement *sce)
int ff_aac_decode_ics(AACDecContext *ac, SingleChannelElement *sce, GetBitContext *gb, int common_window, int scale_flag)
Decode an individual_channel_stream payload; reference: table 4.44.
Single Channel Element - used for both SCE and LFE elements.
channel element - generic struct for SCE/CPE/CCE/LFE
const uint16_t * swb_offset
table of offsets to the lowest spectral coefficient of a scalefactor band, sfb, for a particular wind...
#define RENAME_FIXED(name)
OutputConfiguration oc[2]
void(* imdct_and_windowing_eld)(AACDecContext *ac, SingleChannelElement *sce)
INTFLOAT_ALIGNED_UNION(32, coeffs, 1024)
coefficients for IMDCT, maybe processed
int pce_instance_tag
Indicates with which program the DRC info is associated.
float coef[8][4][TNS_MAX_ORDER]
int ch_select[8]
[0] shared list of gains; [1] list of gains for right channel; [2] list of gains for left channel; [3...
INTFLOAT_UNION(coef, [8][4][TNS_MAX_ORDER])
main AAC decoding context
main external API structure.
struct AVCodecContext * avctx
uint8_t prediction_used[41]
Filter the word “frame” indicates either a video frame or a group of audio samples
int band_incr
Number of DRC bands greater than 1 having DRC info.
AVChannelLayout ch_layout
int is_saved
Set if elements have stored overlap from previous frame.
int dyn_rng_sgn[17]
DRC sign information; 0 - positive, 1 - negative.
Decode-specific primitives.
uint8_t max_sfb
number of scalefactor bands per group
int interpolation_scheme
Indicates the interpolation scheme used in the SBR QMF domain.
@ OC_TRIAL_FRAME
Output configuration under trial specified by a frame header.
INTFLOAT_UNION(sf, [120])
scalefactors
int predictor_reset_group
int predictor_initialized