From c25c7767085297e4f6bf4171391b615b5bddc281 Mon Sep 17 00:00:00 2001 From: Jason Garrett-Glaser Date: Fri, 23 Jul 2010 00:07:16 +0000 Subject: VP8: clear DCT blocks in iDCT instead of using clear_blocks. ~0.3% faster overall. Originally committed as revision 24448 to svn://svn.ffmpeg.org/ffmpeg/trunk --- libavcodec/vp8dsp.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'libavcodec/vp8dsp.c') diff --git a/libavcodec/vp8dsp.c b/libavcodec/vp8dsp.c index 482d62af1b..3e6463d598 100644 --- a/libavcodec/vp8dsp.c +++ b/libavcodec/vp8dsp.c @@ -69,6 +69,10 @@ static void vp8_idct_add_c(uint8_t *dst, DCTELEM block[16], int stride) t1 = block[0*4+i] - block[2*4+i]; t2 = MUL_35468(block[1*4+i]) - MUL_20091(block[3*4+i]); t3 = MUL_20091(block[1*4+i]) + MUL_35468(block[3*4+i]); + block[0*4+i] = 0; + block[1*4+i] = 0; + block[2*4+i] = 0; + block[3*4+i] = 0; tmp[i*4+0] = t0 + t3; tmp[i*4+1] = t1 + t2; @@ -94,6 +98,7 @@ static void vp8_idct_dc_add_c(uint8_t *dst, DCTELEM block[16], int stride) { int i, dc = (block[0] + 4) >> 3; uint8_t *cm = ff_cropTbl + MAX_NEG_CROP + dc; + block[0] = 0; for (i = 0; i < 4; i++) { dst[0] = cm[dst[0]]; -- cgit v1.2.3