mirror of
https://github.com/nyanmisaka/ffmpeg-rockchip.git
synced 2025-10-21 16:10:16 +08:00
use av_clip_int16() where it makes sense
Originally committed as revision 10078 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
@@ -740,10 +740,7 @@ static int wma_decode_frame(WMACodecContext *s, int16_t *samples)
|
||||
|
||||
for(i=0;i<n;i++) {
|
||||
a = lrintf(*iptr++);
|
||||
if (a > 32767)
|
||||
a = 32767;
|
||||
else if (a < -32768)
|
||||
a = -32768;
|
||||
a = av_clip_int16(a);
|
||||
*ptr = a;
|
||||
ptr += incr;
|
||||
}
|
||||
|
Reference in New Issue
Block a user