diff options
author | James Klicman <james@klicman.org> | 2003-10-26 10:14:05 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2003-10-26 10:14:05 +0000 |
commit | 14cabd40680e459e5d5385e9045d2391b56d2b95 (patch) | |
tree | 5adc8d8cb3b5ec90bdc2896d7c22630beb8b818e /libavcodec/ppc/dsputil_ppc.c | |
parent | 5c69a4fd682ae479f0921361b7953e6163bd3064 (diff) | |
download | ffmpeg-14cabd40680e459e5d5385e9045d2391b56d2b95.tar.gz |
AltiVec optimized fdct patch by (James Klicman <james at klicman dot org>)
Originally committed as revision 2439 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/ppc/dsputil_ppc.c')
-rw-r--r-- | libavcodec/ppc/dsputil_ppc.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/libavcodec/ppc/dsputil_ppc.c b/libavcodec/ppc/dsputil_ppc.c index 7af2aa0029..4d45b4ffcc 100644 --- a/libavcodec/ppc/dsputil_ppc.c +++ b/libavcodec/ppc/dsputil_ppc.c @@ -25,6 +25,7 @@ #include "dsputil_altivec.h" #endif +extern void fdct_altivec(int16_t *block); extern void idct_put_altivec(uint8_t *dest, int line_size, int16_t *block); extern void idct_add_altivec(uint8_t *dest, int line_size, int16_t *block); @@ -48,6 +49,7 @@ static unsigned char* perfname[] = { "fft_calc_altivec", "gmc1_altivec", "dct_unquantize_h263_altivec", + "fdct_altivec", "idct_add_altivec", "idct_put_altivec", "put_pixels16_altivec", @@ -270,6 +272,14 @@ void dsputil_init_ppc(DSPContext* c, AVCodecContext *avctx) c->gmc1 = gmc1_altivec; +#ifdef CONFIG_ENCODERS + if (avctx->dct_algo == FF_DCT_AUTO || + avctx->dct_algo == FF_DCT_ALTIVEC) + { + c->fdct = fdct_altivec; + } +#endif //CONFIG_ENCODERS + if ((avctx->idct_algo == FF_IDCT_AUTO) || (avctx->idct_algo == FF_IDCT_ALTIVEC)) { |