FFmpeg
Variables
ac3dec_float.c File Reference
#include "ac3dec.h"
#include "eac3dec.c"
#include "ac3dec.c"

Go to the source code of this file.

Variables

static const AVOption options []
 Upmix delay samples from stereo to original channel layout. More...
 
static const AVClass ac3_eac3_decoder_class
 
const AVCodec ff_ac3_decoder
 

Variable Documentation

◆ options

const AVOption options[]
static
Initial value:
= {
{ "cons_noisegen", "enable consistent noise generation", OFFSET(consistent_noise_generation), AV_OPT_TYPE_BOOL, {.i64 = 0 }, 0, 1, PAR },
{ "drc_scale", "percentage of dynamic range compression to apply", OFFSET(drc_scale), AV_OPT_TYPE_FLOAT, {.dbl = 1.0}, 0.0, 6.0, PAR },
{ "heavy_compr", "enable heavy dynamic range compression", OFFSET(heavy_compression), AV_OPT_TYPE_BOOL, {.i64 = 0 }, 0, 1, PAR },
{ "target_level", "target level in -dBFS (0 not applied)", OFFSET(target_level), AV_OPT_TYPE_INT, {.i64 = 0 }, -31, 0, PAR },
{"dmix_mode", "Preferred Stereo Downmix Mode", OFFSET(preferred_stereo_downmix), AV_OPT_TYPE_INT, {.i64 = -1 }, -1, 2, 0, "dmix_mode"},
{"ltrt_cmixlev", "Lt/Rt Center Mix Level", OFFSET(ltrt_center_mix_level), AV_OPT_TYPE_FLOAT, {.dbl = -1.0 }, -1.0, 2.0, 0},
{"ltrt_surmixlev", "Lt/Rt Surround Mix Level", OFFSET(ltrt_surround_mix_level), AV_OPT_TYPE_FLOAT, {.dbl = -1.0 }, -1.0, 2.0, 0},
{"loro_cmixlev", "Lo/Ro Center Mix Level", OFFSET(loro_center_mix_level), AV_OPT_TYPE_FLOAT, {.dbl = -1.0 }, -1.0, 2.0, 0},
{"loro_surmixlev", "Lo/Ro Surround Mix Level", OFFSET(loro_surround_mix_level), AV_OPT_TYPE_FLOAT, {.dbl = -1.0 }, -1.0, 2.0, 0},
{ NULL},
}

Upmix delay samples from stereo to original channel layout.

Definition at line 34 of file ac3dec_float.c.

◆ ac3_eac3_decoder_class

const AVClass ac3_eac3_decoder_class
static
Initial value:
= {
.class_name = "(E-)AC3 decoder",
.item_name = av_default_item_name,
.option = options,
}

Definition at line 49 of file ac3dec_float.c.

◆ ff_ac3_decoder

const AVCodec ff_ac3_decoder
Initial value:
= {
.name = "ac3",
.priv_data_size = sizeof (AC3DecodeContext),
.close = ac3_decode_end,
.capabilities = AV_CODEC_CAP_CHANNEL_CONF |
.long_name = NULL_IF_CONFIG_SMALL("ATSC A/52A (AC-3)"),
.sample_fmts = (const enum AVSampleFormat[]) { AV_SAMPLE_FMT_FLTP,
.priv_class = &ac3_eac3_decoder_class,
}

Definition at line 56 of file ac3dec_float.c.

AV_SAMPLE_FMT_FLTP
@ AV_SAMPLE_FMT_FLTP
float, planar
Definition: samplefmt.h:69
FF_CODEC_CAP_INIT_THREADSAFE
#define FF_CODEC_CAP_INIT_THREADSAFE
The codec does not modify any global variables in the init function, allowing to call the init functi...
Definition: internal.h:42
AV_CODEC_ID_AC3
@ AV_CODEC_ID_AC3
Definition: codec_id.h:426
init
static int init
Definition: av_tx.c:47
decode
static void decode(AVCodecContext *dec_ctx, AVPacket *pkt, AVFrame *frame, FILE *outfile)
Definition: decode_audio.c:71
AVMEDIA_TYPE_AUDIO
@ AVMEDIA_TYPE_AUDIO
Definition: avutil.h:202
ac3_decode_init
static av_cold int ac3_decode_init(AVCodecContext *avctx)
AVCodec initialization.
Definition: ac3dec.c:185
LIBAVUTIL_VERSION_INT
#define LIBAVUTIL_VERSION_INT
Definition: version.h:85
NULL
#define NULL
Definition: coverity.c:32
ac3_eac3_decoder_class
static const AVClass ac3_eac3_decoder_class
Definition: ac3dec_float.c:49
av_default_item_name
const char * av_default_item_name(void *ptr)
Return the context name.
Definition: log.c:235
options
static const AVOption options[]
Upmix delay samples from stereo to original channel layout.
Definition: ac3dec_float.c:34
AV_CODEC_CAP_CHANNEL_CONF
#define AV_CODEC_CAP_CHANNEL_CONF
Codec should fill in channel configuration and samplerate instead of container.
Definition: codec.h:109
AV_CODEC_CAP_DR1
#define AV_CODEC_CAP_DR1
Codec uses get_buffer() or get_encode_buffer() for allocating buffers and supports custom allocators.
Definition: codec.h:52
NULL_IF_CONFIG_SMALL
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification.
Definition: internal.h:117
AV_SAMPLE_FMT_NONE
@ AV_SAMPLE_FMT_NONE
Definition: samplefmt.h:59
AV_OPT_TYPE_FLOAT
@ AV_OPT_TYPE_FLOAT
Definition: opt.h:227
FF_CODEC_CAP_INIT_CLEANUP
#define FF_CODEC_CAP_INIT_CLEANUP
The codec allows calling the close function for deallocation even if the init function returned a fai...
Definition: internal.h:50
AVSampleFormat
AVSampleFormat
Audio sample formats.
Definition: samplefmt.h:58
ac3_decode_end
static av_cold int ac3_decode_end(AVCodecContext *avctx)
Uninitialize the AC-3 decoder.
Definition: ac3dec.c:1837
OFFSET
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 default minimum maximum flags name is the option keep it simple and lowercase description are in without and describe what they for example set the foo of the bar offset is the offset of the field in your see the OFFSET() macro
AV_OPT_TYPE_INT
@ AV_OPT_TYPE_INT
Definition: opt.h:224
AV_OPT_TYPE_BOOL
@ AV_OPT_TYPE_BOOL
Definition: opt.h:241
PAR
@ PAR
Definition: af_afade.c:54
ac3_decode_frame
static int ac3_decode_frame(AVCodecContext *avctx, void *data, int *got_frame_ptr, AVPacket *avpkt)
Decode a single AC-3 frame.
Definition: ac3dec.c:1468