[SCM] libav/experimental: Make the horizontal C scaler code clip only against INT16_MAX not 0, this decreases the difference between C and MMX, its also faster.

siretart at users.alioth.debian.org siretart at users.alioth.debian.org
Sun Jun 30 16:30:03 UTC 2013


The following commit has been merged in the experimental branch:
commit 881c429407c2e16c2eb8e86cd036f7652912cdc3
Author: Michael Niedermayer <michaelni at gmx.at>
Date:   Fri Sep 12 22:29:21 2008 +0000

    Make the horizontal C scaler code clip only against INT16_MAX not 0,
    this decreases the difference between C and MMX, its also faster.
    
    Originally committed as revision 27593 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale

diff --git a/libswscale/swscale_template.c b/libswscale/swscale_template.c
index bccead8..4bcb605 100644
--- a/libswscale/swscale_template.c
+++ b/libswscale/swscale_template.c
@@ -2330,7 +2330,7 @@ static inline void RENAME(hScale)(int16_t *dst, int dstW, uint8_t *src, int srcW
             val += ((int)src[srcPos + j])*filter[filterSize*i + j];
         }
         //filter += hFilterSize;
-        dst[i] = av_clip(val>>7, 0, (1<<15)-1); // the cubic equation does overflow ...
+        dst[i] = FFMIN(val>>7, (1<<15)-1); // the cubic equation does overflow ...
         //dst[i] = val>>7;
     }
 #endif /* HAVE_ALTIVEC */

-- 
Libav/FFmpeg packaging



More information about the pkg-multimedia-commits mailing list