[FFmpeg-cvslog] avcodec/adxenc: Use av_clip_intp2()

Michael Niedermayer git at videolan.org
Sat Feb 21 20:52:17 CET 2015


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Sat Feb 21 20:38:13 2015 +0100| [d74c8d3adac889c57b60644c4c494c57754b244a] | committer: Michael Niedermayer

avcodec/adxenc: Use av_clip_intp2()

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

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

 libavcodec/adxenc.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/adxenc.c b/libavcodec/adxenc.c
index 4387ffb..7736d09 100644
--- a/libavcodec/adxenc.c
+++ b/libavcodec/adxenc.c
@@ -81,7 +81,7 @@ static void adx_encode(ADXContext *c, uint8_t *adx, const int16_t *wav,
     for (i = 0, j = 0; j < 32; i += channels, j++) {
         d = ((wav[i] << COEFF_BITS) - c->coeff[0] * s1 - c->coeff[1] * s2) >> COEFF_BITS;
 
-        d = av_clip(ROUNDED_DIV(d, scale), -8, 7);
+        d = av_clip_intp2(ROUNDED_DIV(d, scale), 3);
 
         put_sbits(&pb, 4, d);
 



More information about the ffmpeg-cvslog mailing list