FFmpeg
|
#include "libavutil/imgutils.h"
#include "libavutil/eval.h"
#include "libavutil/opt.h"
#include "libavutil/pixfmt.h"
#include "avfilter.h"
#include "bufferqueue.h"
#include "formats.h"
#include "internal.h"
#include "video.h"
Go to the source code of this file.
Data Structures | |
struct | FilterParams |
filter data More... | |
struct | BlendContext |
Macros | |
#define | TOP 0 |
#define | BOTTOM 1 |
#define | OFFSET(x) offsetof(BlendContext, x) |
#define | FLAGS AV_OPT_FLAG_FILTERING_PARAM|AV_OPT_FLAG_VIDEO_PARAM |
#define | DEFINE_BLEND(name, expr) |
#define | A top[j] |
#define | B bottom[j] |
#define | MULTIPLY(x, a, b) (x * ((a * b) / 255)) |
#define | SCREEN(x, a, b) (255 - x * ((255 - a) * (255 - b) / 255)) |
#define | BURN(a, b) ((a == 0) ? a : FFMAX(0, 255 - ((255 - b) << 8) / a)) |
#define | DODGE(a, b) ((a == 255) ? a : FFMIN(255, ((b << 8) / (255 - a)))) |
Enumerations | |
enum | BlendMode { BLEND_UNSET = -1, BLEND_NORMAL, BLEND_ADDITION, BLEND_AND, BLEND_AVERAGE, BLEND_BURN, BLEND_DARKEN, BLEND_DIFFERENCE, BLEND_DIVIDE, BLEND_DODGE, BLEND_EXCLUSION, BLEND_HARDLIGHT, BLEND_LIGHTEN, BLEND_MULTIPLY, BLEND_NEGATION, BLEND_OR, BLEND_OVERLAY, BLEND_PHOENIX, BLEND_PINLIGHT, BLEND_REFLECT, BLEND_SCREEN, BLEND_SOFTLIGHT, BLEND_SUBTRACT, BLEND_VIVIDLIGHT, BLEND_XOR, BLEND_NB } |
enum | { VAR_X, VAR_Y, VAR_W, VAR_H, VAR_SW, VAR_SH, VAR_T, VAR_A, VAR_B, VAR_TOP, VAR_BOTTOM, VAR_VARS_NB } |
Functions | |
AVFILTER_DEFINE_CLASS (blend) | |
static void | blend_normal (const uint8_t *top, int top_linesize, const uint8_t *bottom, int bottom_linesize, uint8_t *dst, int dst_linesize, int width, int height, FilterParams *param) |
DEFINE_BLEND (overlay,(A< 128)?MULTIPLY(2, A, B):SCREEN(2, A, B)) | |
static av_cold int | init (AVFilterContext *ctx, const char *args) |
static int | query_formats (AVFilterContext *ctx) |
static int | config_output (AVFilterLink *outlink) |
static int | config_input_top (AVFilterLink *inlink) |
static av_cold void | uninit (AVFilterContext *ctx) |
static int | request_frame (AVFilterLink *outlink) |
static void | blend_frame (AVFilterContext *ctx, AVFilterBufferRef *top_buf, AVFilterBufferRef *bottom_buf, AVFilterBufferRef *dst_buf) |
static int | filter_frame (AVFilterLink *inlink, AVFilterBufferRef *buf) |
Variables | |
static const char *const | var_names [] = { "X", "Y", "W", "H", "SW", "SH", "T", "A", "B", "TOP", "BOTTOM", NULL } |
static const AVOption | blend_options [] |
static const AVFilterPad | blend_inputs [] |
static const AVFilterPad | blend_outputs [] |
AVFilter | avfilter_vf_blend |
#define TOP 0 |
Definition at line 31 of file vf_blend.c.
Referenced by config_output(), decode_pixel_in_context(), filter_frame(), mss4_decode_dct(), mss4_decode_dct_block(), mss4_update_dc_cache(), and request_frame().
#define BOTTOM 1 |
Definition at line 32 of file vf_blend.c.
Referenced by config_output(), filter_frame(), and request_frame().
#define OFFSET | ( | x | ) | offsetof(BlendContext, x) |
Definition at line 91 of file vf_blend.c.
#define FLAGS AV_OPT_FLAG_FILTERING_PARAM|AV_OPT_FLAG_VIDEO_PARAM |
Definition at line 92 of file vf_blend.c.
#define DEFINE_BLEND | ( | name, | |
expr | |||
) |
Definition at line 147 of file vf_blend.c.
#define A top[j] |
Definition at line 166 of file vf_blend.c.
#define B bottom[j] |
Definition at line 167 of file vf_blend.c.
Definition at line 170 of file vf_blend.c.
Definition at line 171 of file vf_blend.c.
Definition at line 172 of file vf_blend.c.
enum BlendMode |
Definition at line 34 of file vf_blend.c.
anonymous enum |
Definition at line 64 of file vf_blend.c.
AVFILTER_DEFINE_CLASS | ( | blend | ) |
|
static |
Definition at line 139 of file vf_blend.c.
Referenced by init().
Definition at line 181 of file vf_blend.c.
|
static |
Definition at line 222 of file vf_blend.c.
|
static |
Definition at line 285 of file vf_blend.c.
|
static |
Definition at line 297 of file vf_blend.c.
|
static |
Definition at line 331 of file vf_blend.c.
|
static |
Definition at line 341 of file vf_blend.c.
|
static |
Definition at line 354 of file vf_blend.c.
|
static |
Definition at line 370 of file vf_blend.c.
Referenced by filter_frame().
|
static |
Definition at line 401 of file vf_blend.c.
|
static |
Definition at line 63 of file vf_blend.c.
Referenced by init().
|
static |
Definition at line 94 of file vf_blend.c.
|
static |
Definition at line 438 of file vf_blend.c.
|
static |
Definition at line 454 of file vf_blend.c.
AVFilter avfilter_vf_blend |
Definition at line 464 of file vf_blend.c.