summaryrefslogtreecommitdiffstats
path: root/libswscale
diff options
context:
space:
mode:
authorkostya <kostya@b3059339-0415-0410-9bf9-f77b7e298cf2>2009-02-14 16:39:15 +0000
committerkostya <kostya@b3059339-0415-0410-9bf9-f77b7e298cf2>2009-02-14 16:39:15 +0000
commit060548889799bad3f9fc417c6a22a39783fd66ae (patch)
treee1ce2bc53390d1511fb099c3da146747f43ac3f9 /libswscale
parent919b7aef263325e8b21dd7fd36c67e89ae80431e (diff)
downloadmpv-060548889799bad3f9fc417c6a22a39783fd66ae.tar.bz2
mpv-060548889799bad3f9fc417c6a22a39783fd66ae.tar.xz
Make hScale_altivec_real() trim its output like other implementations do
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28556 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libswscale')
-rw-r--r--libswscale/swscale_altivec_template.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/libswscale/swscale_altivec_template.c b/libswscale/swscale_altivec_template.c
index 2111cec410..a008b966e8 100644
--- a/libswscale/swscale_altivec_template.c
+++ b/libswscale/swscale_altivec_template.c
@@ -220,7 +220,7 @@ static inline void hScale_altivec_real(int16_t *dst, int dstW, uint8_t *src, int
for (j=0; j<filterSize; j++) {
val += ((int)src[srcPos + j])*filter[filterSize*i + j];
}
- dst[i] = av_clip(val>>7, 0, (1<<15)-1);
+ dst[i] = FFMIN(val>>7, (1<<15)-1);
}
}
else
@@ -259,7 +259,7 @@ static inline void hScale_altivec_real(int16_t *dst, int dstW, uint8_t *src, int
val_vEven = vec_mule(src_v, filter_v);
val_s = vec_sums(val_vEven, vzero);
vec_st(val_s, 0, tempo);
- dst[i] = av_clip(tempo[3]>>7, 0, (1<<15)-1);
+ dst[i] = FFMIN(tempo[3]>>7, (1<<15)-1);
}
}
break;
@@ -286,7 +286,7 @@ static inline void hScale_altivec_real(int16_t *dst, int dstW, uint8_t *src, int
val_v = vec_msums(src_v, filter_v, (vector signed int)vzero);
val_s = vec_sums(val_v, vzero);
vec_st(val_s, 0, tempo);
- dst[i] = av_clip(tempo[3]>>7, 0, (1<<15)-1);
+ dst[i] = FFMIN(tempo[3]>>7, (1<<15)-1);
}
}
break;
@@ -315,7 +315,7 @@ static inline void hScale_altivec_real(int16_t *dst, int dstW, uint8_t *src, int
vector signed int val_s = vec_sums(val_v, vzero);
vec_st(val_s, 0, tempo);
- dst[i] = av_clip(tempo[3]>>7, 0, (1<<15)-1);
+ dst[i] = FFMIN(tempo[3]>>7, (1<<15)-1);
}
}
break;
@@ -377,7 +377,7 @@ static inline void hScale_altivec_real(int16_t *dst, int dstW, uint8_t *src, int
val_s = vec_sums(val_v, vzero);
vec_st(val_s, 0, tempo);
- dst[i] = av_clip(tempo[3]>>7, 0, (1<<15)-1);
+ dst[i] = FFMIN(tempo[3]>>7, (1<<15)-1);
}
}