diff options
author | Romain Dolbeau <dolbeau@irisa.fr> | 2004-05-30 01:53:43 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2004-05-30 01:53:43 +0000 |
commit | 20646267cdde0ec0c6d8fb61b7bab29f431fa541 (patch) | |
tree | 57da484ddb2aa1b4408781c9409b1ed1d176650f /libavcodec/libpostproc/postprocess_template.c | |
parent | 752040924503695dac18d1068a4b6b759a68f3d4 (diff) | |
download | ffmpeg-20646267cdde0ec0c6d8fb61b7bab29f431fa541.tar.gz |
Another (final?) patch for libpostproc.
This one replace horizClassify by a
transpose/(use Vert)/transpose sequence.
This add LowPass and DefFilter for "free".
I also fixed the header in postprocess.c
and special-cased some of the well-aligned
cases (all horiz stuff is well-aligned).
patch by (Romain Dolbeau <dolbeau at irisa dot fr>)
Originally committed as revision 3175 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/libpostproc/postprocess_template.c')
-rw-r--r-- | libavcodec/libpostproc/postprocess_template.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/libavcodec/libpostproc/postprocess_template.c b/libavcodec/libpostproc/postprocess_template.c index 209fff2402..316d9f3884 100644 --- a/libavcodec/libpostproc/postprocess_template.c +++ b/libavcodec/libpostproc/postprocess_template.c @@ -3684,12 +3684,27 @@ static void RENAME(postProcess)(uint8_t src[], int srcStride, uint8_t dst[], int horizX1Filter(dstBlock-4, stride, QP); else if(mode & H_DEBLOCK) { +#ifdef HAVE_ALTIVEC + unsigned char __attribute__ ((aligned(16))) tempBlock[272]; + transpose_16x8_char_toPackedAlign_altivec(tempBlock, dstBlock - (4 + 1), stride); + + const int t=vertClassify_altivec(tempBlock-48, 16, &c); + if(t==1) { + doVertLowPass_altivec(tempBlock-48, 16, &c); + transpose_8x16_char_fromPackedAlign_altivec(dstBlock - (4 + 1), tempBlock, stride); + } + else if(t==2) { + doVertDefFilter_altivec(tempBlock-48, 16, &c); + transpose_8x16_char_fromPackedAlign_altivec(dstBlock - (4 + 1), tempBlock, stride); + } +#else const int t= RENAME(horizClassify)(dstBlock-4, stride, &c); if(t==1) RENAME(doHorizLowPass)(dstBlock-4, stride, &c); else if(t==2) RENAME(doHorizDefFilter)(dstBlock-4, stride, &c); +#endif }else if(mode & H_A_DEBLOCK){ RENAME(do_a_deblock)(dstBlock-8, 1, stride, &c); } |