summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYaowu Xu <yaowu@google.com>2011-10-25 16:08:51 +0000
committerOn2 (Google) Code Review <on2-gerrit@google.com>2011-10-25 16:08:51 +0000
commit4081e5b3fe41a062a42e6171d6c4ebceb85f8d88 (patch)
tree90428d631004a84a8dfe8d7e04929e7ce1efe7f7
parent23701f4f877ba7bdb6c3b308c1fdd3bbcf3c91dd (diff)
parenta66c945c5973246561b3ff710886018f14e6679c (diff)
downloadlibvpx-4081e5b3fe41a062a42e6171d6c4ebceb85f8d88.tar
libvpx-4081e5b3fe41a062a42e6171d6c4ebceb85f8d88.tar.gz
libvpx-4081e5b3fe41a062a42e6171d6c4ebceb85f8d88.tar.bz2
libvpx-4081e5b3fe41a062a42e6171d6c4ebceb85f8d88.zip
Merge "added a last stage rounding for 8x8 inverse dct" into experimental
-rw-r--r--vp8/common/idctllm.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/vp8/common/idctllm.c b/vp8/common/idctllm.c
index 567aa1dcc..a0042ae6d 100644
--- a/vp8/common/idctllm.c
+++ b/vp8/common/idctllm.c
@@ -369,7 +369,7 @@ static void idctcol (int *blk)
((blk[8 * 0] + 32) >> 6);
return;
}
- x0 = (blk[8 * 0] << 8) + 8192;
+ x0 = (blk[8 * 0] << 8) + 16384;
/* first stage */
x8 = W7 * (x4 + x5) + 4;
@@ -399,14 +399,14 @@ static void idctcol (int *blk)
x4 = (181 * (x4 - x5) + 128) >> 8;
/* fourth stage */
- blk[8 * 0] = (x7 + x1) >> 14;
- blk[8 * 1] = (x3 + x2) >> 14;
- blk[8 * 2] = (x0 + x4) >> 14;
- blk[8 * 3] = (x8 + x6) >> 14;
- blk[8 * 4] = (x8 - x6) >> 14;
- blk[8 * 5] = (x0 - x4) >> 14;
- blk[8 * 6] = (x3 - x2) >> 14;
- blk[8 * 7] = (x7 - x1) >> 14;
+ blk[8 * 0] = (x7 + x1 ) >> 15;
+ blk[8 * 1] = (x3 + x2 ) >> 15;
+ blk[8 * 2] = (x0 + x4 ) >> 15;
+ blk[8 * 3] = (x8 + x6 ) >> 15;
+ blk[8 * 4] = (x8 - x6 ) >> 15;
+ blk[8 * 5] = (x0 - x4 ) >> 15;
+ blk[8 * 6] = (x3 - x2 ) >> 15;
+ blk[8 * 7] = (x7 - x1 ) >> 15;
}
#define TX_DIM 8
@@ -434,7 +434,7 @@ void vp8_short_idct8x8_c(short *coefs, short *block, int pitch)
{
for (j = 0; j < TX_DIM; j++)
{
- block[i*shortpitch+j] = X[i * TX_DIM + j]>>1;
+ block[i*shortpitch+j] = X[i * TX_DIM + j];
}
}
}