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

Bauer stereo-to-binaural filter. More...

#include <bs2b.h>
#include "libavutil/channel_layout.h"
#include "libavutil/common.h"
#include "libavutil/opt.h"
#include "audio.h"
#include "avfilter.h"
#include "formats.h"
#include "internal.h"

Go to the source code of this file.

Data Structures

struct  Bs2bContext
 

Macros

#define OFFSET(x)   offsetof(Bs2bContext, x)
 
#define A   AV_OPT_FLAG_AUDIO_PARAM | AV_OPT_FLAG_FILTERING_PARAM
 

Typedefs

typedef void(* filter_func )(t_bs2bdp bs2bdp, uint8_t *sample, int n)
 

Functions

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

Variables

static const AVOption bs2b_options []
 
static const AVFilterPad bs2b_inputs []
 
static const AVFilterPad bs2b_outputs []
 
AVFilter ff_af_bs2b
 

Detailed Description

Bauer stereo-to-binaural filter.

Definition in file af_bs2b.c.

Macro Definition Documentation

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

Definition at line 49 of file af_bs2b.c.

Definition at line 50 of file af_bs2b.c.

Typedef Documentation

typedef void(* filter_func)(t_bs2bdp bs2bdp, uint8_t *sample, int n)

Definition at line 35 of file af_bs2b.c.

Function Documentation

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

Definition at line 67 of file af_bs2b.c.

static av_cold void uninit ( AVFilterContext ctx)
static

Definition at line 85 of file af_bs2b.c.

static int query_formats ( AVFilterContext ctx)
static

Definition at line 93 of file af_bs2b.c.

static int filter_frame ( AVFilterLink inlink,
AVFrame frame 
)
static

Definition at line 127 of file af_bs2b.c.

static int config_output ( AVFilterLink outlink)
static

Definition at line 160 of file af_bs2b.c.

Variable Documentation

const AVOption bs2b_options[]
static
Initial value:
= {
{ "profile", "Apply a pre-defined crossfeed level",
OFFSET(profile), AV_OPT_TYPE_INT, { .i64 = BS2B_DEFAULT_CLEVEL }, 0, INT_MAX, A, "profile" },
{ "default", "default profile", 0, AV_OPT_TYPE_CONST, { .i64 = BS2B_DEFAULT_CLEVEL }, 0, 0, A, "profile" },
{ "cmoy", "Chu Moy circuit", 0, AV_OPT_TYPE_CONST, { .i64 = BS2B_CMOY_CLEVEL }, 0, 0, A, "profile" },
{ "jmeier", "Jan Meier circuit", 0, AV_OPT_TYPE_CONST, { .i64 = BS2B_JMEIER_CLEVEL }, 0, 0, A, "profile" },
{ "fcut", "Set cut frequency (in Hz)",
OFFSET(fcut), AV_OPT_TYPE_INT, { .i64 = 0 }, 0, BS2B_MAXFCUT, A },
{ "feed", "Set feed level (in Hz)",
OFFSET(feed), AV_OPT_TYPE_INT, { .i64 = 0 }, 0, BS2B_MAXFEED, A },
{ NULL },
}
#define NULL
Definition: coverity.c:32
#define OFFSET(x)
Definition: af_bs2b.c:49
mfxU16 profile
Definition: qsvenc.c:44
#define A
Definition: af_bs2b.c:50

Definition at line 52 of file af_bs2b.c.

const AVFilterPad bs2b_inputs[]
static
Initial value:
= {
{
.name = "default",
.filter_frame = filter_frame,
},
{ NULL }
}
#define NULL
Definition: coverity.c:32
static int filter_frame(AVFilterLink *inlink, AVFrame *frame)
Definition: af_bs2b.c:127

Definition at line 196 of file af_bs2b.c.

const AVFilterPad bs2b_outputs[]
static
Initial value:
= {
{
.name = "default",
.config_props = config_output,
},
{ NULL }
}
#define NULL
Definition: coverity.c:32
static int config_output(AVFilterLink *outlink)
Definition: af_bs2b.c:160

Definition at line 205 of file af_bs2b.c.

AVFilter ff_af_bs2b
Initial value:
= {
.name = "bs2b",
.description = NULL_IF_CONFIG_SMALL("Bauer stereo-to-binaural filter."),
.query_formats = query_formats,
.priv_size = sizeof(Bs2bContext),
.priv_class = &bs2b_class,
.init = init,
}
static const AVFilterPad bs2b_inputs[]
Definition: af_bs2b.c:196
static int query_formats(AVFilterContext *ctx)
Definition: af_bs2b.c:93
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
Definition: internal.h:186
static const AVFilterPad inputs[]
Definition: af_acontrast.c:193
static const AVFilterPad outputs[]
Definition: af_acontrast.c:203
static const AVFilterPad bs2b_outputs[]
Definition: af_bs2b.c:205
static av_cold void uninit(AVFilterContext *ctx)
Definition: af_bs2b.c:85
static av_cold int init(AVFilterContext *ctx)
Definition: af_bs2b.c:67

Definition at line 214 of file af_bs2b.c.