diff options
author | Diego Biurrun <diego@biurrun.de> | 2013-12-30 19:19:39 +0100 |
---|---|---|
committer | Diego Biurrun <diego@biurrun.de> | 2014-07-06 13:09:24 -0700 |
commit | 8d686ca59db14900ad5c12b547fb8a7afc8b0b94 (patch) | |
tree | 55fef696ccc67aa3793283f7575299b55e760206 /libavcodec/dsputil.c | |
parent | a7985cfd4c51b7fe2b870fc4ecd109707ee035d6 (diff) | |
download | ffmpeg-8d686ca59db14900ad5c12b547fb8a7afc8b0b94.tar.gz |
dsputil: Split off *_8x8basis to a separate context
Diffstat (limited to 'libavcodec/dsputil.c')
-rw-r--r-- | libavcodec/dsputil.c | 32 |
1 files changed, 0 insertions, 32 deletions
diff --git a/libavcodec/dsputil.c b/libavcodec/dsputil.c index 5e5ad93956..68f5120c41 100644 --- a/libavcodec/dsputil.c +++ b/libavcodec/dsputil.c @@ -464,35 +464,6 @@ static int nsse8_c(MpegEncContext *c, uint8_t *s1, uint8_t *s2, int stride, int return score1 + FFABS(score2) * 8; } -static int try_8x8basis_c(int16_t rem[64], int16_t weight[64], - int16_t basis[64], int scale) -{ - int i; - unsigned int sum = 0; - - for (i = 0; i < 8 * 8; i++) { - int b = rem[i] + ((basis[i] * scale + - (1 << (BASIS_SHIFT - RECON_SHIFT - 1))) >> - (BASIS_SHIFT - RECON_SHIFT)); - int w = weight[i]; - b >>= RECON_SHIFT; - assert(-512 < b && b < 512); - - sum += (w * b) * (w * b) >> 4; - } - return sum >> 2; -} - -static void add_8x8basis_c(int16_t rem[64], int16_t basis[64], int scale) -{ - int i; - - for (i = 0; i < 8 * 8; i++) - rem[i] += (basis[i] * scale + - (1 << (BASIS_SHIFT - RECON_SHIFT - 1))) >> - (BASIS_SHIFT - RECON_SHIFT); -} - static int zero_cmp(MpegEncContext *s, uint8_t *a, uint8_t *b, int stride, int h) { @@ -1126,9 +1097,6 @@ av_cold void ff_dsputil_init(DSPContext *c, AVCodecContext *avctx) c->nsse[0] = nsse16_c; c->nsse[1] = nsse8_c; - c->try_8x8basis = try_8x8basis_c; - c->add_8x8basis = add_8x8basis_c; - c->shrink[0] = av_image_copy_plane; c->shrink[1] = ff_shrink22; c->shrink[2] = ff_shrink44; |