FFmpeg
Macros | Functions | Variables
yadif_common.c File Reference
#include "libavutil/avassert.h"
#include "libavutil/imgutils.h"
#include "filters.h"
#include "video.h"
#include "yadif.h"

Go to the source code of this file.

Macros

#define OFFSET(x)   offsetof(YADIFContext, x)
 
#define FLAGS   AV_OPT_FLAG_VIDEO_PARAM|AV_OPT_FLAG_FILTERING_PARAM
 
#define CONST(name, help, val, u)   { name, help, 0, AV_OPT_TYPE_CONST, {.i64=val}, INT_MIN, INT_MAX, FLAGS, .unit = u }
 

Functions

static int return_frame (AVFilterContext *ctx, int is_second)
 
static int checkstride (YADIFContext *yadif, const AVFrame *a, const AVFrame *b)
 
static void fixstride (AVFilterLink *link, AVFrame *f)
 
int ff_yadif_filter_frame (AVFilterLink *link, AVFrame *frame)
 
int ff_yadif_request_frame (AVFilterLink *link)
 
int ff_yadif_config_output_common (AVFilterLink *outlink)
 
void ff_yadif_uninit (AVFilterContext *ctx)
 

Variables

const AVOption ff_yadif_options []
 

Macro Definition Documentation

◆ OFFSET

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

Definition at line 268 of file yadif_common.c.

◆ FLAGS

Definition at line 269 of file yadif_common.c.

◆ CONST

#define CONST (   name,
  help,
  val,
  u 
)    { name, help, 0, AV_OPT_TYPE_CONST, {.i64=val}, INT_MIN, INT_MAX, FLAGS, .unit = u }

Definition at line 271 of file yadif_common.c.

Function Documentation

◆ return_frame()

static int return_frame ( AVFilterContext ctx,
int  is_second 
)
static

Definition at line 28 of file yadif_common.c.

Referenced by ff_yadif_filter_frame(), and ff_yadif_request_frame().

◆ checkstride()

static int checkstride ( YADIFContext yadif,
const AVFrame a,
const AVFrame b 
)
static

Definition at line 81 of file yadif_common.c.

Referenced by ff_yadif_filter_frame().

◆ fixstride()

static void fixstride ( AVFilterLink link,
AVFrame f 
)
static

Definition at line 90 of file yadif_common.c.

Referenced by ff_yadif_filter_frame().

◆ ff_yadif_filter_frame()

int ff_yadif_filter_frame ( AVFilterLink link,
AVFrame frame 
)

Definition at line 104 of file yadif_common.c.

Referenced by ff_yadif_request_frame().

◆ ff_yadif_request_frame()

int ff_yadif_request_frame ( AVFilterLink link)

Definition at line 184 of file yadif_common.c.

◆ ff_yadif_config_output_common()

int ff_yadif_config_output_common ( AVFilterLink outlink)

Definition at line 218 of file yadif_common.c.

Referenced by bwdif_vulkan_config_output(), config_output(), and config_props().

◆ ff_yadif_uninit()

void ff_yadif_uninit ( AVFilterContext ctx)

Definition at line 258 of file yadif_common.c.

Referenced by bwdif_vulkan_uninit(), and deint_cuda_uninit().

Variable Documentation

◆ ff_yadif_options

const AVOption ff_yadif_options[]
Initial value:
= {
{ "mode", "specify the interlacing mode", OFFSET(mode), AV_OPT_TYPE_INT, {.i64=YADIF_MODE_SEND_FRAME}, 0, 3, FLAGS, .unit = "mode"},
CONST("send_frame", "send one frame for each frame", YADIF_MODE_SEND_FRAME, "mode"),
CONST("send_field", "send one frame for each field", YADIF_MODE_SEND_FIELD, "mode"),
CONST("send_frame_nospatial", "send one frame for each frame, but skip spatial interlacing check", YADIF_MODE_SEND_FRAME_NOSPATIAL, "mode"),
CONST("send_field_nospatial", "send one frame for each field, but skip spatial interlacing check", YADIF_MODE_SEND_FIELD_NOSPATIAL, "mode"),
{ "parity", "specify the assumed picture field parity", OFFSET(parity), AV_OPT_TYPE_INT, {.i64=YADIF_PARITY_AUTO}, -1, 1, FLAGS, .unit = "parity" },
CONST("tff", "assume top field first", YADIF_PARITY_TFF, "parity"),
CONST("bff", "assume bottom field first", YADIF_PARITY_BFF, "parity"),
CONST("auto", "auto detect parity", YADIF_PARITY_AUTO, "parity"),
{ "deint", "specify which frames to deinterlace", OFFSET(deint), AV_OPT_TYPE_INT, {.i64=YADIF_DEINT_ALL}, 0, 1, FLAGS, .unit = "deint" },
CONST("all", "deinterlace all frames", YADIF_DEINT_ALL, "deint"),
CONST("interlaced", "only deinterlace frames marked as interlaced", YADIF_DEINT_INTERLACED, "deint"),
{ NULL }
}

Definition at line 273 of file yadif_common.c.

YADIF_MODE_SEND_FIELD
@ YADIF_MODE_SEND_FIELD
send 1 frame for each field
Definition: yadif.h:29
mode
Definition: swscale.c:52
FLAGS
#define FLAGS
Definition: yadif_common.c:269
YADIF_MODE_SEND_FRAME
@ YADIF_MODE_SEND_FRAME
send 1 frame for each frame
Definition: yadif.h:28
YADIF_MODE_SEND_FIELD_NOSPATIAL
@ YADIF_MODE_SEND_FIELD_NOSPATIAL
send 1 frame for each field but skips spatial interlacing check
Definition: yadif.h:31
YADIF_PARITY_AUTO
@ YADIF_PARITY_AUTO
auto detection
Definition: yadif.h:37
YADIF_MODE_SEND_FRAME_NOSPATIAL
@ YADIF_MODE_SEND_FRAME_NOSPATIAL
send 1 frame for each frame but skips spatial interlacing check
Definition: yadif.h:30
NULL
#define NULL
Definition: coverity.c:32
parity
mcdeint parity
Definition: vf_mcdeint.c:281
OFFSET
#define OFFSET(x)
Definition: yadif_common.c:268
YADIF_DEINT_ALL
@ YADIF_DEINT_ALL
deinterlace all frames
Definition: yadif.h:41
AV_OPT_TYPE_INT
@ AV_OPT_TYPE_INT
Underlying C type is int.
Definition: opt.h:259
YADIF_DEINT_INTERLACED
@ YADIF_DEINT_INTERLACED
only deinterlace frames marked as interlaced
Definition: yadif.h:42
YADIF_PARITY_TFF
@ YADIF_PARITY_TFF
top field first
Definition: yadif.h:35
CONST
#define CONST(name, help, val, u)
Definition: yadif_common.c:271
YADIF_PARITY_BFF
@ YADIF_PARITY_BFF
bottom field first
Definition: yadif.h:36