FFmpeg
Data Structures | Macros | Functions | Variables
noise_bsf.c File Reference
#include <stdlib.h>
#include <string.h>
#include "avcodec.h"
#include "bsf.h"
#include "libavutil/log.h"
#include "libavutil/mem.h"
#include "libavutil/opt.h"

Go to the source code of this file.

Data Structures

struct  NoiseContext
 

Macros

#define OFFSET(x)   offsetof(NoiseContext, x)
 
#define FLAGS   (AV_OPT_FLAG_VIDEO_PARAM|AV_OPT_FLAG_AUDIO_PARAM|AV_OPT_FLAG_BSF_PARAM)
 

Functions

static int noise (AVBSFContext *ctx, AVPacket *pkt)
 

Variables

static const AVOption options []
 
static const AVClass noise_class
 
const AVBitStreamFilter ff_noise_bsf
 

Macro Definition Documentation

◆ OFFSET

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

Definition at line 73 of file noise_bsf.c.

◆ FLAGS

Definition at line 74 of file noise_bsf.c.

Function Documentation

◆ noise()

static int noise ( AVBSFContext ctx,
AVPacket pkt 
)
static

Variable Documentation

◆ options

const AVOption options[]
static
Initial value:
= {
{ "amount", NULL, OFFSET(amount), AV_OPT_TYPE_INT, { .i64 = 0 }, 0, INT_MAX, FLAGS },
{ "dropamount", NULL, OFFSET(dropamount), AV_OPT_TYPE_INT, { .i64 = 0 }, 0, INT_MAX, FLAGS },
{ NULL },
}

Definition at line 75 of file noise_bsf.c.

◆ noise_class

const AVClass noise_class
static
Initial value:
= {
.class_name = "noise",
.item_name = av_default_item_name,
.option = options,
}

Definition at line 81 of file noise_bsf.c.

◆ ff_noise_bsf

const AVBitStreamFilter ff_noise_bsf
Initial value:
= {
.name = "noise",
.priv_data_size = sizeof(NoiseContext),
.priv_class = &noise_class,
}

Definition at line 88 of file noise_bsf.c.

filter
filter_frame For filters that do not use the this method is called when a frame is pushed to the filter s input It can be called at any time except in a reentrant way If the input frame is enough to produce then the filter should push the output frames on the output link immediately As an exception to the previous rule if the input frame is enough to produce several output frames then the filter needs output only at least one per link The additional frames can be left buffered in the filter
Definition: filter_design.txt:228
FLAGS
#define FLAGS
Definition: noise_bsf.c:74
NoiseContext
Definition: noise_bsf.c:31
LIBAVUTIL_VERSION_INT
#define LIBAVUTIL_VERSION_INT
Definition: version.h:85
NULL
#define NULL
Definition: coverity.c:32
av_default_item_name
const char * av_default_item_name(void *ptr)
Return the context name.
Definition: log.c:191
OFFSET
#define OFFSET(x)
Definition: noise_bsf.c:73
noise
static int noise(AVBSFContext *ctx, AVPacket *pkt)
Definition: noise_bsf.c:38
AV_OPT_TYPE_INT
@ AV_OPT_TYPE_INT
Definition: opt.h:223
options
static const AVOption options[]
Definition: noise_bsf.c:75
noise_class
static const AVClass noise_class
Definition: noise_bsf.c:81