diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2004-09-27 19:47:17 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2004-09-27 19:47:17 +0000 |
commit | 0fa8158d3e70eccda141df1d18cff648530c0cf5 (patch) | |
tree | b25c0e4f68211bdba5ea58f7edc8f2c601fc0b0b /libavcodec/dsputil.c | |
parent | 40028f8f6e214c90a15a10b3b33e83c06c4ac74f (diff) | |
download | ffmpeg-0fa8158d3e70eccda141df1d18cff648530c0cf5.tar.gz |
move h264 idct to its own file and call via function pointer in DspContext
allow h264 idct to be used for lowres=1
Originally committed as revision 3524 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/dsputil.c')
-rw-r--r-- | libavcodec/dsputil.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/libavcodec/dsputil.c b/libavcodec/dsputil.c index 3db04c00a7..1fc698a62f 100644 --- a/libavcodec/dsputil.c +++ b/libavcodec/dsputil.c @@ -3434,8 +3434,13 @@ void dsputil_init(DSPContext* c, AVCodecContext *avctx) #endif //CONFIG_ENCODERS if(avctx->lowres==1){ - c->idct_put= ff_jref_idct4_put; - c->idct_add= ff_jref_idct4_add; + if(avctx->idct_algo==FF_IDCT_INT || avctx->idct_algo==FF_IDCT_AUTO){ + c->idct_put= ff_jref_idct4_put; + c->idct_add= ff_jref_idct4_add; + }else{ + c->idct_put= ff_h264_lowres_idct_put_c; + c->idct_add= ff_h264_lowres_idct_add_c; + } c->idct = j_rev_dct4; c->idct_permutation_type= FF_NO_IDCT_PERM; }else if(avctx->lowres==2){ @@ -3462,6 +3467,8 @@ void dsputil_init(DSPContext* c, AVCodecContext *avctx) } } + c->h264_idct_add= ff_h264_idct_add_c; + /* VP3 DSP support */ c->vp3_dsp_init = vp3_dsp_init_c; c->vp3_idct = vp3_idct_c; |