Go to the source code of this file.
|
static int | comp (const float *a, const float *b) |
|
| AVFILTER_DEFINE_CLASS (blurdetect) |
|
static av_cold int | blurdetect_init (AVFilterContext *ctx) |
|
static int | blurdetect_config_input (AVFilterLink *inlink) |
|
static float | edge_width (BLRContext *blr, int i, int j, int8_t dir, int w, int h, int edge, const uint8_t *src, int src_linesize) |
|
static float | calculate_blur (BLRContext *s, int w, int h, int hsub, int vsub, int8_t *dir, int dir_linesize, uint8_t *dst, int dst_linesize, uint8_t *src, int src_linesize) |
|
static void | set_meta (AVDictionary **metadata, const char *key, float d) |
|
static int | blurdetect_filter_frame (AVFilterLink *inlink, AVFrame *in) |
|
static av_cold void | blurdetect_uninit (AVFilterContext *ctx) |
|
No-reference blurdetect filter
Implementing: Marziliano, Pina, et al. "A no-reference perceptual blur metric." Proceedings. International conference on image processing. Vol. 3. IEEE, 2002. https://infoscience.epfl.ch/record/111802/files/14%20A%20no-reference%20perceptual%20blur%20metric.pdf
- Author
- Thilo Borgmann <thilo.borgmann at mail.de>
Definition in file vf_blurdetect.c.
◆ OFFSET
◆ FLAGS
◆ comp()
◆ AVFILTER_DEFINE_CLASS()
AVFILTER_DEFINE_CLASS |
( |
blurdetect |
| ) |
|
◆ blurdetect_init()
◆ blurdetect_config_input()
◆ edge_width()
◆ calculate_blur()
static float calculate_blur |
( |
BLRContext * |
s, |
|
|
int |
w, |
|
|
int |
h, |
|
|
int |
hsub, |
|
|
int |
vsub, |
|
|
int8_t * |
dir, |
|
|
int |
dir_linesize, |
|
|
uint8_t * |
dst, |
|
|
int |
dst_linesize, |
|
|
uint8_t * |
src, |
|
|
int |
src_linesize |
|
) |
| |
|
static |
◆ set_meta()
◆ blurdetect_filter_frame()
◆ blurdetect_uninit()
◆ blurdetect_options
Initial value:= {
{
"block_pct",
"block pooling threshold when calculating blurriness",
OFFSET(block_pct),
AV_OPT_TYPE_INT, {.i64=80}, 1, 100,
FLAGS },
{
"block_width",
"block size for block-based abbreviation of blurriness",
OFFSET(block_width),
AV_OPT_TYPE_INT, {.i64=-1}, -1, INT_MAX,
FLAGS },
{
"block_height",
"block size for block-based abbreviation of blurriness",
OFFSET(block_height),
AV_OPT_TYPE_INT, {.i64=-1}, -1, INT_MAX,
FLAGS },
}
Definition at line 71 of file vf_blurdetect.c.
◆ pix_fmts
◆ blurdetect_inputs
Initial value:= {
{
.name = "default",
},
}
Definition at line 351 of file vf_blurdetect.c.
◆ ff_vf_blurdetect
Initial value:= {
.name = "blurdetect",
.priv_class = &blurdetect_class,
}
Definition at line 360 of file vf_blurdetect.c.
#define FILTER_PIXFMTS_ARRAY(array)
static av_cold int blurdetect_init(AVFilterContext *ctx)
@ AV_PIX_FMT_YUV440P
planar YUV 4:4:0 (1 Cr & Cb sample per 1x2 Y samples)
static enum AVPixelFormat pix_fmts[]
@ AV_PIX_FMT_GBRAP
planar GBRA 4:4:4:4 32bpp
@ AV_PIX_FMT_YUVJ411P
planar YUV 4:1:1, 12bpp, (1 Cr & Cb sample per 4x1 Y samples) full scale (JPEG), deprecated in favor ...
const AVFilterPad ff_video_default_filterpad[1]
An AVFilterPad array whose only entry has name "default" and is of type AVMEDIA_TYPE_VIDEO.
@ AV_PIX_FMT_YUVJ422P
planar YUV 4:2:2, 16bpp, full scale (JPEG), deprecated in favor of AV_PIX_FMT_YUV422P and setting col...
@ AV_PIX_FMT_YUVA420P
planar YUV 4:2:0, 20bpp, (1 Cr & Cb sample per 2x2 Y & A samples)
@ AV_PIX_FMT_YUV420P
planar YUV 4:2:0, 12bpp, (1 Cr & Cb sample per 2x2 Y samples)
#define FILTER_INPUTS(array)
@ AV_PIX_FMT_YUVJ444P
planar YUV 4:4:4, 24bpp, full scale (JPEG), deprecated in favor of AV_PIX_FMT_YUV444P and setting col...
@ AV_PIX_FMT_YUVJ420P
planar YUV 4:2:0, 12bpp, full scale (JPEG), deprecated in favor of AV_PIX_FMT_YUV420P and setting col...
static av_cold void blurdetect_uninit(AVFilterContext *ctx)
@ AV_PIX_FMT_GRAY8
Y , 8bpp.
int(* init)(AVBSFContext *ctx)
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification.
@ AV_PIX_FMT_YUVA444P
planar YUV 4:4:4 32bpp, (1 Cr & Cb sample per 1x1 Y & A samples)
static void uninit(AVBSFContext *ctx)
@ AV_PIX_FMT_YUVJ440P
planar YUV 4:4:0 full scale (JPEG), deprecated in favor of AV_PIX_FMT_YUV440P and setting color_range
static const AVFilterPad blurdetect_inputs[]
static int blurdetect_filter_frame(AVFilterLink *inlink, AVFrame *in)
#define AVFILTER_FLAG_METADATA_ONLY
The filter is a "metadata" filter - it does not modify the frame data in any way.
@ AV_PIX_FMT_YUV444P
planar YUV 4:4:4, 24bpp, (1 Cr & Cb sample per 1x1 Y samples)
@ AV_PIX_FMT_GBRP
planar GBR 4:4:4 24bpp
@ AV_PIX_FMT_YUV422P
planar YUV 4:2:2, 16bpp, (1 Cr & Cb sample per 2x1 Y samples)
static const struct @386 planes[]
#define FILTER_OUTPUTS(array)
@ AV_PIX_FMT_YUV411P
planar YUV 4:1:1, 12bpp, (1 Cr & Cb sample per 4x1 Y samples)
static int blurdetect_config_input(AVFilterLink *inlink)
@ AV_PIX_FMT_YUV410P
planar YUV 4:1:0, 9bpp, (1 Cr & Cb sample per 4x4 Y samples)
@ AV_PIX_FMT_YUVA422P
planar YUV 4:2:2 24bpp, (1 Cr & Cb sample per 2x1 Y & A samples)