Renaming deringing blockwise write-back functions to make code clearer
No change in output.
Change-Id: Ifa5df3adce9f24ef6dcd89a5f33a744bfb57194d
diff --git a/av1/common/dering.c b/av1/common/dering.c
index ba59199..2b99ac8 100644
--- a/av1/common/dering.c
+++ b/av1/common/dering.c
@@ -72,14 +72,14 @@
return count;
}
-static INLINE void copy_8x8_16_8bit(uint8_t *dst, int dstride, int16_t *src, int sstride) {
+static INLINE void copy_8x8_16bit_to_8bit(uint8_t *dst, int dstride, int16_t *src, int sstride) {
int i, j;
for (i = 0; i < 8; i++)
for (j = 0; j < 8; j++)
dst[i * dstride + j] = src[i * sstride + j];
}
-static INLINE void copy_4x4_16_8bit(uint8_t *dst, int dstride, int16_t *src, int sstride) {
+static INLINE void copy_4x4_16bit_to_8bit(uint8_t *dst, int dstride, int16_t *src, int sstride) {
int i, j;
for (i = 0; i < 4; i++)
for (j = 0; j < 4; j++)
@@ -87,7 +87,7 @@
}
/* TODO: Optimize this function for SSE. */
-void copy_blocks_16_8bit(uint8_t *dst, int dstride, int16_t *src,
+void copy_dering_16bit_to_8bit(uint8_t *dst, int dstride, int16_t *src,
dering_list *dlist, int dering_count, int bsize)
{
int bi, bx, by;
@@ -95,7 +95,7 @@
for (bi = 0; bi < dering_count; bi++) {
by = dlist[bi].by;
bx = dlist[bi].bx;
- copy_8x8_16_8bit(&dst[(by << 3) * dstride + (bx << 3)],
+ copy_8x8_16bit_to_8bit(&dst[(by << 3) * dstride + (bx << 3)],
dstride,
&src[bi << 2*bsize], 1 << bsize);
}
@@ -103,7 +103,7 @@
for (bi = 0; bi < dering_count; bi++) {
by = dlist[bi].by;
bx = dlist[bi].bx;
- copy_4x4_16_8bit(&dst[(by << 2) * dstride + (bx << 2)],
+ copy_4x4_16bit_to_8bit(&dst[(by << 2) * dstride + (bx << 2)],
dstride,
&src[bi << 2*bsize], 1 << bsize);
}
@@ -344,7 +344,7 @@
dec[pli], dir, pli, dlist, dering_count, threshold, coeff_shift);
#if CONFIG_AOM_HIGHBITDEPTH
if (cm->use_highbitdepth) {
- copy_blocks_16bit(
+ copy_dering_16bit_to_16bit(
(int16_t*)&CONVERT_TO_SHORTPTR(
xd->plane[pli].dst.buf)[xd->plane[pli].dst.stride *
(MAX_MIB_SIZE * sbr << bsize[pli]) +
@@ -353,7 +353,7 @@
dering_count, 3 - dec[pli]);
} else {
#endif
- copy_blocks_16_8bit(
+ copy_dering_16bit_to_8bit(
&xd->plane[pli].dst.buf[xd->plane[pli].dst.stride *
(MAX_MIB_SIZE * sbr << bsize[pli]) +
(sbc * MAX_MIB_SIZE << bsize[pli])],
diff --git a/av1/common/od_dering.c b/av1/common/od_dering.c
index 8b9dd7e..977faa0 100644
--- a/av1/common/od_dering.c
+++ b/av1/common/od_dering.c
@@ -258,14 +258,14 @@
return (threshold * OD_THRESH_TABLE_Q8[OD_ILOG(v1)] + 128) >> 8;
}
-static INLINE void copy_8x8_16bit(int16_t *dst, int dstride, int16_t *src, int sstride) {
+static INLINE void copy_8x8_16bit_to_16bit(int16_t *dst, int dstride, int16_t *src, int sstride) {
int i, j;
for (i = 0; i < 8; i++)
for (j = 0; j < 8; j++)
dst[i * dstride + j] = src[i * sstride + j];
}
-static INLINE void copy_4x4_16bit(int16_t *dst, int dstride, int16_t *src, int sstride) {
+static INLINE void copy_4x4_16bit_to_16bit(int16_t *dst, int dstride, int16_t *src, int sstride) {
int i, j;
for (i = 0; i < 4; i++)
for (j = 0; j < 4; j++)
@@ -273,7 +273,7 @@
}
/* TODO: Optimize this function for SSE. */
-void copy_blocks_16bit(int16_t *dst, int dstride, int16_t *src,
+void copy_dering_16bit_to_16bit(int16_t *dst, int dstride, int16_t *src,
dering_list *dlist, int dering_count, int bsize)
{
int bi, bx, by;
@@ -281,7 +281,7 @@
for (bi = 0; bi < dering_count; bi++) {
by = dlist[bi].by;
bx = dlist[bi].bx;
- copy_8x8_16bit(&dst[(by << 3) * dstride + (bx << 3)],
+ copy_8x8_16bit_to_16bit(&dst[(by << 3) * dstride + (bx << 3)],
dstride,
&src[bi << 2*bsize], 1 << bsize);
}
@@ -289,7 +289,7 @@
for (bi = 0; bi < dering_count; bi++) {
by = dlist[bi].by;
bx = dlist[bi].bx;
- copy_4x4_16bit(&dst[(by << 2) * dstride + (bx << 2)],
+ copy_4x4_16bit_to_16bit(&dst[(by << 2) * dstride + (bx << 2)],
dstride,
&src[bi << 2*bsize], 1 << bsize);
}
@@ -342,7 +342,7 @@
dir[by][bx]);
}
}
- copy_blocks_16bit(in, OD_FILT_BSTRIDE, y, dlist, dering_count,
+ copy_dering_16bit_to_16bit(in, OD_FILT_BSTRIDE, y, dlist, dering_count,
bsize);
for (bi = 0; bi < dering_count; bi++) {
by = dlist[bi].by;
diff --git a/av1/common/od_dering.h b/av1/common/od_dering.h
index 60cb041..48acf37 100644
--- a/av1/common/od_dering.h
+++ b/av1/common/od_dering.h
@@ -44,7 +44,7 @@
typedef void (*od_filter_dering_orthogonal_func)(int16_t *y, int ystride,
const int16_t *in,
int threshold, int dir);
-void copy_blocks_16bit(int16_t *dst, int dstride, int16_t *src,
+void copy_dering_16bit_to_16bit(int16_t *dst, int dstride, int16_t *src,
dering_list *dlist, int dering_count, int bsize);
void od_dering(int16_t *y, int16_t *in, int xdec,
diff --git a/av1/encoder/pickdering.c b/av1/encoder/pickdering.c
index 558baee..a6b918c 100644
--- a/av1/encoder/pickdering.c
+++ b/av1/encoder/pickdering.c
@@ -138,7 +138,7 @@
}
od_dering(tmp_dst, in, 0, dir, 0, dlist, dering_count, threshold,
coeff_shift);
- copy_blocks_16bit(dst, MAX_MIB_SIZE << bsize[0], tmp_dst, dlist,
+ copy_dering_16bit_to_16bit(dst, MAX_MIB_SIZE << bsize[0], tmp_dst, dlist,
dering_count, 3);
cur_mse = (int)compute_dist(
dst, MAX_MIB_SIZE << bsize[0],