FFmpeg
Data Fields
AC3EncodeContext Struct Reference

AC-3 encoder private context. More...

#include <ac3enc.h>

Data Fields

AVClassav_class
 AVClass used for AVOption. More...
 
AC3EncOptions options
 encoding options More...
 
AVCodecContextavctx
 parent AVCodecContext More...
 
PutBitContext pb
 bitstream writer context More...
 
AudioDSPContext adsp
 
AVFixedDSPContextfdsp
 
MECmpContext mecc
 
AC3DSPContext ac3dsp
 AC-3 optimized functions. More...
 
AVTXContexttx
 FFT context for MDCT calculation. More...
 
av_tx_fn tx_fn
 
const SampleTypemdct_window
 MDCT window function array. More...
 
AC3Block blocks [AC3_MAX_BLOCKS]
 per-block info More...
 
int fixed_point
 indicates if fixed-point encoder is being used More...
 
int eac3
 indicates if this is E-AC-3 vs. AC-3 More...
 
int bitstream_id
 bitstream id (bsid) More...
 
int bitstream_mode
 bitstream mode (bsmod) More...
 
int bit_rate
 target bit rate, in bits-per-second More...
 
int sample_rate
 sampling frequency, in Hz More...
 
int num_blks_code
 number of blocks code (numblkscod) More...
 
int num_blocks
 number of blocks per frame More...
 
int frame_size_min
 minimum frame size in case rounding is necessary More...
 
int frame_size
 current frame size in bytes More...
 
int frame_size_code
 frame size code (frmsizecod) More...
 
uint16_t crc_inv [2]
 
int64_t bits_written
 bit count (used to avg. bitrate) More...
 
int64_t samples_written
 sample count (used to avg. bitrate) More...
 
int fbw_channels
 number of full-bandwidth channels (nfchans) More...
 
int channels
 total number of channels (nchans) More...
 
int lfe_on
 indicates if there is an LFE channel (lfeon) More...
 
int lfe_channel
 channel index of the LFE channel More...
 
int has_center
 indicates if there is a center channel More...
 
int has_surround
 indicates if there are one or more surround channels More...
 
int channel_mode
 channel mode (acmod) More...
 
const uint8_t * channel_map
 channel map used to reorder channels More...
 
int center_mix_level
 center mix level code More...
 
int surround_mix_level
 surround mix level code More...
 
int ltrt_center_mix_level
 Lt/Rt center mix level code. More...
 
int ltrt_surround_mix_level
 Lt/Rt surround mix level code. More...
 
int loro_center_mix_level
 Lo/Ro center mix level code. More...
 
int loro_surround_mix_level
 Lo/Ro surround mix level code. More...
 
int cutoff
 user-specified cutoff frequency, in Hz More...
 
int bandwidth_code
 bandwidth code (0 to 60) (chbwcod) More...
 
int start_freq [AC3_MAX_CHANNELS]
 start frequency bin (strtmant) More...
 
int cpl_end_freq
 coupling channel end frequency bin More...
 
int cpl_on
 coupling turned on for this frame More...
 
int cpl_enabled
 coupling enabled for all frames More...
 
int num_cpl_subbands
 number of coupling subbands (ncplsubnd) More...
 
int num_cpl_bands
 number of coupling bands (ncplbnd) More...
 
uint8_t cpl_band_sizes [AC3_MAX_CPL_BANDS]
 number of coeffs in each coupling band More...
 
int rematrixing_enabled
 stereo rematrixing enabled More...
 
int slow_gain_code
 slow gain code (sgaincod) More...
 
int slow_decay_code
 slow decay code (sdcycod) More...
 
int fast_decay_code
 fast decay code (fdcycod) More...
 
int db_per_bit_code
 dB/bit code (dbpbcod) More...
 
int floor_code
 floor code (floorcod) More...
 
AC3BitAllocParameters bit_alloc
 bit allocation parameters More...
 
int coarse_snr_offset
 coarse SNR offsets (csnroffst) More...
 
