FFmpeg
Data Structures | Macros | Functions | Variables
avf_abitscope.c File Reference
#include "libavutil/avassert.h"
#include "libavutil/avstring.h"
#include "libavutil/intreadwrite.h"
#include "libavutil/opt.h"
#include "libavutil/parseutils.h"
#include "avfilter.h"
#include "filters.h"
#include "formats.h"
#include "audio.h"
#include "video.h"
#include "internal.h"

Go to the source code of this file.

Data Structures

struct  AudioBitScopeContext
 

Macros

#define OFFSET(x)   offsetof(AudioBitScopeContext, x)
 
#define FLAGS   AV_OPT_FLAG_FILTERING_PARAM|AV_OPT_FLAG_VIDEO_PARAM
 

Functions

 AVFILTER_DEFINE_CLASS (abitscope)
 
static int query_formats (AVFilterContext *ctx)
 
static int config_input (AVFilterLink *inlink)
 
static int config_output (AVFilterLink *outlink)
 
static void count_bits (AudioBitScopeContext *s, uint32_t sample, int max)
 
static int filter_frame (AVFilterLink *inlink, AVFrame *insamples)
 
static int activate (AVFilterContext *ctx)
 

Variables

static const AVOption abitscope_options []
 
static const AVFilterPad inputs []
 
static const AVFilterPad outputs []
 
AVFilter ff_avf_abitscope
 

Macro Definition Documentation

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

Definition at line 47 of file avf_abitscope.c.

Definition at line 48 of file avf_abitscope.c.

Function Documentation

AVFILTER_DEFINE_CLASS ( abitscope  )
static int query_formats ( AVFilterContext ctx)
static

Definition at line 61 of file avf_abitscope.c.

static int config_input ( AVFilterLink inlink)
static

Definition at line 92 of file avf_abitscope.c.

static int config_output ( AVFilterLink outlink)
static

Definition at line 128 of file avf_abitscope.c.

static void count_bits ( AudioBitScopeContext s,
uint32_t  sample,
int  max 
)
static

Definition at line 140 of file avf_abitscope.c.

Referenced by filter_frame().

static int filter_frame ( AVFilterLink inlink,
AVFrame insamples 
)
static

Definition at line 150 of file avf_abitscope.c.

Referenced by activate().

static int activate ( AVFilterContext ctx)
static

Definition at line 224 of file avf_abitscope.c.

Variable Documentation

const AVOption abitscope_options[]
static
Initial value:
= {
{ "rate", "set video rate", OFFSET(frame_rate), AV_OPT_TYPE_VIDEO_RATE, {.str="25"}, 0, INT_MAX, FLAGS },
{ "r", "set video rate", OFFSET(frame_rate), AV_OPT_TYPE_VIDEO_RATE, {.str="25"}, 0, INT_MAX, FLAGS },
{ "size", "set video size", OFFSET(w), AV_OPT_TYPE_IMAGE_SIZE, {.str="1024x256"}, 0, 0, FLAGS },
{ "s", "set video size", OFFSET(w), AV_OPT_TYPE_IMAGE_SIZE, {.str="1024x256"}, 0, 0, FLAGS },
{ "colors", "set channels colors", OFFSET(colors), AV_OPT_TYPE_STRING, {.str = "red|green|blue|yellow|orange|lime|pink|magenta|brown" }, 0, 0, FLAGS },
{ NULL }
}
#define NULL
Definition: coverity.c:32
#define OFFSET(x)
Definition: avf_abitscope.c:47
#define FLAGS
Definition: avf_abitscope.c:48
uint8_t w
Definition: llviddspenc.c:38
offset must point to AVRational
Definition: opt.h:236
offset must point to two consecutive integers
Definition: opt.h:233

Definition at line 50 of file avf_abitscope.c.

const AVFilterPad inputs[]
static
Initial value:
= {
{
.name = "default",
.config_props = config_input,
},
{ NULL }
}
static int config_input(AVFilterLink *inlink)
Definition: avf_abitscope.c:92
#define NULL
Definition: coverity.c:32

Definition at line 246 of file avf_abitscope.c.

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

Definition at line 255 of file avf_abitscope.c.

AVFilter ff_avf_abitscope
Initial value:
= {
.name = "abitscope",
.description = NULL_IF_CONFIG_SMALL("Convert input audio to audio bit scope video output."),
.query_formats = query_formats,
.priv_size = sizeof(AudioBitScopeContext),
.priv_class = &abitscope_class,
}
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
Definition: internal.h:186
static int query_formats(AVFilterContext *ctx)
Definition: avf_abitscope.c:61
static const AVFilterPad inputs[]
static const AVFilterPad outputs[]
static int activate(AVFilterContext *ctx)

Definition at line 264 of file avf_abitscope.c.