From 7fb7f6367a4cc55a0ab0b42a11d1e2c2086e3877 Mon Sep 17 00:00:00 2001 From: Roman Shaposhnik Date: Thu, 19 Feb 2009 00:30:24 +0000 Subject: [PATCH] Adding 2 intra 8x8 cmp functions: vsad, vsse Originally committed as revision 17448 to svn://svn.ffmpeg.org/ffmpeg/trunk --- libavcodec/dsputil.c | 65 ++++++++++++++++++++++++++++++---------------------- 1 file changed, 37 insertions(+), 28 deletions(-) diff --git a/libavcodec/dsputil.c b/libavcodec/dsputil.c index 71a5b94..86a6c37 100644 --- a/libavcodec/dsputil.c +++ b/libavcodec/dsputil.c @@ -3937,20 +3937,23 @@ static int bit8x8_c(/*MpegEncContext*/ void *c, uint8_t *src1, uint8_t *src2, in return bits; } -static int vsad_intra16_c(/*MpegEncContext*/ void *c, uint8_t *s, uint8_t *dummy, int stride, int h){ - int score=0; - int x,y; - - for(y=1; yhadamard8_diff[4]= hadamard8_intra16_c; + c->hadamard8_diff[5]= hadamard8_intra8x8_c; SET_CMP_FUNC(dct_sad) SET_CMP_FUNC(dct_max) #if CONFIG_GPL @@ -4555,8 +4562,10 @@ void dsputil_init(DSPContext* c, AVCodecContext *avctx) SET_CMP_FUNC(bit) c->vsad[0]= vsad16_c; c->vsad[4]= vsad_intra16_c; + c->vsad[5]= vsad_intra8_c; c->vsse[0]= vsse16_c; c->vsse[4]= vsse_intra16_c; + c->vsse[5]= vsse_intra8_c; c->nsse[0]= nsse16_c; c->nsse[1]= nsse8_c; #if CONFIG_SNOW_ENCODER -- 2.7.4