diff options
author | Ramiro Polla <ramiro.polla@gmail.com> | 2007-06-02 01:41:07 +0000 |
---|---|---|
committer | Ramiro Polla <ramiro.polla@gmail.com> | 2007-06-02 01:41:07 +0000 |
commit | 2c124cb65c24cc7d0538260726045d68442eef25 (patch) | |
tree | 3752a8d02aa478d977264e8ce0438f49c92a4aca /libavcodec/dsicinav.c | |
parent | 29b29011e5631c4e867baf42258a00886d142841 (diff) | |
download | ffmpeg-2c124cb65c24cc7d0538260726045d68442eef25.tar.gz |
Use AV_xx throughout libavcodec
Originally committed as revision 9169 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/dsicinav.c')
-rw-r--r-- | libavcodec/dsicinav.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/libavcodec/dsicinav.c b/libavcodec/dsicinav.c index 7b4349b703..78cdbe93a9 100644 --- a/libavcodec/dsicinav.c +++ b/libavcodec/dsicinav.c @@ -25,6 +25,7 @@ */ #include "avcodec.h" +#include "bytestream.h" typedef enum CinVideoBitmapIndex { @@ -206,7 +207,7 @@ static int cinvideo_decode_frame(AVCodecContext *avctx, } palette_type = buf[0]; - palette_colors_count = buf[1] | (buf[2] << 8); + palette_colors_count = AV_RL16(buf+1); bitmap_frame_type = buf[3]; buf += 4; @@ -215,13 +216,12 @@ static int cinvideo_decode_frame(AVCodecContext *avctx, /* handle palette */ if (palette_type == 0) { for (i = 0; i < palette_colors_count; ++i) { - cin->palette[i] = (buf[2] << 16) | (buf[1] << 8) | buf[0]; - buf += 3; + cin->palette[i] = bytestream_get_le24(&buf); bitmap_frame_size -= 3; } } else { for (i = 0; i < palette_colors_count; ++i) { - cin->palette[buf[0]] = (buf[3] << 16) | (buf[2] << 8) | buf[1]; + cin->palette[buf[0]] = AV_RL24(buf+1); buf += 4; bitmap_frame_size -= 4; } |