FFmpeg
Data Structures | Macros | Functions | Variables
vf_telecine.c File Reference
#include "libavutil/avstring.h"
#include "libavutil/imgutils.h"
#include "libavutil/opt.h"
#include "libavutil/pixdesc.h"
#include "avfilter.h"
#include "filters.h"
#include "formats.h"
#include "video.h"

Go to the source code of this file.

Data Structures

struct  TelecineContext
 

Macros

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

Functions

 AVFILTER_DEFINE_CLASS (telecine)
 
static av_cold int init (AVFilterContext *ctx)
 
static int query_formats (const AVFilterContext *ctx, AVFilterFormatsConfig **cfg_in, AVFilterFormatsConfig **cfg_out)
 
static int config_input (AVFilterLink *inlink)
 
static int config_output (AVFilterLink *outlink)
 
static int filter_frame (AVFilterLink *inlink, AVFrame *inpicref)
 
static av_cold void uninit (AVFilterContext *ctx)
 

Variables

static const AVOption telecine_options []
 
static const AVFilterPad telecine_inputs []
 
static const AVFilterPad telecine_outputs []
 
const AVFilter ff_vf_telecine
 

Macro Definition Documentation

◆ OFFSET

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

Definition at line 56 of file vf_telecine.c.

◆ FLAGS

Definition at line 57 of file vf_telecine.c.

Function Documentation

◆ AVFILTER_DEFINE_CLASS()

AVFILTER_DEFINE_CLASS ( telecine  )

◆ init()

static av_cold int init ( AVFilterContext ctx)
static

Definition at line 71 of file vf_telecine.c.

◆ query_formats()

static int query_formats ( const AVFilterContext ctx,
AVFilterFormatsConfig **  cfg_in,
AVFilterFormatsConfig **  cfg_out 
)
static

Definition at line 102 of file vf_telecine.c.

◆ config_input()

static int config_input ( AVFilterLink inlink)
static

Definition at line 114 of file vf_telecine.c.

◆ config_output()

static int config_output ( AVFilterLink outlink)
static

Definition at line 140 of file vf_telecine.c.

◆ filter_frame()

static int filter_frame ( AVFilterLink inlink,
AVFrame inpicref 
)
static

Definition at line 168 of file vf_telecine.c.

◆ uninit()

static av_cold void uninit ( AVFilterContext ctx)
static

Definition at line 296 of file vf_telecine.c.

Variable Documentation

◆ telecine_options

const AVOption telecine_options[]
static
Initial value:
= {
{"first_field", "select first field", OFFSET(first_field), AV_OPT_TYPE_INT, {.i64=0}, 0, 1, FLAGS, .unit = "field"},
{"top", "select top field first", 0, AV_OPT_TYPE_CONST, {.i64=0}, 0, 0, FLAGS, .unit = "field"},
{"t", "select top field first", 0, AV_OPT_TYPE_CONST, {.i64=0}, 0, 0, FLAGS, .unit = "field"},
{"bottom", "select bottom field first", 0, AV_OPT_TYPE_CONST, {.i64=1}, 0, 0, FLAGS, .unit = "field"},
{"b", "select bottom field first", 0, AV_OPT_TYPE_CONST, {.i64=1}, 0, 0, FLAGS, .unit = "field"},
{"pattern", "pattern that describe for how many fields a frame is to be displayed", OFFSET(pattern), AV_OPT_TYPE_STRING, {.str="23"}, 0, 0, FLAGS},
{NULL}
}

Definition at line 59 of file vf_telecine.c.

◆ telecine_inputs

const AVFilterPad telecine_inputs[]
static
Initial value:
= {
{
.name = "default",
.filter_frame = filter_frame,
.config_props = config_input,
},
}

Definition at line 306 of file vf_telecine.c.

◆ telecine_outputs

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

Definition at line 315 of file vf_telecine.c.

◆ ff_vf_telecine

const AVFilter ff_vf_telecine
Initial value:
= {
.name = "telecine",
.description = NULL_IF_CONFIG_SMALL("Apply a telecine pattern."),
.priv_size = sizeof(TelecineContext),
.priv_class = &telecine_class,
.init = init,
}

Definition at line 323 of file vf_telecine.c.

FILTER_INPUTS
#define FILTER_INPUTS(array)
Definition: filters.h:262
filter_frame
static int filter_frame(AVFilterLink *inlink, AVFrame *inpicref)
Definition: vf_telecine.c:168
uninit
static av_cold void uninit(AVFilterContext *ctx)
Definition: vf_telecine.c:296
telecine_inputs
static const AVFilterPad telecine_inputs[]
Definition: vf_telecine.c:306
FILTER_OUTPUTS
#define FILTER_OUTPUTS(array)
Definition: filters.h:263
NULL
#define NULL
Definition: coverity.c:32
config_input
static int config_input(AVFilterLink *inlink)
Definition: vf_telecine.c:114
NULL_IF_CONFIG_SMALL
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification.
Definition: internal.h:94
TelecineContext
Definition: vf_telecine.c:36
FILTER_QUERY_FUNC2
#define FILTER_QUERY_FUNC2(func)
Definition: filters.h:239
OFFSET
#define OFFSET(x)
Definition: vf_telecine.c:56
telecine_outputs
static const AVFilterPad telecine_outputs[]
Definition: vf_telecine.c:315
query_formats
static int query_formats(const AVFilterContext *ctx, AVFilterFormatsConfig **cfg_in, AVFilterFormatsConfig **cfg_out)
Definition: vf_telecine.c:102
AV_OPT_TYPE_INT
@ AV_OPT_TYPE_INT
Underlying C type is int.
Definition: opt.h:259
init
static av_cold int init(AVFilterContext *ctx)
Definition: vf_telecine.c:71
AVMEDIA_TYPE_VIDEO
@ AVMEDIA_TYPE_VIDEO
Definition: avutil.h:201
config_output
static int config_output(AVFilterLink *outlink)
Definition: vf_telecine.c:140
AV_OPT_TYPE_STRING
@ AV_OPT_TYPE_STRING
Underlying C type is a uint8_t* that is either NULL or points to a C string allocated with the av_mal...
Definition: opt.h:276
first_field
static int first_field(const struct video_data *s)
Definition: v4l2.c:256
AV_OPT_TYPE_CONST
@ AV_OPT_TYPE_CONST
Special option type for declaring named constants.
Definition: opt.h:299
FLAGS
#define FLAGS
Definition: vf_telecine.c:57