#include "libavutil/avstring.h"
#include "libavutil/eval.h"
#include "libavutil/opt.h"
#include "libavutil/pixdesc.h"
#include "avfilter.h"
#include "drawutils.h"
#include "internal.h"
Go to the source code of this file.
Data Structures | |
struct | FadeContext |
Defines | |
#define | R 0 |
#define | G 1 |
#define | B 2 |
#define | A 3 |
#define | Y 0 |
#define | U 1 |
#define | V 2 |
#define | OFFSET(x) offsetof(FadeContext, x) |
Functions | |
static const char * | fade_get_name (void *ctx) |
static av_cold int | init (AVFilterContext *ctx, const char *args, void *opaque) |
static av_cold void | uninit (AVFilterContext *ctx) |
static int | query_formats (AVFilterContext *ctx) |
static int | config_props (AVFilterLink *inlink) |
static void | fade_plane (int y, int h, int w, int fade_factor, int black_level, int black_level_scaled, uint8_t offset, uint8_t step, int bytes_per_plane, uint8_t *data, int line_size) |
static void | draw_slice (AVFilterLink *inlink, int y, int h, int slice_dir) |
static void | end_frame (AVFilterLink *inlink) |
Variables | |
static const AVOption | fade_options [] |
static const AVClass | fade_class |
static const enum PixelFormat | studio_level_pix_fmts [] |
static enum PixelFormat | alpha_pix_fmts [] |
AVFilter | avfilter_vf_fade |
Definition in file vf_fade.c.
#define OFFSET | ( | x | ) | offsetof(FadeContext, x) |
static int config_props | ( | AVFilterLink * | inlink | ) | [static] |
static void draw_slice | ( | AVFilterLink * | inlink, | |
int | y, | |||
int | h, | |||
int | slice_dir | |||
) | [static] |
static void end_frame | ( | AVFilterLink * | inlink | ) | [static] |
static void fade_plane | ( | int | y, | |
int | h, | |||
int | w, | |||
int | fade_factor, | |||
int | black_level, | |||
int | black_level_scaled, | |||
uint8_t | offset, | |||
uint8_t | step, | |||
int | bytes_per_plane, | |||
uint8_t * | data, | |||
int | line_size | |||
) | [static] |
static av_cold int init | ( | AVFilterContext * | ctx, | |
const char * | args, | |||
void * | opaque | |||
) | [static] |
static int query_formats | ( | AVFilterContext * | ctx | ) | [static] |
static av_cold void uninit | ( | AVFilterContext * | ctx | ) | [static] |
enum PixelFormat alpha_pix_fmts[] [static] |
Initial value:
Definition at line 175 of file vf_fade.c.
Referenced by config_input_main(), config_input_overlay(), and config_props().
Initial value:
{ .name = "fade", .description = NULL_IF_CONFIG_SMALL("Fade in/out input video."), .init = init, .uninit = uninit, .priv_size = sizeof(FadeContext), .query_formats = query_formats, .inputs = (const AVFilterPad[]) {{ .name = "default", .type = AVMEDIA_TYPE_VIDEO, .config_props = config_props, .get_video_buffer = avfilter_null_get_video_buffer, .start_frame = avfilter_null_start_frame, .draw_slice = draw_slice, .end_frame = end_frame, .min_perms = AV_PERM_READ | AV_PERM_WRITE, .rej_perms = AV_PERM_PRESERVE, }, { .name = NULL}}, .outputs = (const AVFilterPad[]) {{ .name = "default", .type = AVMEDIA_TYPE_VIDEO, }, { .name = NULL}}, }
const AVClass fade_class [static] |
Initial value:
{ "FadeContext", fade_get_name, fade_options }
const AVOption fade_options[] [static] |
Initial value:
{ { "type", "set the fade direction", OFFSET(type), AV_OPT_TYPE_STRING, {.str = "in" }, CHAR_MIN, CHAR_MAX }, { "t", "set the fade direction", OFFSET(type), AV_OPT_TYPE_STRING, {.str = "in" }, CHAR_MIN, CHAR_MAX }, { "start_frame", "set expression of frame to start fading", OFFSET(start_frame), AV_OPT_TYPE_INT, {.dbl = 0 }, 0, INT_MAX }, { "s", "set expression of frame to start fading", OFFSET(start_frame), AV_OPT_TYPE_INT, {.dbl = 0 }, 0, INT_MAX }, { "nb_frames", "set expression for fade duration in frames", OFFSET(nb_frames), AV_OPT_TYPE_INT, {.dbl = 25 }, 0, INT_MAX }, { "n", "set expression for fade duration in frames", OFFSET(nb_frames), AV_OPT_TYPE_INT, {.dbl = 25 }, 0, INT_MAX }, { "alpha", "fade alpha if it is available on the input", OFFSET(alpha), AV_OPT_TYPE_INT, {.dbl = 0 }, 0, 1 }, {NULL}, }
const enum PixelFormat studio_level_pix_fmts[] [static] |
Initial value:
{ PIX_FMT_YUV444P, PIX_FMT_YUV422P, PIX_FMT_YUV420P, PIX_FMT_YUV411P, PIX_FMT_YUV410P, PIX_FMT_YUV440P, PIX_FMT_NONE }
Definition at line 168 of file vf_fade.c.
Referenced by config_props().