FFmpeg  4.0
Data Structures | Macros | Functions | Variables
vf_entropy.c File Reference
#include "libavutil/imgutils.h"
#include "libavutil/opt.h"
#include "libavutil/pixdesc.h"
#include "avfilter.h"
#include "drawutils.h"
#include "formats.h"
#include "internal.h"
#include "video.h"

Go to the source code of this file.

Data Structures

struct  EntropyContext
 

Macros

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

Functions

 AVFILTER_DEFINE_CLASS (entropy)
 
static int query_formats (AVFilterContext *ctx)
 
static int config_input (AVFilterLink *inlink)
 
static int filter_frame (AVFilterLink *inlink, AVFrame *in)
 
static av_cold void uninit (AVFilterContext *ctx)
 

Variables

static const AVOption entropy_options []
 
static const AVFilterPad inputs []
 
static const AVFilterPad outputs []
 
AVFilter ff_vf_entropy
 

Macro Definition Documentation

◆ OFFSET

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

Definition at line 45 of file vf_entropy.c.

◆ FLAGS

Definition at line 46 of file vf_entropy.c.

Function Documentation

◆ AVFILTER_DEFINE_CLASS()

AVFILTER_DEFINE_CLASS ( entropy  )

◆ query_formats()

static int query_formats ( AVFilterContext ctx)
static

Definition at line 56 of file vf_entropy.c.

◆ config_input()

static int config_input ( AVFilterLink inlink)
static

Definition at line 82 of file vf_entropy.c.

◆ filter_frame()

static int filter_frame ( AVFilterLink inlink,
AVFrame in 
)
static

Definition at line 110 of file vf_entropy.c.

◆ uninit()

static av_cold void uninit ( AVFilterContext ctx)
static

Definition at line 171 of file vf_entropy.c.

Variable Documentation

◆ entropy_options

const AVOption entropy_options[]
static
Initial value:
= {
{ "mode", "set kind of histogram entropy measurement", OFFSET(mode), AV_OPT_TYPE_INT, {.i64=0}, 0, 1, FLAGS, "mode" },
{ "normal", NULL, 0, AV_OPT_TYPE_CONST, {.i64=0}, 0, 0, FLAGS, "mode" },
{ "diff", NULL, 0, AV_OPT_TYPE_CONST, {.i64=1}, 0, 0, FLAGS, "mode" },
{ NULL }
}
#define NULL
Definition: coverity.c:32
#define FLAGS
Definition: vf_entropy.c:46
#define OFFSET(x)
Definition: vf_entropy.c:45
mode
Use these values in ebur128_init (or'ed).
Definition: ebur128.h:83

Definition at line 47 of file vf_entropy.c.

◆ inputs

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

Definition at line 178 of file vf_entropy.c.

◆ outputs

const AVFilterPad outputs[]
static
Initial value:
= {
{
.name = "default",
},
{ NULL }
}
#define NULL
Definition: coverity.c:32

Definition at line 188 of file vf_entropy.c.

◆ ff_vf_entropy

AVFilter ff_vf_entropy
Initial value:
= {
.name = "entropy",
.description = NULL_IF_CONFIG_SMALL("Measure video frames entropy."),
.priv_size = sizeof(EntropyContext),
.priv_class = &entropy_class,
}
#define AVFILTER_FLAG_SUPPORT_TIMELINE_GENERIC
Some filters support a generic "enable" expression option that can be used to enable or disable a fil...
Definition: avfilter.h:125
static int flags
Definition: log.c:55
static const AVFilterPad inputs[]
Definition: vf_entropy.c:178
#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: vf_entropy.c:56
static av_cold void uninit(AVFilterContext *ctx)
Definition: vf_entropy.c:171
static const AVFilterPad outputs[]
Definition: vf_entropy.c:188

Definition at line 196 of file vf_entropy.c.