diff --git a/configure b/configure index 6c1e90909c424ef903e8670253fd9cc81e40b439..27e303470cb31a493433c445991a4b68802d317d 100755 --- a/configure +++ b/configure @@ -1806,7 +1806,7 @@ sonic_encoder_select="golomb" sonic_ls_encoder_select="golomb" svq1_decoder_select="hpeldsp" svq1_encoder_select="aandcttables dsputil mpegvideoenc" -svq3_decoder_select="error_resilience golomb h264chroma h264dsp h264pred h264qpel mpegvideo videodsp" +svq3_decoder_select="dsputil error_resilience golomb h264chroma h264dsp h264pred h264qpel mpegvideo videodsp" svq3_decoder_suggest="zlib" tak_decoder_select="dsputil" theora_decoder_select="vp3_decoder" diff --git a/libavcodec/svq3.c b/libavcodec/svq3.c index ac1d39f19df0511eb1120ea1525f36ff53e6af98..53c4d3202c95446203c09f3841bd521debd43278 100644 --- a/libavcodec/svq3.c +++ b/libavcodec/svq3.c @@ -48,6 +48,7 @@ #include "h264_mvpred.h" #include "golomb.h" +#include "hpeldsp.h" #include "rectangle.h" #include "vdpau_internal.h" @@ -65,6 +66,7 @@ typedef struct { H264Context h; + HpelDSPContext hdsp; Picture *cur_pic; Picture *next_pic; Picture *last_pic; @@ -316,9 +318,9 @@ static inline void svq3_mc_dir_part(SVQ3Context *s, : h->dsp.put_tpel_pixels_tab)[dxy](dest, src, h->linesize, width, height); else - (avg ? h->dsp.avg_pixels_tab - : h->dsp.put_pixels_tab)[blocksize][dxy](dest, src, h->linesize, - height); + (avg ? s->hdsp.avg_pixels_tab + : s->hdsp.put_pixels_tab)[blocksize][dxy](dest, src, h->linesize, + height); if (!(h->flags & CODEC_FLAG_GRAY)) { mx = mx + (mx < (int) x) >> 1; @@ -344,10 +346,10 @@ static inline void svq3_mc_dir_part(SVQ3Context *s, h->uvlinesize, width, height); else - (avg ? h->dsp.avg_pixels_tab - : h->dsp.put_pixels_tab)[blocksize][dxy](dest, src, - h->uvlinesize, - height); + (avg ? s->hdsp.avg_pixels_tab + : s->hdsp.put_pixels_tab)[blocksize][dxy](dest, src, + h->uvlinesize, + height); } } } @@ -869,6 +871,7 @@ static av_cold int svq3_decode_init(AVCodecContext *avctx) if (ff_h264_decode_init(avctx) < 0) return -1; + ff_hpeldsp_init(&s->hdsp, avctx->flags); h->flags = avctx->flags; h->is_complex = 1; h->sps.chroma_format_idc = 1;