FFmpeg
Data Structures | Enumerations | Functions | Variables
vf_alphamerge.c File Reference

copy an alpha component from another video's luma More...

#include <string.h>
#include "libavutil/imgutils.h"
#include "libavutil/opt.h"
#include "libavutil/pixfmt.h"
#include "avfilter.h"
#include "drawutils.h"
#include "formats.h"
#include "filters.h"
#include "framesync.h"
#include "internal.h"
#include "video.h"

Go to the source code of this file.

Data Structures

struct  AlphaMergeContext
 

Enumerations

enum  { Y, U, V, A }
 

Functions

static int do_alphamerge (FFFrameSync *fs)
 
static av_cold int init (AVFilterContext *ctx)
 
static int query_formats (AVFilterContext *ctx)
 
static int config_input_main (AVFilterLink *inlink)
 
static int config_output (AVFilterLink *outlink)
 
static int activate (AVFilterContext *ctx)
 
static av_cold void uninit (AVFilterContext *ctx)
 
 FRAMESYNC_DEFINE_CLASS (alphamerge, AlphaMergeContext, fs)
 

Variables

static const AVFilterPad alphamerge_inputs []
 
static const AVFilterPad alphamerge_outputs []
 
static const AVOption alphamerge_options []
 
AVFilter ff_vf_alphamerge
 

Detailed Description

copy an alpha component from another video's luma

Definition in file vf_alphamerge.c.

Enumeration Type Documentation

anonymous enum
Enumerator

Definition at line 39 of file vf_alphamerge.c.

Function Documentation

static int do_alphamerge ( FFFrameSync fs)
static

Definition at line 50 of file vf_alphamerge.c.

Referenced by init().

static av_cold int init ( AVFilterContext ctx)
static

Definition at line 86 of file vf_alphamerge.c.

static int query_formats ( AVFilterContext ctx)
static

Definition at line 94 of file vf_alphamerge.c.

static int config_input_main ( AVFilterLink inlink)
static

Definition at line 114 of file vf_alphamerge.c.

static int config_output ( AVFilterLink outlink)
static

Definition at line 123 of file vf_alphamerge.c.

static int activate ( AVFilterContext ctx)
static

Definition at line 151 of file vf_alphamerge.c.

static av_cold void uninit ( AVFilterContext ctx)
static

Definition at line 157 of file vf_alphamerge.c.

FRAMESYNC_DEFINE_CLASS ( alphamerge  ,
AlphaMergeContext  ,
fs   
)

Variable Documentation

const AVFilterPad alphamerge_inputs[]
static
Initial value:
= {
{
.name = "main",
.config_props = config_input_main,
},{
.name = "alpha",
},
{ NULL }
}
#define NULL
Definition: coverity.c:32
static int config_input_main(AVFilterLink *inlink)

Definition at line 164 of file vf_alphamerge.c.

const AVFilterPad alphamerge_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 176 of file vf_alphamerge.c.

const AVOption alphamerge_options[]
static
Initial value:
= {
{ NULL }
}
#define NULL
Definition: coverity.c:32

Definition at line 185 of file vf_alphamerge.c.

AVFilter ff_vf_alphamerge
Initial value:
= {
.name = "alphamerge",
.description = NULL_IF_CONFIG_SMALL("Copy the luma value of the second "
"input into the alpha channel of the first input."),
.preinit = alphamerge_framesync_preinit,
.priv_size = sizeof(AlphaMergeContext),
.priv_class = &alphamerge_class,
.init = init,
}
static const AVFilterPad alphamerge_inputs[]
static int activate(AVFilterContext *ctx)
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
Definition: internal.h:153
static int query_formats(AVFilterContext *ctx)
Definition: vf_alphamerge.c:94
static av_cold void uninit(AVFilterContext *ctx)
static const AVFilterPad alphamerge_outputs[]
static const AVFilterPad outputs[]
Definition: af_acontrast.c:203
these buffered frames must be flushed immediately if a new input produces new the filter must not call request_frame to get more It must just process the frame or queue it The task of requesting more frames is left to the filter s request_frame method or the application If a filter has several inputs
static av_cold int init(AVFilterContext *ctx)
Definition: vf_alphamerge.c:86
#define AVFILTER_FLAG_SUPPORT_TIMELINE_INTERNAL
Same as AVFILTER_FLAG_SUPPORT_TIMELINE_GENERIC, except that the filter will have its filter_frame() c...
Definition: avfilter.h:134
#define flags(name, subs,...)
Definition: cbs_av1.c:560

Definition at line 191 of file vf_alphamerge.c.