Commit cff43bb2 authored by David Barker's avatar David Barker

Fix a bug in the C selfguided filter

Patch https://aomedia-review.googlesource.com/c/8321/ introduced
a bug in the C version of the self-guided filter in the case where
w = 384 and h > 368 or w > 368 and h = 384. This was due to forgetting
to adjust the offset between A and B in the C code.

This patch sets the offset correctly, resolving this bug.

Change-Id: I6bdf11aa76c37d0ecae02788b262e7a2e0a11a6e
parent 5765fad5
......@@ -615,7 +615,7 @@ void av1_selfguided_restoration(int32_t *dgd, int width, int height, int stride,
int bit_depth, int r, int eps,
int32_t *tmpbuf) {
int32_t *A = tmpbuf;
int32_t *B = A + RESTORATION_TILEPELS_MAX;
int32_t *B = A + SGRPROJ_OUTBUF_SIZE;
int8_t num[RESTORATION_TILEPELS_MAX];
int i, j;
// Adjusting the stride of A and B here appears to avoid bad cache effects,
......
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