int fast_gain_code [AC3_MAX_CHANNELS]
 fast gain codes (signal-to-mask ratio) (fgaincod) More...
 
int fine_snr_offset [AC3_MAX_CHANNELS]
 fine SNR offsets (fsnroffst) More...
 
int frame_bits_fixed
 number of non-coefficient bits for fixed parameters More...
 
int frame_bits
 all frame bits except exponents and mantissas More...
 
int exponent_bits
 number of bits used for exponents More...
 
SampleTypewindowed_samples
 
SampleType ** planar_samples
 
uint8_t * bap_buffer
 
uint8_t * bap1_buffer
 
CoefTypemdct_coef_buffer
 
int32_tfixed_coef_buffer
 
uint8_t * exp_buffer
 
uint8_t * grouped_exp_buffer
 
int16_t * psd_buffer
 
int16_t * band_psd_buffer
 
int16_t * mask_buffer
 
int16_t * qmant_buffer
 
uint8_t * cpl_coord_exp_buffer
 
uint8_t * cpl_coord_mant_buffer
 
uint8_t exp_strategy [AC3_MAX_CHANNELS][AC3_MAX_BLOCKS]
 exponent strategies More...
 
uint8_t frame_exp_strategy [AC3_MAX_CHANNELS]
 frame exp strategy index More...
 
int use_frame_exp_strategy
 indicates use of frame exp strategy More...
 
uint8_t exp_ref_block [AC3_MAX_CHANNELS][AC3_MAX_BLOCKS]
 reference blocks for EXP_REUSE More...
 
uint8_t * ref_bap [AC3_MAX_CHANNELS][AC3_MAX_BLOCKS]
 bit allocation pointers (bap) More...
 
int ref_bap_set
 indicates if ref_bap pointers have been set More...
 
int warned_alternate_bitstream
 
int(* mdct_init )(struct AC3EncodeContext *s)
 
int(* allocate_sample_buffers )(struct AC3EncodeContext *s)
 
void(* output_frame_header )(struct AC3EncodeContext *s)
 

Detailed Description

AC-3 encoder private context.

Definition at line 158 of file ac3enc.h.

Field Documentation

◆ av_class

AVClass* AC3EncodeContext::av_class

AVClass used for AVOption.

Definition at line 159 of file ac3enc.h.

◆ options

AC3EncOptions AC3EncodeContext::options

encoding options

Definition at line 160 of file ac3enc.h.

◆ avctx

AVCodecContext* AC3EncodeContext::avctx

parent AVCodecContext

Definition at line 161 of file ac3enc.h.

Referenced by ac3_fixed_encode_init(), encode_frame(), and ff_ac3_float_encode_init().

◆ pb

PutBitContext AC3EncodeContext::pb

bitstream writer context

Definition at line 162 of file ac3enc.h.

◆ adsp

AudioDSPContext AC3EncodeContext::adsp

Definition at line 163 of file ac3enc.h.

Referenced by clip_coefficients().

◆ fdsp

AVFixedDSPContext* AC3EncodeContext::fdsp

Definition at line 167 of file ac3enc.h.

◆ mecc

MECmpContext AC3EncodeContext::mecc

Definition at line 169 of file ac3enc.h.

◆ ac3dsp

AC3DSPContext AC3EncodeContext::ac3dsp

AC-3 optimized functions.

Definition at line 170 of file ac3enc.h.

◆ tx

AVTXContext* AC3EncodeContext::tx

FFT context for MDCT calculation.

Definition at line 171 of file ac3enc.h.

◆ tx_fn

av_tx_fn AC3EncodeContext::tx_fn

Definition at line 172 of file ac3enc.h.

◆ mdct_window

const SampleType* AC3EncodeContext::mdct_window

MDCT window function array.

Definition at line 173 of file ac3enc.h.

◆ blocks

AC3Block AC3EncodeContext::blocks[AC3_MAX_BLOCKS]

per-block info

Definition at line 175 of file ac3enc.h.

