Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2015-02-21 22:41:36 +0300
committerMichael Niedermayer <michaelni@gmx.at>2015-02-21 22:41:36 +0300
commitf848a66009f25e32ee5e1244a20060a34c777be0 (patch)
tree29a356056850f8ca4ef28210c63d723563480d4d /libavcodec/adpcmenc.c
parentd1c705087f52a4c39ae982d46d91c35810c1546f (diff)
avcodec/adpcm: use av_clip_intp2()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/adpcmenc.c')
-rw-r--r--libavcodec/adpcmenc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/adpcmenc.c b/libavcodec/adpcmenc.c
index c3546f9058..68164630f4 100644
--- a/libavcodec/adpcmenc.c
+++ b/libavcodec/adpcmenc.c
@@ -227,7 +227,7 @@ static inline uint8_t adpcm_ms_compress_sample(ADPCMChannelStatus *c,
bias = -c->idelta / 2;
nibble = (nibble + bias) / c->idelta;
- nibble = av_clip(nibble, -8, 7) & 0x0F;
+ nibble = av_clip_intp2(nibble, 3) & 0x0F;
predictor += ((nibble & 0x08) ? (nibble - 0x10) : nibble) * c->idelta;