diff options
author | Pascal Massimino <pascal.massimino@gmail.com> | 2014-08-27 02:58:10 +0200 |
---|---|---|
committer | Diego Biurrun <diego@biurrun.de> | 2014-09-02 14:41:13 -0700 |
commit | 7a1d6ddd2c6b2d66fbc1afa584cf506930a26453 (patch) | |
tree | 23c944d6dd16d12184720a1bb402fd5b18a68920 /libavcodec/x86 | |
parent | 95c0cec03acec0a80cc1c7db48f3b2355d9e767b (diff) | |
download | ffmpeg-7a1d6ddd2c6b2d66fbc1afa584cf506930a26453.tar.gz |
xvid: Add C IDCT
Thanks to Pascal Massimino and Michael Militzer for relicensing as LGPL.
Signed-off-by: Diego Biurrun <diego@biurrun.de>
Diffstat (limited to 'libavcodec/x86')
-rw-r--r-- | libavcodec/x86/xvididct_init.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/libavcodec/x86/xvididct_init.c b/libavcodec/x86/xvididct_init.c index ce5f240aee..e4f7345795 100644 --- a/libavcodec/x86/xvididct_init.c +++ b/libavcodec/x86/xvididct_init.c @@ -26,10 +26,16 @@ #include "idctdsp.h" #include "xvididct.h" -av_cold void ff_xvid_idct_init_x86(IDCTDSPContext *c) +av_cold void ff_xvid_idct_init_x86(IDCTDSPContext *c, AVCodecContext *avctx, + unsigned high_bit_depth) { int cpu_flags = av_get_cpu_flags(); + if (high_bit_depth || + !(avctx->idct_algo == FF_IDCT_AUTO || + avctx->idct_algo == FF_IDCT_XVID)) + return; + if (INLINE_MMX(cpu_flags)) { c->idct_put = ff_xvid_idct_mmx_put; c->idct_add = ff_xvid_idct_mmx_add; |