mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-12-23 12:43:46 +02:00
clip MS ADPCM predictor range to correct [0..6] range, not [0..7]
Originally committed as revision 14203 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
parent
962fe7e1c4
commit
f9bd305694
@ -1025,10 +1025,10 @@ static int adpcm_decode_frame(AVCodecContext *avctx,
|
|||||||
n = buf_size - 7 * avctx->channels;
|
n = buf_size - 7 * avctx->channels;
|
||||||
if (n < 0)
|
if (n < 0)
|
||||||
return -1;
|
return -1;
|
||||||
block_predictor[0] = av_clip(*src++, 0, 7);
|
block_predictor[0] = av_clip(*src++, 0, 6);
|
||||||
block_predictor[1] = 0;
|
block_predictor[1] = 0;
|
||||||
if (st)
|
if (st)
|
||||||
block_predictor[1] = av_clip(*src++, 0, 7);
|
block_predictor[1] = av_clip(*src++, 0, 6);
|
||||||
c->status[0].idelta = (int16_t)bytestream_get_le16(&src);
|
c->status[0].idelta = (int16_t)bytestream_get_le16(&src);
|
||||||
if (st){
|
if (st){
|
||||||
c->status[1].idelta = (int16_t)bytestream_get_le16(&src);
|
c->status[1].idelta = (int16_t)bytestream_get_le16(&src);
|
||||||
|
Loading…
Reference in New Issue
Block a user