From 1da94f20855c20571856ef09d8872c42e522a713 Mon Sep 17 00:00:00 2001 From: Ari Koivula Date: Fri, 16 May 2014 05:17:53 +0300 Subject: [PATCH] Stop deblocking from filtering edges not on 8x8 grid. --- src/filter.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/filter.c b/src/filter.c index f3e6b20e..41c9dd38 100644 --- a/src/filter.c +++ b/src/filter.c @@ -401,10 +401,10 @@ void filter_deblock_cu(encoder_state * const encoder_state, int32_t x, int32_t y uint8_t border = border_x | border_y; // are we in any border CU? // split 64x64, on split flag and on border - if (depth == 0 || split_flag || border || tr_split) { + if (depth < MAX_DEPTH && (depth == 0 || split_flag || border || tr_split)) { // Split the four sub-blocks of this block recursively. uint8_t change; - assert(depth >= 0 && depth < MAX_DEPTH); // for clang-analyzer + assert(depth >= 0); // for clang-analyzer change = 1 << (MAX_DEPTH - 1 - depth); filter_deblock_cu(encoder_state, x, y, depth + 1, edge);