◆ fixed_point

int AC3EncodeContext::fixed_point

indicates if fixed-point encoder is being used

Definition at line 177 of file ac3enc.h.

◆ eac3

int AC3EncodeContext::eac3

indicates if this is E-AC-3 vs. AC-3

Definition at line 178 of file ac3enc.h.

◆ bitstream_id

int AC3EncodeContext::bitstream_id

bitstream id (bsid)

Definition at line 179 of file ac3enc.h.

◆ bitstream_mode

int AC3EncodeContext::bitstream_mode

bitstream mode (bsmod)

Definition at line 180 of file ac3enc.h.

◆ bit_rate

int AC3EncodeContext::bit_rate

target bit rate, in bits-per-second

Definition at line 182 of file ac3enc.h.

◆ sample_rate

int AC3EncodeContext::sample_rate

sampling frequency, in Hz

Definition at line 183 of file ac3enc.h.

◆ num_blks_code

int AC3EncodeContext::num_blks_code

number of blocks code (numblkscod)

Definition at line 185 of file ac3enc.h.

◆ num_blocks

int AC3EncodeContext::num_blocks

number of blocks per frame

Definition at line 186 of file ac3enc.h.

Referenced by apply_channel_coupling().

◆ frame_size_min

int AC3EncodeContext::frame_size_min

minimum frame size in case rounding is necessary

Definition at line 187 of file ac3enc.h.

◆ frame_size

int AC3EncodeContext::frame_size

current frame size in bytes

Definition at line 188 of file ac3enc.h.

◆ frame_size_code

int AC3EncodeContext::frame_size_code

frame size code (frmsizecod)

Definition at line 189 of file ac3enc.h.

◆ crc_inv

uint16_t AC3EncodeContext::crc_inv[2]

Definition at line 190 of file ac3enc.h.

◆ bits_written

int64_t AC3EncodeContext::bits_written

bit count (used to avg. bitrate)

Definition at line 191 of file ac3enc.h.

◆ samples_written

int64_t AC3EncodeContext::samples_written

sample count (used to avg. bitrate)

Definition at line 192 of file ac3enc.h.

◆ fbw_channels

int AC3EncodeContext::fbw_channels

number of full-bandwidth channels (nfchans)

Definition at line 194 of file ac3enc.h.

◆ channels

int AC3EncodeContext::channels

total number of channels (nchans)

Definition at line 195 of file ac3enc.h.

◆ lfe_on

int AC3EncodeContext::lfe_on

indicates if there is an LFE channel (lfeon)

Definition at line 196 of file ac3enc.h.

◆ lfe_channel

int AC3EncodeContext::lfe_channel

channel index of the LFE channel

Definition at line 197 of file ac3enc.h.

◆ has_center

int AC3EncodeContext::has_center

indicates if there is a center channel

Definition at line 198 of file ac3enc.h.

◆ has_surround

int AC3EncodeContext::has_surround

indicates if there are one or more surround channels

Definition at line 199 of file ac3enc.h.

◆ channel_mode

int AC3EncodeContext::channel_mode

channel mode (acmod)

Definition at line 200 of file ac3enc.h.

◆ channel_map

const uint8_t* AC3EncodeContext::channel_map

channel map used to reorder channels

Definition at line 201 of file ac3enc.h.

◆ center_mix_level

int AC3EncodeContext::center_mix_level

center mix level code

Definition at line 203 of file ac3enc.h.

◆ surround_mix_level

int AC3EncodeContext::surround_mix_level

surround mix level code

Definition at line 204 of file ac3enc.h.

◆ ltrt_center_mix_level

int AC3EncodeContext::ltrt_center_mix_level

Lt/Rt center mix level code.

Definition at line 205 of file ac3enc.h.

◆ ltrt_surround_mix_level

int AC3EncodeContext::ltrt_surround_mix_level

Lt/Rt surround mix level code.

Definition at line 206 of file ac3enc.h.

◆ loro_center_mix_level

int AC3EncodeContext::loro_center_mix_level

Lo/Ro center mix level code.

Definition at line 207 of file ac3enc.h.

◆ loro_surround_mix_level

int AC3EncodeContext::loro_surround_mix_level

Lo/Ro surround mix level code.

Definition at line 208 of file ac3enc.h.

◆ cutoff

int AC3EncodeContext::cutoff

user-specified cutoff frequency, in Hz

Definition at line 210 of file ac3enc.h.

◆ bandwidth_code

int AC3EncodeContext::bandwidth_code

bandwidth code (0 to 60) (chbwcod)

Definition at line 211 of file ac3enc.h.

◆ start_freq

int AC3EncodeContext::start_freq[AC3_MAX_CHANNELS]

start frequency bin (strtmant)

Definition at line 212 of file ac3enc.h.

◆ cpl_end_freq

int AC3EncodeContext::cpl_end_freq

coupling channel end frequency bin

Definition at line 213 of file ac3enc.h.

Referenced by apply_channel_coupling().

◆ cpl_on

int AC3EncodeContext::cpl_on

coupling turned on for this frame

Definition at line 215 of file ac3enc.h.

◆ cpl_enabled

int AC3EncodeContext::cpl_enabled

coupling enabled for all frames

Definition at line 216 of file ac3enc.h.

◆ num_cpl_subbands

int AC3EncodeContext::num_cpl_subbands

number of coupling subbands (ncplsubnd)

Definition at line 217 of file ac3enc.h.

◆ num_cpl_bands

int AC3EncodeContext::num_cpl_bands

number of coupling bands (ncplbnd)

Definition at line 218 of file ac3enc.h.

◆ cpl_band_sizes

uint8_t AC3EncodeContext::cpl_band_sizes[AC3_MAX_CPL_BANDS]

number of coeffs in each coupling band

Definition at line 219 of file ac3enc.h.

◆ rematrixing_enabled

int AC3EncodeContext::rematrixing_enabled

stereo rematrixing enabled

Definition at line 221 of file ac3enc.h.

◆ slow_gain_code

int AC3EncodeContext::slow_gain_code

slow gain code (sgaincod)

Definition at line 224 of file ac3enc.h.

◆ slow_decay_code

int AC3EncodeContext::slow_decay_code

slow decay code (sdcycod)

Definition at line 225 of file ac3enc.h.

◆ fast_decay_code

int AC3EncodeContext::fast_decay_code

fast decay code (fdcycod)

Definition at line 226 of file ac3enc.h.

◆ db_per_bit_code

int AC3EncodeContext::db_per_bit_code

dB/bit code (dbpbcod)

Definition at line 227 of file ac3enc.h.

◆ floor_code

int AC3EncodeContext::floor_code

floor code (floorcod)

Definition at line 228 of file ac3enc.h.

◆ bit_alloc

AC3BitAllocParameters AC3EncodeContext::bit_alloc

bit allocation parameters

Definition at line 229 of file ac3enc.h.

◆ coarse_snr_offset

int AC3EncodeContext::coarse_snr_offset

coarse SNR offsets (csnroffst)

Definition at line 230 of file ac3enc.h.

◆ fast_gain_code

int AC3EncodeContext::fast_gain_code[AC3_MAX_CHANNELS]

fast gain codes (signal-to-mask ratio) (fgaincod)

Definition at line 231 of file ac3enc.h.

◆ fine_snr_offset

int AC3EncodeContext::fine_snr_offset[AC3_MAX_CHANNELS]

fine SNR offsets (fsnroffst)

Definition at line 232 of file ac3enc.h.

◆ frame_bits_fixed

int AC3EncodeContext::frame_bits_fixed

number of non-coefficient bits for fixed parameters

Definition at line 233 of file ac3enc.h.

◆ frame_bits

int AC3EncodeContext::frame_bits

all frame bits except exponents and mantissas

Definition at line 234 of file ac3enc.h.

◆ exponent_bits

int AC3EncodeContext::exponent_bits

