#include "libavutil/common.h"
#include "libavutil/pixdesc.h"
#include "libavutil/intreadwrite.h"
#include "avfilter.h"
#include "formats.h"
#include "internal.h"
#include "video.h"
Go to the source code of this file.
Data Structures | |
struct | HQDN3DContext |
Defines | |
#define | LUT_BITS (depth==16 ? 8 : 4) |
#define | LOAD(x) (((depth==8 ? src[x] : AV_RN16A(src+(x)*2)) << (16-depth)) + (((1<<(16-depth))-1)>>1)) |
#define | STORE(x, val) |
#define | denoise(...) |
#define | PARAM1_DEFAULT 4.0 |
#define | PARAM2_DEFAULT 3.0 |
#define | PARAM3_DEFAULT 6.0 |
Functions | |
void | ff_hqdn3d_row_8_x86 (uint8_t *src, uint8_t *dst, uint16_t *line_ant, uint16_t *frame_ant, ptrdiff_t w, int16_t *spatial, int16_t *temporal) |
void | ff_hqdn3d_row_9_x86 (uint8_t *src, uint8_t *dst, uint16_t *line_ant, uint16_t *frame_ant, ptrdiff_t w, int16_t *spatial, int16_t *temporal) |
void | ff_hqdn3d_row_10_x86 (uint8_t *src, uint8_t *dst, uint16_t *line_ant, uint16_t *frame_ant, ptrdiff_t w, int16_t *spatial, int16_t *temporal) |
void | ff_hqdn3d_row_16_x86 (uint8_t *src, uint8_t *dst, uint16_t *line_ant, uint16_t *frame_ant, ptrdiff_t w, int16_t *spatial, int16_t *temporal) |
static av_always_inline uint32_t | lowpass (int prev, int cur, int16_t *coef, int depth) |
static av_always_inline void | denoise_temporal (uint8_t *src, uint8_t *dst, uint16_t *frame_ant, int w, int h, int sstride, int dstride, int16_t *temporal, int depth) |
static av_always_inline void | denoise_spatial (HQDN3DContext *hqdn3d, uint8_t *src, uint8_t *dst, uint16_t *line_ant, uint16_t *frame_ant, int w, int h, int sstride, int dstride, int16_t *spatial, int16_t *temporal, int depth) |
static av_always_inline void | denoise_depth (HQDN3DContext *hqdn3d, uint8_t *src, uint8_t *dst, uint16_t *line_ant, uint16_t **frame_ant_ptr, int w, int h, int sstride, int dstride, int16_t *spatial, int16_t *temporal, int depth) |
static int16_t * | precalc_coefs (double dist25, int depth) |
static int | init (AVFilterContext *ctx, const char *args) |
static void | uninit (AVFilterContext *ctx) |
static int | query_formats (AVFilterContext *ctx) |
static int | config_input (AVFilterLink *inlink) |
static int | null_draw_slice (AVFilterLink *link, int y, int h, int slice_dir) |
static int | end_frame (AVFilterLink *inlink) |
Variables | |
AVFilter | avfilter_vf_hqdn3d |
Definition in file vf_hqdn3d.c.
#define denoise | ( | ... | ) |
Value:
switch (hqdn3d->depth) {\ case 8: denoise_depth(__VA_ARGS__, 8); break;\ case 9: denoise_depth(__VA_ARGS__, 9); break;\ case 10: denoise_depth(__VA_ARGS__, 10); break;\ case 16: denoise_depth(__VA_ARGS__, 16); break;\ }
Definition at line 159 of file vf_hqdn3d.c.
Referenced by end_frame().
#define LOAD | ( | x | ) | (((depth==8 ? src[x] : AV_RN16A(src+(x)*2)) << (16-depth)) + (((1<<(16-depth))-1)>>1)) |
Definition at line 53 of file vf_hqdn3d.c.
#define LUT_BITS (depth==16 ? 8 : 4) |
Definition at line 52 of file vf_hqdn3d.c.
#define PARAM1_DEFAULT 4.0 |
Definition at line 188 of file vf_hqdn3d.c.
#define PARAM2_DEFAULT 3.0 |
Definition at line 189 of file vf_hqdn3d.c.
#define PARAM3_DEFAULT 6.0 |
Definition at line 190 of file vf_hqdn3d.c.
#define STORE | ( | x, | |||
val | ) |
static int config_input | ( | AVFilterLink * | inlink | ) | [static] |
Definition at line 294 of file vf_hqdn3d.c.
static av_always_inline void denoise_depth | ( | HQDN3DContext * | hqdn3d, | |
uint8_t * | src, | |||
uint8_t * | dst, | |||
uint16_t * | line_ant, | |||
uint16_t ** | frame_ant_ptr, | |||
int | w, | |||
int | h, | |||
int | sstride, | |||
int | dstride, | |||
int16_t * | spatial, | |||
int16_t * | temporal, | |||
int | depth | |||
) | [static] |
Definition at line 131 of file vf_hqdn3d.c.
static int end_frame | ( | AVFilterLink * | inlink | ) | [static] |
Definition at line 328 of file vf_hqdn3d.c.
void ff_hqdn3d_row_10_x86 | ( | uint8_t * | src, | |
uint8_t * | dst, | |||
uint16_t * | line_ant, | |||
uint16_t * | frame_ant, | |||
ptrdiff_t | w, | |||
int16_t * | spatial, | |||
int16_t * | temporal | |||
) |
Referenced by config_input().
void ff_hqdn3d_row_16_x86 | ( | uint8_t * | src, | |
uint8_t * | dst, | |||
uint16_t * | line_ant, | |||
uint16_t * | frame_ant, | |||
ptrdiff_t | w, | |||
int16_t * | spatial, | |||
int16_t * | temporal | |||
) |
Referenced by config_input().
void ff_hqdn3d_row_8_x86 | ( | uint8_t * | src, | |
uint8_t * | dst, | |||
uint16_t * | line_ant, | |||
uint16_t * | frame_ant, | |||
ptrdiff_t | w, | |||
int16_t * | spatial, | |||
int16_t * | temporal | |||
) |
Referenced by config_input().
void ff_hqdn3d_row_9_x86 | ( | uint8_t * | src, | |
uint8_t * | dst, | |||
uint16_t * | line_ant, | |||
uint16_t * | frame_ant, | |||
ptrdiff_t | w, | |||
int16_t * | spatial, | |||
int16_t * | temporal | |||
) |
Referenced by config_input().
static int init | ( | AVFilterContext * | ctx, | |
const char * | args | |||
) | [static] |
Definition at line 192 of file vf_hqdn3d.c.
static int null_draw_slice | ( | AVFilterLink * | link, | |
int | y, | |||
int | h, | |||
int | slice_dir | |||
) | [static] |
Definition at line 323 of file vf_hqdn3d.c.
static int query_formats | ( | AVFilterContext * | ctx | ) | [static] |
Definition at line 264 of file vf_hqdn3d.c.
static void uninit | ( | AVFilterContext * | ctx | ) | [static] |
Definition at line 250 of file vf_hqdn3d.c.
Initial value:
{ .name = "hqdn3d", .description = NULL_IF_CONFIG_SMALL("Apply a High Quality 3D Denoiser."), .priv_size = sizeof(HQDN3DContext), .init = init, .uninit = uninit, .query_formats = query_formats, .inputs = (const AVFilterPad[]) {{ .name = "default", .type = AVMEDIA_TYPE_VIDEO, .start_frame = ff_inplace_start_frame, .draw_slice = null_draw_slice, .config_props = config_input, .end_frame = end_frame }, { .name = NULL}}, .outputs = (const AVFilterPad[]) {{ .name = "default", .type = AVMEDIA_TYPE_VIDEO }, { .name = NULL}}, }
Definition at line 351 of file vf_hqdn3d.c.