remove c93_ prefix from static functions in c93.c

Originally committed as revision 8674 to svn://svn.ffmpeg.org/ffmpeg/trunk
pull/126/head
Michael Niedermayer 18 years ago
parent 3e62d187ed
commit bee4f778ae
  1. 28
      libavcodec/c93.c

@ -46,13 +46,13 @@ typedef enum {
#define C93_HAS_PALETTE 0x01 #define C93_HAS_PALETTE 0x01
#define C93_FIRST_FRAME 0x02 #define C93_FIRST_FRAME 0x02
static int c93_decode_init(AVCodecContext *avctx) static int decode_init(AVCodecContext *avctx)
{ {
avctx->pix_fmt = PIX_FMT_PAL8; avctx->pix_fmt = PIX_FMT_PAL8;
return 0; return 0;
} }
static int c93_decode_end(AVCodecContext *avctx) static int decode_end(AVCodecContext *avctx)
{ {
C93DecoderContext * const c93 = avctx->priv_data; C93DecoderContext * const c93 = avctx->priv_data;
@ -63,7 +63,7 @@ static int c93_decode_end(AVCodecContext *avctx)
return 0; return 0;
} }
static inline int c93_copy_block(AVCodecContext *avctx, uint8_t *to, static inline int copy_block(AVCodecContext *avctx, uint8_t *to,
uint8_t *from, int offset, int height, int stride) uint8_t *from, int offset, int height, int stride)
{ {
int i; int i;
@ -97,7 +97,7 @@ static inline int c93_copy_block(AVCodecContext *avctx, uint8_t *to,
return 0; return 0;
} }
static inline void c93_draw_n_color(uint8_t *out, int stride, int width, static inline void draw_n_color(uint8_t *out, int stride, int width,
int height, int bpp, uint8_t cols[4], uint8_t grps[4], uint32_t col) int height, int bpp, uint8_t cols[4], uint8_t grps[4], uint32_t col)
{ {
int x, y; int x, y;
@ -113,7 +113,7 @@ static inline void c93_draw_n_color(uint8_t *out, int stride, int width,
} }
} }
static int c93_decode_frame(AVCodecContext *avctx, void *data, static int decode_frame(AVCodecContext *avctx, void *data,
int *data_size, uint8_t * buf, int buf_size) int *data_size, uint8_t * buf, int buf_size)
{ {
C93DecoderContext * const c93 = avctx->priv_data; C93DecoderContext * const c93 = avctx->priv_data;
@ -168,7 +168,7 @@ static int c93_decode_frame(AVCodecContext *avctx, void *data,
switch (bt & 0x0F) { switch (bt & 0x0F) {
case C93_8X8_FROM_PREV: case C93_8X8_FROM_PREV:
offset = bytestream_get_le16(&buf); offset = bytestream_get_le16(&buf);
if (c93_copy_block(avctx, out, copy_from, offset, 8, stride)) if (copy_block(avctx, out, copy_from, offset, 8, stride))
return -1; return -1;
break; break;
@ -178,7 +178,7 @@ static int c93_decode_frame(AVCodecContext *avctx, void *data,
for (j = 0; j < 8; j += 4) { for (j = 0; j < 8; j += 4) {
for (i = 0; i < 8; i += 4) { for (i = 0; i < 8; i += 4) {
offset = bytestream_get_le16(&buf); offset = bytestream_get_le16(&buf);
if (c93_copy_block(avctx, &out[j*stride+i], if (copy_block(avctx, &out[j*stride+i],
copy_from, offset, 4, stride)) copy_from, offset, 4, stride))
return -1; return -1;
} }
@ -188,7 +188,7 @@ static int c93_decode_frame(AVCodecContext *avctx, void *data,
case C93_8X8_2COLOR: case C93_8X8_2COLOR:
bytestream_get_buffer(&buf, cols, 2); bytestream_get_buffer(&buf, cols, 2);
for (i = 0; i < 8; i++) { for (i = 0; i < 8; i++) {
c93_draw_n_color(out + i*stride, stride, 8, 1, 1, cols, draw_n_color(out + i*stride, stride, 8, 1, 1, cols,
NULL, *buf++); NULL, *buf++);
} }
@ -201,15 +201,15 @@ static int c93_decode_frame(AVCodecContext *avctx, void *data,
for (i = 0; i < 8; i += 4) { for (i = 0; i < 8; i += 4) {
if ((bt & 0x0F) == C93_4X4_2COLOR) { if ((bt & 0x0F) == C93_4X4_2COLOR) {
bytestream_get_buffer(&buf, cols, 2); bytestream_get_buffer(&buf, cols, 2);
c93_draw_n_color(out + i + j*stride, stride, 4, 4, draw_n_color(out + i + j*stride, stride, 4, 4,
1, cols, NULL, bytestream_get_le16(&buf)); 1, cols, NULL, bytestream_get_le16(&buf));
} else if ((bt & 0x0F) == C93_4X4_4COLOR) { } else if ((bt & 0x0F) == C93_4X4_4COLOR) {
bytestream_get_buffer(&buf, cols, 4); bytestream_get_buffer(&buf, cols, 4);
c93_draw_n_color(out + i + j*stride, stride, 4, 4, draw_n_color(out + i + j*stride, stride, 4, 4,
2, cols, NULL, bytestream_get_le32(&buf)); 2, cols, NULL, bytestream_get_le32(&buf));
} else { } else {
bytestream_get_buffer(&buf, grps, 4); bytestream_get_buffer(&buf, grps, 4);
c93_draw_n_color(out + i + j*stride, stride, 4, 4, draw_n_color(out + i + j*stride, stride, 4, 4,
1, cols, grps, bytestream_get_le16(&buf)); 1, cols, grps, bytestream_get_le16(&buf));
} }
} }
@ -245,9 +245,9 @@ AVCodec c93_decoder = {
CODEC_TYPE_VIDEO, CODEC_TYPE_VIDEO,
CODEC_ID_C93, CODEC_ID_C93,
sizeof(C93DecoderContext), sizeof(C93DecoderContext),
c93_decode_init, decode_init,
NULL, NULL,
c93_decode_end, decode_end,
c93_decode_frame, decode_frame,
CODEC_CAP_DR1, CODEC_CAP_DR1,
}; };

Loading…
Cancel
Save