FFmpeg
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions | Variables
af_aconvert.c File Reference

sample format and channel layout conversion audio filter More...

#include "libavutil/channel_layout.h"
#include "libavutil/opt.h"
#include "libswresample/swresample.h"
#include "avfilter.h"
#include "audio.h"
#include "internal.h"

Go to the source code of this file.

Data Structures

struct  AConvertContext
 

Macros

#define OFFSET(x)   offsetof(AConvertContext, x)
 
#define A   AV_OPT_FLAG_AUDIO_PARAM
 
#define F   AV_OPT_FLAG_FILTERING_PARAM
 

Functions

 AVFILTER_DEFINE_CLASS (aconvert)
 
static av_cold int init (AVFilterContext *ctx)
 
static av_cold void uninit (AVFilterContext *ctx)
 
static int query_formats (AVFilterContext *ctx)
 
static int config_output (AVFilterLink *outlink)
 
static int filter_frame (AVFilterLink *inlink, AVFrame *insamplesref)
 

Variables

static const AVOption aconvert_options []
 
static const AVFilterPad aconvert_inputs []
 
static const AVFilterPad aconvert_outputs []
 
AVFilter ff_af_aconvert
 

Detailed Description

sample format and channel layout conversion audio filter

Definition in file af_aconvert.c.

Macro Definition Documentation

#define OFFSET (   x)    offsetof(AConvertContext, x)

Definition at line 44 of file af_aconvert.c.

#define A   AV_OPT_FLAG_AUDIO_PARAM

Definition at line 45 of file af_aconvert.c.

Definition at line 46 of file af_aconvert.c.

Referenced by idct().

Function Documentation

AVFILTER_DEFINE_CLASS ( aconvert  )
static av_cold int init ( AVFilterContext ctx)
static

Definition at line 55 of file af_aconvert.c.

static av_cold void uninit ( AVFilterContext ctx)
static

Definition at line 73 of file af_aconvert.c.

static int query_formats ( AVFilterContext ctx)
static

Definition at line 79 of file af_aconvert.c.

static int config_output ( AVFilterLink outlink)
static

Definition at line 110 of file af_aconvert.c.

static int filter_frame ( AVFilterLink inlink,
AVFrame insamplesref 
)
static

Definition at line 146 of file af_aconvert.c.

Variable Documentation

const AVOption aconvert_options[]
static
Initial value:
= {
{ "sample_fmt", "", OFFSET(format_str), AV_OPT_TYPE_STRING, .flags = A|F },
{ "channel_layout", "", OFFSET(channel_layout_str), AV_OPT_TYPE_STRING, .flags = A|F },
{ NULL }
}

Definition at line 47 of file af_aconvert.c.

const AVFilterPad aconvert_inputs[]
static
Initial value:
= {
{
.name = "default",
.filter_frame = filter_frame,
},
{ NULL }
}

Definition at line 168 of file af_aconvert.c.

const AVFilterPad aconvert_outputs[]
static
Initial value:
= {
{
.name = "default",
.config_props = config_output,
},
{ NULL }
}

Definition at line 177 of file af_aconvert.c.

AVFilter ff_af_aconvert
Initial value:
= {
.name = "aconvert",
.description = NULL_IF_CONFIG_SMALL("Convert the input audio to sample_fmt:channel_layout."),
.priv_size = sizeof(AConvertContext),
.priv_class = &aconvert_class,
.init = init,
}

Definition at line 186 of file af_aconvert.c.