diff options
author | Jingning Han <jingning@google.com> | 2013-06-14 11:28:56 -0700 |
---|---|---|
committer | Jingning Han <jingning@google.com> | 2013-06-18 09:46:24 -0700 |
commit | a41a4860c0b3be7815f37b4ec833e87218307c4f (patch) | |
tree | 8d795f9d348b6c21627b36e0e266027e53263d4d /vp9/common | |
parent | c43af9a8a3adc7bd3888e746ce7b7bd581c476ae (diff) | |
download | libvpx-a41a4860c0b3be7815f37b4ec833e87218307c4f.tar libvpx-a41a4860c0b3be7815f37b4ec833e87218307c4f.tar.gz libvpx-a41a4860c0b3be7815f37b4ec833e87218307c4f.tar.bz2 libvpx-a41a4860c0b3be7815f37b4ec833e87218307c4f.zip |
Make fdct32 computation flow within 16bit range
This commit makes use of dual fdct32x32 versions for rate-distortion
optimization loop and encoding process, respectively. The one for
rd loop requires only 16 bits precision for intermediate steps.
The original fdct32x32 that allows higher intermediate precision (18
bits) was retained for the encoding process only.
This allows speed-up for fdct32x32 in the rd loop. No performance
loss observed.
Change-Id: I3237770e39a8f87ed17ae5513c87228533397cc3
Diffstat (limited to 'vp9/common')
-rw-r--r-- | vp9/common/vp9_idct.h | 6 | ||||
-rw-r--r-- | vp9/common/vp9_rtcd_defs.sh | 3 |
2 files changed, 3 insertions, 6 deletions
diff --git a/vp9/common/vp9_idct.h b/vp9/common/vp9_idct.h index af35432c4..64f14c993 100644 --- a/vp9/common/vp9_idct.h +++ b/vp9/common/vp9_idct.h @@ -71,12 +71,6 @@ static INLINE int dct_const_round_shift(int input) { return rv; } -static INLINE int dct_32_round(int input) { - int rv = ROUND_POWER_OF_TWO(input, DCT_CONST_BITS); - assert(-131072 <= rv && rv <= 131071); - return rv; -} - typedef void (*transform_1d)(int16_t*, int16_t*); typedef struct { diff --git a/vp9/common/vp9_rtcd_defs.sh b/vp9/common/vp9_rtcd_defs.sh index 8c78b7bbd..221718b9b 100644 --- a/vp9/common/vp9_rtcd_defs.sh +++ b/vp9/common/vp9_rtcd_defs.sh @@ -577,6 +577,9 @@ specialize vp9_short_fdct8x4 sse2 prototype void vp9_short_fdct32x32 "int16_t *InputData, int16_t *OutputData, int pitch" specialize vp9_short_fdct32x32 +prototype void vp9_short_fdct32x32_rd "int16_t *InputData, int16_t *OutputData, int pitch" +specialize vp9_short_fdct32x32_rd + prototype void vp9_short_fdct16x16 "int16_t *InputData, int16_t *OutputData, int pitch" specialize vp9_short_fdct16x16 sse2 |