[FFmpeg-cvslog] avutil/fixed_dsp: Use av_clip_int16() instead of the non optimized av_clip_int16_c()

Michael Niedermayer git at videolan.org
Sun Feb 15 00:44:14 CET 2015


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Sun Feb 15 00:22:46 2015 +0100| [64e036980875967ff5b793e9a979077b0f6b5643] | committer: Michael Niedermayer

avutil/fixed_dsp: Use av_clip_int16() instead of the non optimized av_clip_int16_c()

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=64e036980875967ff5b793e9a979077b0f6b5643
---

 libavutil/fixed_dsp.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavutil/fixed_dsp.c b/libavutil/fixed_dsp.c
index b99fea5..102a951 100644
--- a/libavutil/fixed_dsp.c
+++ b/libavutil/fixed_dsp.c
@@ -63,8 +63,8 @@ static void vector_fmul_window_fixed_scaled_c(int16_t *dst, const int32_t *src0,
         s1 = src1[j];
         wi = win[i];
         wj = win[j];
-        dst[i] = av_clip_int16_c(((((int64_t)s0*wj - (int64_t)s1*wi + 0x40000000) >> 31) + round) >> bits);
-        dst[j] = av_clip_int16_c(((((int64_t)s0*wi + (int64_t)s1*wj + 0x40000000) >> 31) + round) >> bits);
+        dst[i] = av_clip_int16(((((int64_t)s0*wj - (int64_t)s1*wi + 0x40000000) >> 31) + round) >> bits);
+        dst[j] = av_clip_int16(((((int64_t)s0*wi + (int64_t)s1*wj + 0x40000000) >> 31) + round) >> bits);
     }
 }
 



More information about the ffmpeg-cvslog mailing list