diff options
author | Ronald S. Bultje <rsbultje@gmail.com> | 2012-03-17 15:39:16 -0700 |
---|---|---|
committer | Ronald S. Bultje <rsbultje@gmail.com> | 2012-03-18 15:33:19 -0700 |
commit | 72eda7786da47800065a1fbbe9b8eb31cedcf547 (patch) | |
tree | 1d4031cb2b7d1068bcec6d3ef43174602f631bb5 /libavcodec/adpcm.c | |
parent | f184735a27723885bd6cb12ab3fdc6552c4a3e81 (diff) | |
download | ffmpeg-72eda7786da47800065a1fbbe9b8eb31cedcf547.tar.gz |
adpcm: convert adpcm_yamaha to bytestream2.
Diffstat (limited to 'libavcodec/adpcm.c')
-rw-r--r-- | libavcodec/adpcm.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/adpcm.c b/libavcodec/adpcm.c index 877a5ad217..49f103e871 100644 --- a/libavcodec/adpcm.c +++ b/libavcodec/adpcm.c @@ -1202,8 +1202,8 @@ static int adpcm_decode_frame(AVCodecContext *avctx, void *data, bytestream2_seek(&gb, 0, SEEK_END); break; case CODEC_ID_ADPCM_YAMAHA: - for (n = nb_samples >> (1 - st); n > 0; n--, src++) { - uint8_t v = *src; + for (n = nb_samples >> (1 - st); n > 0; n--) { + int v = bytestream2_get_byteu(&gb); *samples++ = adpcm_yamaha_expand_nibble(&c->status[0 ], v & 0x0F); *samples++ = adpcm_yamaha_expand_nibble(&c->status[st], v >> 4 ); } |