#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "avcodec.h"
#include "bytestream.h"
#include "dsputil.h"
#include "get_bits.h"
Go to the source code of this file.
This decoder presently only supports a PAL8 output colorspace.
An Interplay video frame consists of 2 parts: The decoding map and the video data. A demuxer must load these 2 parts together in a single buffer before sending it through the stream to this decoder.
Definition in file interplayvideo.c.
#define ALT_BITSTREAM_READER_LE |
Definition at line 44 of file interplayvideo.c.
#define CHECK_STREAM_PTR | ( | stream_ptr, | |||
stream_end, | |||||
n | ) |
Value:
if (stream_end - stream_ptr < n) { \ av_log(s->avctx, AV_LOG_ERROR, "Interplay video warning: stream_ptr out of bounds (%p >= %p)\n", \ stream_ptr + n, stream_end); \ return -1; \ }
Definition at line 82 of file interplayvideo.c.
Referenced by ipvideo_decode_block_opcode_0x2(), ipvideo_decode_block_opcode_0x3(), ipvideo_decode_block_opcode_0x4(), ipvideo_decode_block_opcode_0x5(), ipvideo_decode_block_opcode_0x6_16(), ipvideo_decode_block_opcode_0x7(), ipvideo_decode_block_opcode_0x7_16(), ipvideo_decode_block_opcode_0x8(), ipvideo_decode_block_opcode_0x8_16(), ipvideo_decode_block_opcode_0x9(), ipvideo_decode_block_opcode_0x9_16(), ipvideo_decode_block_opcode_0xA(), ipvideo_decode_block_opcode_0xA_16(), ipvideo_decode_block_opcode_0xB(), ipvideo_decode_block_opcode_0xB_16(), ipvideo_decode_block_opcode_0xC(), ipvideo_decode_block_opcode_0xC_16(), ipvideo_decode_block_opcode_0xD(), ipvideo_decode_block_opcode_0xD_16(), ipvideo_decode_block_opcode_0xE(), ipvideo_decode_block_opcode_0xE_16(), ipvideo_decode_block_opcode_0xF(), msvideo1_decode_16bit(), msvideo1_decode_8bit(), qtrle_decode_16bpp(), qtrle_decode_1bpp(), qtrle_decode_24bpp(), qtrle_decode_2n4bpp(), qtrle_decode_32bpp(), and qtrle_decode_8bpp().
#define DEBUG_INTERPLAY 0 |
Definition at line 50 of file interplayvideo.c.
#define PALETTE_COUNT 256 |
Definition at line 47 of file interplayvideo.c.
static int copy_from | ( | IpvideoContext * | s, | |
AVFrame * | src, | |||
int | delta_x, | |||
int | delta_y | |||
) | [static] |
Definition at line 89 of file interplayvideo.c.
Referenced by decode_frame(), ipvideo_decode_block_opcode_0x0(), ipvideo_decode_block_opcode_0x1(), ipvideo_decode_block_opcode_0x2(), ipvideo_decode_block_opcode_0x3(), ipvideo_decode_block_opcode_0x4(), ipvideo_decode_block_opcode_0x5(), and ipvideo_decode_block_opcode_0x6_16().
static void debug_interplay | ( | const char * | format, | |
... | ||||
) | [inline, static] |
Definition at line 54 of file interplayvideo.c.
Referenced by ipvideo_decode_block_opcode_0x2(), ipvideo_decode_block_opcode_0x3(), ipvideo_decode_block_opcode_0x4(), ipvideo_decode_block_opcode_0x5(), ipvideo_decode_block_opcode_0x6_16(), and ipvideo_decode_opcodes().
static int ipvideo_decode_block_opcode_0x0 | ( | IpvideoContext * | s | ) | [static] |
Definition at line 107 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0x1 | ( | IpvideoContext * | s | ) | [static] |
Definition at line 112 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0x2 | ( | IpvideoContext * | s | ) | [static] |
Definition at line 117 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0x3 | ( | IpvideoContext * | s | ) | [static] |
Definition at line 143 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0x4 | ( | IpvideoContext * | s | ) | [static] |
Definition at line 171 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0x5 | ( | IpvideoContext * | s | ) | [static] |
Definition at line 194 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0x6 | ( | IpvideoContext * | s | ) | [static] |
Definition at line 209 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0x6_16 | ( | IpvideoContext * | s | ) | [static] |
Definition at line 576 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0x7 | ( | IpvideoContext * | s | ) | [static] |
Definition at line 218 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0x7_16 | ( | IpvideoContext * | s | ) | [static] |
Definition at line 590 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0x8 | ( | IpvideoContext * | s | ) | [static] |
Definition at line 263 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0x8_16 | ( | IpvideoContext * | s | ) | [static] |
Definition at line 633 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0x9 | ( | IpvideoContext * | s | ) | [static] |
Definition at line 340 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0x9_16 | ( | IpvideoContext * | s | ) | [static] |
Definition at line 712 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0xA | ( | IpvideoContext * | s | ) | [static] |
Definition at line 414 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0xA_16 | ( | IpvideoContext * | s | ) | [static] |
Definition at line 787 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0xB | ( | IpvideoContext * | s | ) | [static] |
Definition at line 476 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0xB_16 | ( | IpvideoContext * | s | ) | [static] |
Definition at line 850 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0xC | ( | IpvideoContext * | s | ) | [static] |
Definition at line 493 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0xC_16 | ( | IpvideoContext * | s | ) | [static] |
Definition at line 868 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0xD | ( | IpvideoContext * | s | ) | [static] |
Definition at line 514 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0xD_16 | ( | IpvideoContext * | s | ) | [static] |
Definition at line 890 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0xE | ( | IpvideoContext * | s | ) | [static] |
Definition at line 536 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0xE_16 | ( | IpvideoContext * | s | ) | [static] |
Definition at line 913 of file interplayvideo.c.
static int ipvideo_decode_block_opcode_0xF | ( | IpvideoContext * | s | ) | [static] |
Definition at line 554 of file interplayvideo.c.
static av_cold int ipvideo_decode_end | ( | AVCodecContext * | avctx | ) | [static] |
Definition at line 1083 of file interplayvideo.c.
static int ipvideo_decode_frame | ( | AVCodecContext * | avctx, | |
void * | data, | |||
int * | data_size, | |||
AVPacket * | avpkt | |||
) | [static] |
Definition at line 1038 of file interplayvideo.c.
static av_cold int ipvideo_decode_init | ( | AVCodecContext * | avctx | ) | [static] |
Definition at line 1014 of file interplayvideo.c.
static void ipvideo_decode_opcodes | ( | IpvideoContext * | s | ) | [static] |
Initial value:
{ "interplayvideo", AVMEDIA_TYPE_VIDEO, CODEC_ID_INTERPLAY_VIDEO, sizeof(IpvideoContext), ipvideo_decode_init, NULL, ipvideo_decode_end, ipvideo_decode_frame, CODEC_CAP_DR1, .long_name = NULL_IF_CONFIG_SMALL("Interplay MVE video"), }
Definition at line 1096 of file interplayvideo.c.
int(* const ipvideo_decode_block[])(IpvideoContext *s) [static] |
Initial value:
{ ipvideo_decode_block_opcode_0x0, ipvideo_decode_block_opcode_0x1, ipvideo_decode_block_opcode_0x2, ipvideo_decode_block_opcode_0x3, ipvideo_decode_block_opcode_0x4, ipvideo_decode_block_opcode_0x5, ipvideo_decode_block_opcode_0x6, ipvideo_decode_block_opcode_0x7, ipvideo_decode_block_opcode_0x8, ipvideo_decode_block_opcode_0x9, ipvideo_decode_block_opcode_0xA, ipvideo_decode_block_opcode_0xB, ipvideo_decode_block_opcode_0xC, ipvideo_decode_block_opcode_0xD, ipvideo_decode_block_opcode_0xE, ipvideo_decode_block_opcode_0xF, }
Referenced by ipvideo_decode_opcodes().
int(* const ipvideo_decode_block16[])(IpvideoContext *s) [static] |
Initial value:
{ ipvideo_decode_block_opcode_0x0, ipvideo_decode_block_opcode_0x1, ipvideo_decode_block_opcode_0x2, ipvideo_decode_block_opcode_0x3, ipvideo_decode_block_opcode_0x4, ipvideo_decode_block_opcode_0x5, ipvideo_decode_block_opcode_0x6_16, ipvideo_decode_block_opcode_0x7_16, ipvideo_decode_block_opcode_0x8_16, ipvideo_decode_block_opcode_0x9_16, ipvideo_decode_block_opcode_0xA_16, ipvideo_decode_block_opcode_0xB_16, ipvideo_decode_block_opcode_0xC_16, ipvideo_decode_block_opcode_0xD_16, ipvideo_decode_block_opcode_0xE_16, ipvideo_decode_block_opcode_0x1, }
Referenced by ipvideo_decode_opcodes().