diff options
author | Vitor Sessak <vitor1001@gmail.com> | 2008-05-24 09:17:30 +0000 |
---|---|---|
committer | Vitor Sessak <vitor1001@gmail.com> | 2008-05-24 09:17:30 +0000 |
commit | c2c237a0d55ce1f0a57d66b9f051d1ca9556a792 (patch) | |
tree | a6c43452f518c57765c3ef147c5e13b59cf0a1e3 /libavcodec/ra144.c | |
parent | d548f09ff6ebdfa3d27765bf2c954b32cb0a4fed (diff) | |
download | ffmpeg-c2c237a0d55ce1f0a57d66b9f051d1ca9556a792.tar.gz |
More simplifications of ra144_decode_frame()
Originally committed as revision 13275 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/ra144.c')
-rw-r--r-- | libavcodec/ra144.c | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/libavcodec/ra144.c b/libavcodec/ra144.c index a3e0cd5be9..07431bfd08 100644 --- a/libavcodec/ra144.c +++ b/libavcodec/ra144.c @@ -365,7 +365,6 @@ static int ra144_decode_frame(AVCodecContext * avctx, static const uint8_t sizes[10] = {6, 5, 5, 4, 4, 3, 3, 3, 3, 2}; unsigned int a, c; int i; - signed short *shptr; int16_t *data = vdata; unsigned int val; @@ -397,15 +396,12 @@ static int ra144_decode_frame(AVCodecContext * avctx, /* do output */ for (c=0; c<4; c++) { - unsigned int gval = glob->gbuf1[c]; - unsigned short *gsp = glob->gbuf2[c]; - signed short output_buffer[40]; + do_output_subblock(glob, glob->gbuf2[c], glob->gbuf1[c], data, &gb); - do_output_subblock(glob, gsp, gval, output_buffer, &gb); - - shptr = output_buffer; - while (shptr < output_buffer + BLOCKSIZE) - *data++ = av_clip_int16(*(shptr++) << 2); + for (i=0; i<BLOCKSIZE; i++) { + *data = av_clip_int16(*data << 2); + data++; + } } glob->oldval = val; |