summaryrefslogtreecommitdiff
path: root/src/libffmpeg/libavcodec/ppc/dsputil_altivec.c
diff options
context:
space:
mode:
authorMiguel Freitas <miguelfreitas@users.sourceforge.net>2003-01-08 13:18:42 +0000
committerMiguel Freitas <miguelfreitas@users.sourceforge.net>2003-01-08 13:18:42 +0000
commit6f1c8d4eafabd914b87e9171bf4d04f4ef9160ea (patch)
treee70be493d1222b10f96aa5efac01c0ec0d5bcc97 /src/libffmpeg/libavcodec/ppc/dsputil_altivec.c
parent1fb58a63872660424777d41389e426dc90f1b660 (diff)
downloadxine-lib-6f1c8d4eafabd914b87e9171bf4d04f4ef9160ea.tar.gz
xine-lib-6f1c8d4eafabd914b87e9171bf4d04f4ef9160ea.tar.bz2
syncing ffmpeg (with some compilation fixes)
- fixes wma bugs - mace, huffyuv and mp3 decoders imported (but not enabled) tested: wma (v1 and v2), mpeg4, msmpeg4 v1, v2 and v3, divx3, divx4, divx5, xvid and dv decoders. everything looks fine. CVS patchset: 3828 CVS date: 2003/01/08 13:18:42
Diffstat (limited to 'src/libffmpeg/libavcodec/ppc/dsputil_altivec.c')
-rw-r--r--src/libffmpeg/libavcodec/ppc/dsputil_altivec.c42
1 files changed, 0 insertions, 42 deletions
diff --git a/src/libffmpeg/libavcodec/ppc/dsputil_altivec.c b/src/libffmpeg/libavcodec/ppc/dsputil_altivec.c
index ed34a2d92..5f14ed0eb 100644
--- a/src/libffmpeg/libavcodec/ppc/dsputil_altivec.c
+++ b/src/libffmpeg/libavcodec/ppc/dsputil_altivec.c
@@ -343,48 +343,6 @@ int pix_norm1_altivec(uint8_t *pix, int line_size)
return s;
}
-
-int pix_norm_altivec(uint8_t *pix1, uint8_t *pix2, int line_size)
-{
- int s, i;
- vector unsigned char *tv, zero;
- vector unsigned char pix1v, pix2v, t5;
- vector unsigned int sv;
- vector signed int sum;
-
- zero = vec_splat_u8(0);
- sv = vec_splat_u32(0);
- s = 0;
- for (i = 0; i < 16; i++) {
- /* Read in the potentially unaligned pixels */
- tv = (vector unsigned char *) pix1;
- pix1v = vec_perm(tv[0], tv[1], vec_lvsl(0, pix1));
-
- tv = (vector unsigned char *) pix2;
- pix2v = vec_perm(tv[0], tv[1], vec_lvsl(0, pix2));
-
- /*
- Since we want to use unsigned chars, we can take advantage
- of the fact that abs(a-b)^2 = (a-b)^2.
- */
-
- /* Calculate a sum of abs differences vector */
- t5 = vec_sub(vec_max(pix1v, pix2v), vec_min(pix1v, pix2v));
-
- /* Square the values and add them to our sum */
- sv = vec_msum(t5, t5, sv);
-
- pix1 += line_size;
- pix2 += line_size;
- }
- /* Sum up the four partial sums, and put the result into s */
- sum = vec_sums((vector signed int) sv, (vector signed int) zero);
- sum = vec_splat(sum, 3);
- vec_ste(sum, 0, &s);
- return s;
-}
-
-
int pix_sum_altivec(UINT8 * pix, int line_size)
{