summaryrefslogtreecommitdiff
path: root/vp9/common/vp9_idct.h
diff options
context:
space:
mode:
authorJingning Han <jingning@google.com>2013-11-15 15:21:38 -0800
committerJingning Han <jingning@google.com>2013-11-15 15:30:47 -0800
commitbdc4371174e37748a7e64a13defd7b5437be190c (patch)
treef26a90b77b560d79ae7dd106419c01b5811ee36b /vp9/common/vp9_idct.h
parent8d7bd4d1265ab24749ab5dcc4a0226e588fb1f8b (diff)
downloadlibvpx-bdc4371174e37748a7e64a13defd7b5437be190c.tar
libvpx-bdc4371174e37748a7e64a13defd7b5437be190c.tar.gz
libvpx-bdc4371174e37748a7e64a13defd7b5437be190c.tar.bz2
libvpx-bdc4371174e37748a7e64a13defd7b5437be190c.zip
Take out assertion from inverse transforms
Separate the rounding and right shift operations of forward transform from those of inverse transform. Take out the assertion check from inverse transforms. If the transform coefficients were constructed to cause intermediate steps of inverse transform overflow, the codec will just let it overflow without breaking the decoding flow. Change-Id: I73cfc3706c4e840fc543a77cbc4cdb0b05d07730
Diffstat (limited to 'vp9/common/vp9_idct.h')
-rw-r--r--vp9/common/vp9_idct.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/vp9/common/vp9_idct.h b/vp9/common/vp9_idct.h
index 2b3f35f0a..183c50abf 100644
--- a/vp9/common/vp9_idct.h
+++ b/vp9/common/vp9_idct.h
@@ -77,8 +77,7 @@ static const int sinpi_4_9 = 15212;
static INLINE int dct_const_round_shift(int input) {
int rv = ROUND_POWER_OF_TWO(input, DCT_CONST_BITS);
- assert(INT16_MIN <= rv && rv <= INT16_MAX);
- return rv;
+ return (int16_t)rv;
}
typedef void (*transform_1d)(const int16_t*, int16_t*);