number of bits used for exponents

Definition at line 235 of file ac3enc.h.

◆ windowed_samples

SampleType* AC3EncodeContext::windowed_samples

Definition at line 237 of file ac3enc.h.

◆ planar_samples

SampleType** AC3EncodeContext::planar_samples

Definition at line 238 of file ac3enc.h.

◆ bap_buffer

uint8_t* AC3EncodeContext::bap_buffer

Definition at line 239 of file ac3enc.h.

◆ bap1_buffer

uint8_t* AC3EncodeContext::bap1_buffer

Definition at line 240 of file ac3enc.h.

◆ mdct_coef_buffer

CoefType* AC3EncodeContext::mdct_coef_buffer

Definition at line 241 of file ac3enc.h.

◆ fixed_coef_buffer

int32_t* AC3EncodeContext::fixed_coef_buffer

Definition at line 242 of file ac3enc.h.

◆ exp_buffer

uint8_t* AC3EncodeContext::exp_buffer

Definition at line 243 of file ac3enc.h.

◆ grouped_exp_buffer

uint8_t* AC3EncodeContext::grouped_exp_buffer

Definition at line 244 of file ac3enc.h.

◆ psd_buffer

int16_t* AC3EncodeContext::psd_buffer

Definition at line 245 of file ac3enc.h.

◆ band_psd_buffer

int16_t* AC3EncodeContext::band_psd_buffer

Definition at line 246 of file ac3enc.h.

◆ mask_buffer

int16_t* AC3EncodeContext::mask_buffer

Definition at line 247 of file ac3enc.h.

◆ qmant_buffer

int16_t* AC3EncodeContext::qmant_buffer

Definition at line 248 of file ac3enc.h.

◆ cpl_coord_exp_buffer

uint8_t* AC3EncodeContext::cpl_coord_exp_buffer

Definition at line 249 of file ac3enc.h.

◆ cpl_coord_mant_buffer

uint8_t* AC3EncodeContext::cpl_coord_mant_buffer

Definition at line 250 of file ac3enc.h.

◆ exp_strategy

uint8_t AC3EncodeContext::exp_strategy[AC3_MAX_CHANNELS][AC3_MAX_BLOCKS]

exponent strategies

Definition at line 252 of file ac3enc.h.

◆ frame_exp_strategy

uint8_t AC3EncodeContext::frame_exp_strategy[AC3_MAX_CHANNELS]

frame exp strategy index

Definition at line 253 of file ac3enc.h.

◆ use_frame_exp_strategy

int AC3EncodeContext::use_frame_exp_strategy

indicates use of frame exp strategy

Definition at line 254 of file ac3enc.h.

◆ exp_ref_block

uint8_t AC3EncodeContext::exp_ref_block[AC3_MAX_CHANNELS][AC3_MAX_BLOCKS]

reference blocks for EXP_REUSE

Definition at line 255 of file ac3enc.h.

◆ ref_bap

uint8_t* AC3EncodeContext::ref_bap[AC3_MAX_CHANNELS][AC3_MAX_BLOCKS]

bit allocation pointers (bap)

Definition at line 256 of file ac3enc.h.

◆ ref_bap_set

int AC3EncodeContext::ref_bap_set

indicates if ref_bap pointers have been set

Definition at line 257 of file ac3enc.h.

◆ warned_alternate_bitstream

int AC3EncodeContext::warned_alternate_bitstream

Definition at line 259 of file ac3enc.h.

◆ mdct_init

int(* AC3EncodeContext::mdct_init) (struct AC3EncodeContext *s)

Definition at line 262 of file ac3enc.h.

◆ allocate_sample_buffers

int(* AC3EncodeContext::allocate_sample_buffers) (struct AC3EncodeContext *s)

Definition at line 265 of file ac3enc.h.

◆ output_frame_header

void(* AC3EncodeContext::output_frame_header) (struct AC3EncodeContext *s)

Definition at line 268 of file ac3enc.h.


The documentation for this struct was generated from the following file: