summaryrefslogtreecommitdiff
path: root/libavcodec/hevcdsp_template.c
diff options
context:
space:
mode:
authorClément Bœsch <cboesch@gopro.com>2017-01-31 16:02:35 +0100
committerClément Bœsch <cboesch@gopro.com>2017-01-31 16:05:06 +0100
commit05018c2cdaf3cbf5769bdf90951f707cf99edd52 (patch)
tree8a6509baa7b9667e2e4eee6c3015729d24eb9f23 /libavcodec/hevcdsp_template.c
parenta604115f72ad0d77b69193989bbe16174135129d (diff)
parentcc16da75c2f99d92f7a6461100f041352deb6d88 (diff)
Merge commit 'cc16da75c2f99d92f7a6461100f041352deb6d88'
* commit 'cc16da75c2f99d92f7a6461100f041352deb6d88': hevc: Add coefficient limiting to speed up IDCT Noop again as we have these changes already, only random spacing changes. Merged-by: Clément Bœsch <cboesch@gopro.com>
Diffstat (limited to 'libavcodec/hevcdsp_template.c')
-rw-r--r--libavcodec/hevcdsp_template.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/libavcodec/hevcdsp_template.c b/libavcodec/hevcdsp_template.c
index 1dbd47a45b..665436cce3 100644
--- a/libavcodec/hevcdsp_template.c
+++ b/libavcodec/hevcdsp_template.c
@@ -223,7 +223,7 @@ static void FUNC(transform_4x4_luma)(int16_t *coeffs)
for (i = 0; i < 16; i++) \
for (j = 1; j < end; j += 2) \
o_32[i] += transform[j][i] * src[j * sstep]; \
- TR_16(e_32, src, 1, 2 * sstep, SET, end/2); \
+ TR_16(e_32, src, 1, 2 * sstep, SET, end / 2); \
\
for (i = 0; i < 16; i++) { \
assign(dst[i * dstep], e_32[i] + o_32[i]); \
@@ -232,21 +232,22 @@ static void FUNC(transform_4x4_luma)(int16_t *coeffs)
} while (0)
#define IDCT_VAR4(H) \
- int limit2 = FFMIN(col_limit + 4, H)
+ int limit2 = FFMIN(col_limit + 4, H)
#define IDCT_VAR8(H) \
- int limit = FFMIN(col_limit, H); \
- int limit2 = FFMIN(col_limit + 4, H)
+ int limit = FFMIN(col_limit, H); \
+ int limit2 = FFMIN(col_limit + 4, H)
#define IDCT_VAR16(H) IDCT_VAR8(H)
#define IDCT_VAR32(H) IDCT_VAR8(H)
#define IDCT(H) \
static void FUNC(idct_ ## H ## x ## H )(int16_t *coeffs, \
- int col_limit) { \
+ int col_limit) \
+{ \
int i; \
int shift = 7; \
int add = 1 << (shift - 1); \
int16_t *src = coeffs; \
- IDCT_VAR ##H(H); \
+ IDCT_VAR ## H(H); \
\
for (i = 0; i < H; i++) { \
TR_ ## H(src, src, H, H, SCALE, limit2); \