Commit 9716af45 authored by David Barker's avatar David Barker

Fix a bug in loopfiltering-across-tiles(-ext)

Commit https://aomedia-review.googlesource.com/c/aom/+/39985
changed the deblock filter for subsampled planes, so that
we always look at the bottom-right mi unit in each 8x8 luma
pixel unit. This fixed some issues around determining which
blocks are inter/skip/etc.

However, this introduced a different bug - the boundary info
("are we allowed to filter across the top/left edge of this block?")
is stored in the *top-left* mi unit in each 8x8 luma pixel unit.
But now we we're looking at the bottom-right unit, which always says
it's fine to filter across the top and left boundaries! Thus the
deblock filter effectively ignored the
loop_filter_across_tiles_enabled flag(s).

Fix this issue by looking up the boundary info from the top-left
block in each unit; the other information is still taken from
the bottom-right.

Change-Id: I626ea3358563641a2532ee9c5968fb54bdc78e34
parent 2537bfc5
......@@ -2091,8 +2091,14 @@ static void set_lpf_parameters(
// prepare outer edge parameters. deblock the edge if it's an edge of a TU
if (coord) {
#if CONFIG_LOOPFILTERING_ACROSS_TILES || CONFIG_LOOPFILTERING_ACROSS_TILES_EXT
MODE_INFO *const mi_bound = cm->mi + mi_row * cm->mi_stride + mi_col;
// here, assuming bounfary_info is set correctly based on the
// Note: For sub8x8 blocks, we need to look at the top-left mi unit in
// order
// to extract the correct boundary information.
const int mi_row_bound = ((y << scale_vert) >> MI_SIZE_LOG2);
const int mi_col_bound = ((x << scale_horz) >> MI_SIZE_LOG2);
MODE_INFO *const mi_bound =
cm->mi + mi_row_bound * cm->mi_stride + mi_col_bound;
// here, assuming boundary_info is set correctly based on the
// loop_filter_across_tiles_enabled flag, i.e, tile boundary should
// only be set to true when this flag is set to 0.
int left_boundary = (mi_bound->mbmi.boundary_info & TILE_LEFT_BOUNDARY);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment