FFmpeg
Macros | Enumerations | Functions
aacsbr.h File Reference
#include "get_bits.h"
#include "aac/aacdec.h"
#include "libavutil/attributes_internal.h"

Go to the source code of this file.

Macros

#define ENVELOPE_ADJUSTMENT_OFFSET   2
 
#define NOISE_FLOOR_OFFSET   6
 

Enumerations

enum  {
  T_HUFFMAN_ENV_1_5DB, F_HUFFMAN_ENV_1_5DB, T_HUFFMAN_ENV_BAL_1_5DB, F_HUFFMAN_ENV_BAL_1_5DB,
  T_HUFFMAN_ENV_3_0DB, F_HUFFMAN_ENV_3_0DB, T_HUFFMAN_ENV_BAL_3_0DB, F_HUFFMAN_ENV_BAL_3_0DB,
  T_HUFFMAN_NOISE_3_0DB, T_HUFFMAN_NOISE_BAL_3_0DB
}
 SBR VLC tables. More...
 
enum  { FIXFIX, FIXVAR, VARFIX, VARVAR }
 bs_frame_class - frame class of current SBR frame (14496-3 sp04 p98) More...
 
enum  { EXTENSION_ID_PS = 2 }
 

Functions

FF_VISIBILITY_PUSH_HIDDEN void ff_aac_sbr_init (void)
 Initialize SBR. More...
 
void ff_aac_sbr_init_fixed (void)
 
int ff_aac_sbr_ctx_alloc_init (AACDecContext *ac, ChannelElement **che, int id_aac)
 Allocate an ExtChannelElement (if necessary) and initialize the SBR context contained in it. More...
 
int ff_aac_sbr_ctx_alloc_init_fixed (AACDecContext *ac, ChannelElement **che, int id_aac)
 
void ff_aac_sbr_ctx_close (ChannelElement *che)
 Close the SBR context implicitly contained in a ChannelElement. More...
 
void ff_aac_sbr_ctx_close_fixed (ChannelElement *che)
 
int ff_aac_sbr_decode_extension (AACDecContext *ac, ChannelElement *che, GetBitContext *gb, int crc, int cnt, int id_aac)
 Decode one SBR element. More...
 
int ff_aac_sbr_decode_extension_fixed (AACDecContext *ac, ChannelElement *che, GetBitContext *gb, int crc, int cnt, int id_aac)
 
int ff_aac_sbr_config_usac (AACDecContext *ac, ChannelElement *che, AACUsacElemConfig *ue)
 Due to channel allocation not being known upon SBR parameter transmission, supply the parameters separately. More...
 
int ff_aac_sbr_decode_usac_data (AACDecContext *ac, ChannelElement *che, AACUsacElemConfig *ue, GetBitContext *gb, int sbr_ch, int indep_flag)
 Decode frame SBR data, USAC. More...
 
void ff_aac_sbr_apply (AACDecContext *ac, ChannelElement *che, int id_aac, void *L, void *R)
 Apply one SBR element to one AAC element. More...
 
void ff_aac_sbr_apply_fixed (AACDecContext *ac, ChannelElement *che, int id_aac, void *L, void *R)
 

Detailed Description

AAC Spectral Band Replication function declarations

Author
Robert Swain ( rob opendot cl )

Definition in file aacsbr.h.

Macro Definition Documentation

◆ ENVELOPE_ADJUSTMENT_OFFSET

#define ENVELOPE_ADJUSTMENT_OFFSET   2

Definition at line 37 of file aacsbr.h.

◆ NOISE_FLOOR_OFFSET

#define NOISE_FLOOR_OFFSET   6

Definition at line 38 of file aacsbr.h.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum

SBR VLC tables.

Enumerator
T_HUFFMAN_ENV_1_5DB 
F_HUFFMAN_ENV_1_5DB 
T_HUFFMAN_ENV_BAL_1_5DB 
F_HUFFMAN_ENV_BAL_1_5DB 
T_HUFFMAN_ENV_3_0DB 
F_HUFFMAN_ENV_3_0DB 
T_HUFFMAN_ENV_BAL_3_0DB 
F_HUFFMAN_ENV_BAL_3_0DB 
T_HUFFMAN_NOISE_3_0DB 
T_HUFFMAN_NOISE_BAL_3_0DB 

