From 2c124cb65c24cc7d0538260726045d68442eef25 Mon Sep 17 00:00:00 2001 From: Ramiro Polla Date: Sat, 2 Jun 2007 01:41:07 +0000 Subject: Use AV_xx throughout libavcodec Originally committed as revision 9169 to svn://svn.ffmpeg.org/ffmpeg/trunk --- libavcodec/kmvc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'libavcodec/kmvc.c') diff --git a/libavcodec/kmvc.c b/libavcodec/kmvc.c index 573f10c80d..c56b62ca2f 100644 --- a/libavcodec/kmvc.c +++ b/libavcodec/kmvc.c @@ -29,6 +29,7 @@ #include #include "avcodec.h" +#include "bytestream.h" #define KMVC_KEYFRAME 0x80 #define KMVC_PALETTE 0x40 @@ -249,7 +250,7 @@ static int decode_frame(AVCodecContext * avctx, void *data, int *data_size, uint if (buf[0] == 127) { buf += 3; for (i = 0; i < 127; i++) { - ctx->pal[i + (header & 0x81)] = (buf[0] << 16) | (buf[1] << 8) | buf[2]; + ctx->pal[i + (header & 0x81)] = AV_RB24(buf); buf += 4; } buf -= 127 * 4 + 3; @@ -274,8 +275,7 @@ static int decode_frame(AVCodecContext * avctx, void *data, int *data_size, uint ctx->pic.palette_has_changed = 1; // palette starts from index 1 and has 127 entries for (i = 1; i <= ctx->palsize; i++) { - ctx->pal[i] = (buf[0] << 16) | (buf[1] << 8) | buf[2]; - buf += 3; + ctx->pal[i] = bytestream_get_be24(&buf); } } -- cgit v1.2.3