gradfun debanding filter, ported from MPlayer libmpcodecs/vf_gradfun.c More...
#include "libavutil/imgutils.h"
#include "libavutil/cpu.h"
#include "libavutil/pixdesc.h"
#include "avfilter.h"
#include "gradfun.h"
Go to the source code of this file.
Functions | |
void | ff_gradfun_filter_line_c (uint8_t *dst, uint8_t *src, uint16_t *dc, int width, int thresh, const uint16_t *dithers) |
void | ff_gradfun_blur_line_c (uint16_t *dc, uint16_t *buf, uint16_t *buf1, uint8_t *src, int src_linesize, int width) |
static void | filter (GradFunContext *ctx, uint8_t *dst, uint8_t *src, int width, int height, int dst_linesize, int src_linesize, int r) |
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_input (AVFilterLink *inlink) |
static void | start_frame (AVFilterLink *inlink, AVFilterBufferRef *inpicref) |
static void | null_draw_slice (AVFilterLink *link, int y, int h, int slice_dir) |
static void | end_frame (AVFilterLink *inlink) |
Variables | |
static const uint16_t | dither [8][8] |
AVFilter | avfilter_vf_gradfun |
gradfun debanding filter, ported from MPlayer libmpcodecs/vf_gradfun.c
Apply a boxblur debanding algorithm (based on the gradfun2db Avisynth filter by prunedtree). Foreach pixel, if it's within threshold of the blurred value, make it closer. So now we have a smoothed and higher bitdepth version of all the shallow gradients, while leaving detailed areas untouched. Dither it back to 8bit.
Definition in file vf_gradfun.c.
|
static |
Definition at line 169 of file vf_gradfun.c.
|
static |
Definition at line 205 of file vf_gradfun.c.
void ff_gradfun_blur_line_c | ( | uint16_t * | dc, |
uint16_t * | buf, | ||
uint16_t * | buf1, | ||
uint8_t * | src, | ||
int | src_linesize, | ||
int | width | ||
) |
Definition at line 66 of file vf_gradfun.c.
Referenced by init().
void ff_gradfun_filter_line_c | ( | uint8_t * | dst, |
uint8_t * | src, | ||
uint16_t * | dc, | ||
int | width, | ||
int | thresh, | ||
const uint16_t * | dithers | ||
) |
Definition at line 52 of file vf_gradfun.c.
Referenced by ff_gradfun_filter_line_mmx2(), ff_gradfun_filter_line_ssse3(), and init().
|
static |
Definition at line 77 of file vf_gradfun.c.
Referenced by end_frame().
|
static |
Definition at line 119 of file vf_gradfun.c.
|
static |
Definition at line 203 of file vf_gradfun.c.
|
static |
Definition at line 154 of file vf_gradfun.c.
|
static |
Definition at line 186 of file vf_gradfun.c.
|
static |
Definition at line 148 of file vf_gradfun.c.
AVFilter avfilter_vf_gradfun |
Definition at line 236 of file vf_gradfun.c.
|
static |
Definition at line 41 of file vf_gradfun.c.
Referenced by ac3_decode_transform_coeffs_ch(), filter(), render_charset(), and rv40_loop_filter().