Definition at line 43 of file aacsbr.h.

◆ anonymous enum

anonymous enum

bs_frame_class - frame class of current SBR frame (14496-3 sp04 p98)

Enumerator
FIXFIX 
FIXVAR 
VARFIX 
VARVAR 

Definition at line 59 of file aacsbr.h.

◆ anonymous enum

anonymous enum
Enumerator
EXTENSION_ID_PS 

Definition at line 66 of file aacsbr.h.

Function Documentation

◆ ff_aac_sbr_init()

FF_VISIBILITY_PUSH_HIDDEN void ff_aac_sbr_init ( void  )

Initialize SBR.

Definition at line 52 of file aacsbr_template.c.

Referenced by init_tables_float_fn().

◆ ff_aac_sbr_init_fixed()

void ff_aac_sbr_init_fixed ( void  )

Referenced by init_tables_fixed_fn().

◆ ff_aac_sbr_ctx_alloc_init()

int ff_aac_sbr_ctx_alloc_init ( AACDecContext ac,
ChannelElement **  che,
int  id_aac 
)

Allocate an ExtChannelElement (if necessary) and initialize the SBR context contained in it.

Definition at line 70 of file aacsbr_template.c.

◆ ff_aac_sbr_ctx_alloc_init_fixed()

int ff_aac_sbr_ctx_alloc_init_fixed ( AACDecContext ac,
ChannelElement **  che,
int  id_aac 
)

◆ ff_aac_sbr_ctx_close()

void ff_aac_sbr_ctx_close ( ChannelElement che)

Close the SBR context implicitly contained in a ChannelElement.

Definition at line 115 of file aacsbr_template.c.

◆ ff_aac_sbr_ctx_close_fixed()

void ff_aac_sbr_ctx_close_fixed ( ChannelElement che)

◆ ff_aac_sbr_decode_extension()

int ff_aac_sbr_decode_extension ( AACDecContext ac,
ChannelElement che,
GetBitContext gb_host,
int  crc,
int  cnt,
int  id_aac 
)

Decode one SBR element.

Decode one SBR element.

Parameters
crcflag indicating the presence of CRC checksum
cntlength of TYPE_FIL syntactic element in bytes
Returns
Returns number of bytes consumed from the TYPE_FIL element.

Definition at line 1133 of file aacsbr_template.c.

◆ ff_aac_sbr_decode_extension_fixed()

int ff_aac_sbr_decode_extension_fixed ( AACDecContext ac,
ChannelElement che,
GetBitContext gb,
int  crc,
int  cnt,
int  id_aac 
)

◆ ff_aac_sbr_config_usac()

int ff_aac_sbr_config_usac ( AACDecContext ac,
ChannelElement che,
AACUsacElemConfig ue 
)

Due to channel allocation not being known upon SBR parameter transmission, supply the parameters separately.

Functionally identical to ff_aac_sbr_decode_extension()

Definition at line 1200 of file aacsbr_template.c.

Referenced by ff_aac_usac_reset_state().

◆ ff_aac_sbr_decode_usac_data()

int ff_aac_sbr_decode_usac_data ( AACDecContext ac,
ChannelElement che,
AACUsacElemConfig ue,
GetBitContext gb,
int  sbr_ch,
int  indep_flag 
)

Decode frame SBR data, USAC.

Definition at line 1208 of file aacsbr_template.c.

Referenced by decode_usac_core_coder().

◆ ff_aac_sbr_apply()

void ff_aac_sbr_apply ( AACDecContext ac,
ChannelElement che,
int  id_aac,
void *  L,
void *  R 
)

Apply one SBR element to one AAC element.

Definition at line 1671 of file aacsbr_template.c.

◆ ff_aac_sbr_apply_fixed()

void ff_aac_sbr_apply_fixed ( AACDecContext ac,
ChannelElement che,
int  id_aac,
void *  L,
void *  R 
)