summaryrefslogtreecommitdiff
path: root/libavcodec/simple_idct_template.c
diff options
context:
space:
mode:
Diffstat (limited to 'libavcodec/simple_idct_template.c')
-rw-r--r--libavcodec/simple_idct_template.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/libavcodec/simple_idct_template.c b/libavcodec/simple_idct_template.c
index dabfbda8a0..ffd75780a8 100644
--- a/libavcodec/simple_idct_template.c
+++ b/libavcodec/simple_idct_template.c
@@ -62,7 +62,7 @@
#define MUL(a, b) MUL16(a, b)
#define MAC(a, b, c) MAC16(a, b, c)
-#elif BIT_DEPTH == 10
+#elif BIT_DEPTH == 10 || BIT_DEPTH == 12
#define W1 90901
#define W2 85627
@@ -72,9 +72,15 @@
#define W6 35468
#define W7 18081
+#if BIT_DEPTH == 10
#define ROW_SHIFT 15
#define COL_SHIFT 20
#define DC_SHIFT 1
+#else
+#define ROW_SHIFT 17
+#define COL_SHIFT 18
+#define DC_SHIFT -1
+#endif
#define MUL(a, b) ((a) * (b))
#define MAC(a, b, c) ((a) += (b) * (c))