summaryrefslogtreecommitdiff
path: root/libavcodec/tscc2.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2014-06-07 17:44:23 +0200
committerMichael Niedermayer <michaelni@gmx.at>2014-06-07 17:44:23 +0200
commit118c042116bf0da1ac357b41219d4a6c95f544ad (patch)
treeba59c041f4a05aa88bccf66921274bd0e24dd4c8 /libavcodec/tscc2.c
parent925bd174f20371dee37542291c77fee1ba3e155d (diff)
avcodec/tscc2: fix macro ()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/tscc2.c')
-rw-r--r--libavcodec/tscc2.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/tscc2.c b/libavcodec/tscc2.c
index 487af5462c..92210f7d39 100644
--- a/libavcodec/tscc2.c
+++ b/libavcodec/tscc2.c
@@ -90,14 +90,14 @@ static av_cold int init_vlcs(TSCC2Context *c)
return 0;
}
-#define DEQUANT(val, q) ((q * val + 0x80) >> 8)
+#define DEQUANT(val, q) (((q) * (val) + 0x80) >> 8)
#define DCT1D(d0, d1, d2, d3, s0, s1, s2, s3, OP) \
OP(d0, 5 * ((s0) + (s1) + (s2)) + 2 * (s3)); \
OP(d1, 5 * ((s0) - (s2) - (s3)) + 2 * (s1)); \
OP(d2, 5 * ((s0) - (s2) + (s3)) - 2 * (s1)); \
OP(d3, 5 * ((s0) - (s1) + (s2)) - 2 * (s3)); \
-#define COL_OP(a, b) a = b
+#define COL_OP(a, b) a = (b)
#define ROW_OP(a, b) a = ((b) + 0x20) >> 6
static void tscc2_idct4_put(int *in, int q[3], uint8_t *dst, int stride)