Commit abb3e4e9 authored by David Barker's avatar David Barker Committed by Debargha Mukherjee
Browse files

loop-restoration: Remove duplicated function

We currently have two implementations of the same function
(aom_memset16() and memset16()), one of which is only defined inside
restoration.c. Remove this duplicate, and use the globally defined
version instead.

Change-Id: I52740541f2e974f505728240127842397f6ef38d
parent da2eefc6
......@@ -1911,18 +1911,14 @@ int av1_loop_restoration_corners_in_sb(const struct AV1Common *cm, int plane,
static void memset16(uint16_t *arr, uint16_t val, int nelts) {
for (int i = 0; i < nelts; ++i) arr[i] = val;
// Extend to left and right
static void extend_lines(uint8_t *buf, int width, int height, int stride,
int extend, int use_highbitdepth) {
for (int i = 0; i < height; ++i) {
if (use_highbitdepth) {
uint16_t *buf16 = (uint16_t *)buf;
memset16(buf16 - extend, buf16[0], extend);
memset16(buf16 + width, buf16[width - 1], extend);
aom_memset16(buf16 - extend, buf16[0], extend);
aom_memset16(buf16 + width, buf16[width - 1], extend);
} else {
memset(buf - extend, buf[0], extend);
memset(buf + width, buf[width - 1], extend);
Supports Markdown
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