12 #ifndef AOM_AV1_COMMON_AV1_LOOPFILTER_H_
13 #define AOM_AV1_COMMON_AV1_LOOPFILTER_H_
15 #include "config/aom_config.h"
17 #include "aom_ports/mem.h"
18 #include "av1/common/blockd.h"
19 #include "av1/common/seg_common.h"
25 #define MAX_LOOP_FILTER 63
26 #define MAX_SHARPNESS 7
37 enum { VERT_EDGE = 0, HORZ_EDGE = 1, NUM_EDGE_DIRS } UENUM1BYTE(EDGE_DIR);
49 uint8_t mode_ref_delta_enabled;
50 uint8_t mode_ref_delta_update;
54 int8_t ref_deltas[REF_FRAMES];
57 int8_t mode_deltas[MAX_MODE_LF_DELTAS];
63 DECLARE_ALIGNED(SIMD_WIDTH, uint8_t, mblim[SIMD_WIDTH]);
64 DECLARE_ALIGNED(SIMD_WIDTH, uint8_t, lim[SIMD_WIDTH]);
65 DECLARE_ALIGNED(SIMD_WIDTH, uint8_t, hev_thr[SIMD_WIDTH]);
69 loop_filter_thresh lfthr[MAX_LOOP_FILTER + 1];
70 uint8_t lvl[MAX_MB_PLANE][MAX_SEGMENTS][2][REF_FRAMES][MAX_MODE_LF_DELTAS];
73 typedef struct LoopFilterWorkerData {
76 struct macroblockd_plane planes[MAX_MB_PLANE];
88 void av1_loop_filter_init(
struct AV1Common *cm);
90 void av1_loop_filter_frame_init(
struct AV1Common *cm,
int plane_start,
93 void av1_filter_block_plane_vert(
const struct AV1Common *
const cm,
95 const MACROBLOCKD_PLANE *
const plane_ptr,
96 const uint32_t mi_row,
const uint32_t mi_col);
98 void av1_filter_block_plane_horz(
const struct AV1Common *
const cm,
100 const MACROBLOCKD_PLANE *
const plane_ptr,
101 const uint32_t mi_row,
const uint32_t mi_col);
103 void av1_filter_block_plane_vert_rt(
const struct AV1Common *
const cm,
106 const MACROBLOCKD_PLANE *
const plane_ptr,
107 const uint32_t mi_row,
108 const uint32_t mi_col);
110 void av1_filter_block_plane_horz_rt(
const struct AV1Common *
const cm,
113 const MACROBLOCKD_PLANE *
const plane_ptr,
114 const uint32_t mi_row,
115 const uint32_t mi_col);
117 uint8_t av1_get_filter_level(
const struct AV1Common *cm,
118 const loop_filter_info_n *lfi_n,
const int dir_idx,
Top level common structure used by both encoder and decoder.
Definition: av1_common_int.h:755
Stores the prediction/txfm mode of the current coding block.
Definition: blockd.h:222
Variables related to current coding block.
Definition: blockd.h:577
YV12 frame buffer data structure.
Definition: yv12config.h:39