FFmpeg
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions | Variables
ipmovie.c File Reference

Interplay MVE file demuxer by Mike Melanson (melan.nosp@m.son@.nosp@m.pcisy.nosp@m.s.ne.nosp@m.t) For more information regarding the Interplay MVE file format, visit: http://www.pcisys.net/~melanson/codecs/ The aforementioned site also contains a command line utility for parsing IP MVE files so that you can get a good idea of the typical structure of such files. More...

#include "libavutil/channel_layout.h"
#include "libavutil/intreadwrite.h"
#include "avformat.h"
#include "internal.h"

Go to the source code of this file.

Data Structures

struct  IPMVEContext
 

Macros

#define CHUNK_PREAMBLE_SIZE   4
 
#define OPCODE_PREAMBLE_SIZE   4
 
#define CHUNK_INIT_AUDIO   0x0000
 
#define CHUNK_AUDIO_ONLY   0x0001
 
#define CHUNK_INIT_VIDEO   0x0002
 
#define CHUNK_VIDEO   0x0003
 
#define CHUNK_SHUTDOWN   0x0004
 
#define CHUNK_END   0x0005
 
#define CHUNK_DONE   0xFFFC
 
#define CHUNK_NOMEM   0xFFFD
 
#define CHUNK_EOF   0xFFFE
 
#define CHUNK_BAD   0xFFFF
 
#define OPCODE_END_OF_STREAM   0x00
 
#define OPCODE_END_OF_CHUNK   0x01
 
#define OPCODE_CREATE_TIMER   0x02
 
#define OPCODE_INIT_AUDIO_BUFFERS   0x03
 
#define OPCODE_START_STOP_AUDIO   0x04
 
#define OPCODE_INIT_VIDEO_BUFFERS   0x05
 
#define OPCODE_UNKNOWN_06   0x06
 
#define OPCODE_SEND_BUFFER   0x07
 
#define OPCODE_AUDIO_FRAME   0x08
 
#define OPCODE_SILENCE_FRAME   0x09
 
#define OPCODE_INIT_VIDEO_MODE   0x0A
 
#define OPCODE_CREATE_GRADIENT   0x0B
 
#define OPCODE_SET_PALETTE   0x0C
 
#define OPCODE_SET_PALETTE_COMPRESSED   0x0D
 
#define OPCODE_UNKNOWN_0E   0x0E
 
#define OPCODE_SET_DECODING_MAP   0x0F
 
#define OPCODE_UNKNOWN_10   0x10
 
#define OPCODE_VIDEO_DATA   0x11
 
#define OPCODE_UNKNOWN_12   0x12
 
#define OPCODE_UNKNOWN_13   0x13
 
#define OPCODE_UNKNOWN_14   0x14
 
#define OPCODE_UNKNOWN_15   0x15
 
#define PALETTE_COUNT   256
 

Functions

static int load_ipmovie_packet (IPMVEContext *s, AVIOContext *pb, AVPacket *pkt)
 
static int process_ipmovie_chunk (IPMVEContext *s, AVIOContext *pb, AVPacket *pkt)
 
static int ipmovie_probe (AVProbeData *p)
 
static int ipmovie_read_header (AVFormatContext *s)
 
static int ipmovie_read_packet (AVFormatContext *s, AVPacket *pkt)
 

Variables

static const char signature [] = "Interplay MVE File\x1A\0\x1A"
 
AVInputFormat ff_ipmovie_demuxer
 

Detailed Description

Interplay MVE file demuxer by Mike Melanson (melan.nosp@m.son@.nosp@m.pcisy.nosp@m.s.ne.nosp@m.t) For more information regarding the Interplay MVE file format, visit: http://www.pcisys.net/~melanson/codecs/ The aforementioned site also contains a command line utility for parsing IP MVE files so that you can get a good idea of the typical structure of such files.

This demuxer is not the best example to use if you are trying to write your own as it uses a rather roundabout approach for splitting up and sending out the chunks.

Definition in file ipmovie.c.

Macro Definition Documentation

#define CHUNK_PREAMBLE_SIZE   4

Definition at line 40 of file ipmovie.c.

Referenced by ipmovie_read_header(), and process_ipmovie_chunk().

#define OPCODE_PREAMBLE_SIZE   4

Definition at line 41 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define CHUNK_INIT_AUDIO   0x0000

Definition at line 43 of file ipmovie.c.

Referenced by ipmovie_read_header(), ipmovie_read_packet(), and process_ipmovie_chunk().

#define CHUNK_AUDIO_ONLY   0x0001

Definition at line 44 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define CHUNK_INIT_VIDEO   0x0002

Definition at line 45 of file ipmovie.c.

Referenced by ipmovie_read_header(), ipmovie_read_packet(), and process_ipmovie_chunk().

#define CHUNK_VIDEO   0x0003
#define CHUNK_SHUTDOWN   0x0004

Definition at line 47 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define CHUNK_END   0x0005

Definition at line 48 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define CHUNK_DONE   0xFFFC

Definition at line 50 of file ipmovie.c.

Referenced by load_ipmovie_packet(), and process_ipmovie_chunk().

#define CHUNK_NOMEM   0xFFFD

Definition at line 51 of file ipmovie.c.

Referenced by ipmovie_read_packet(), and load_ipmovie_packet().

#define CHUNK_EOF   0xFFFE

Definition at line 52 of file ipmovie.c.

Referenced by ipmovie_read_packet(), load_ipmovie_packet(), and process_ipmovie_chunk().

#define CHUNK_BAD   0xFFFF

Definition at line 53 of file ipmovie.c.

Referenced by ipmovie_read_packet(), load_ipmovie_packet(), and process_ipmovie_chunk().

#define OPCODE_END_OF_STREAM   0x00

Definition at line 55 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_END_OF_CHUNK   0x01

Definition at line 56 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_CREATE_TIMER   0x02

Definition at line 57 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_INIT_AUDIO_BUFFERS   0x03

Definition at line 58 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_START_STOP_AUDIO   0x04

Definition at line 59 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_INIT_VIDEO_BUFFERS   0x05

Definition at line 60 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_UNKNOWN_06   0x06

Definition at line 61 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_SEND_BUFFER   0x07

Definition at line 62 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_AUDIO_FRAME   0x08

Definition at line 63 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_SILENCE_FRAME   0x09

Definition at line 64 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_INIT_VIDEO_MODE   0x0A

Definition at line 65 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_CREATE_GRADIENT   0x0B

Definition at line 66 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_SET_PALETTE   0x0C

Definition at line 67 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_SET_PALETTE_COMPRESSED   0x0D

Definition at line 68 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_UNKNOWN_0E   0x0E

Definition at line 69 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_SET_DECODING_MAP   0x0F

Definition at line 70 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_UNKNOWN_10   0x10

Definition at line 71 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_VIDEO_DATA   0x11

Definition at line 72 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_UNKNOWN_12   0x12

Definition at line 73 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_UNKNOWN_13   0x13

Definition at line 74 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_UNKNOWN_14   0x14

Definition at line 75 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define OPCODE_UNKNOWN_15   0x15

Definition at line 76 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

#define PALETTE_COUNT   256

Definition at line 78 of file ipmovie.c.

Function Documentation

static int load_ipmovie_packet ( IPMVEContext s,
AVIOContext pb,
AVPacket pkt 
)
static

Definition at line 115 of file ipmovie.c.

Referenced by process_ipmovie_chunk().

static int process_ipmovie_chunk ( IPMVEContext s,
AVIOContext pb,
AVPacket pkt 
)
static

Definition at line 217 of file ipmovie.c.

Referenced by ipmovie_read_header(), and ipmovie_read_packet().

static int ipmovie_probe ( AVProbeData p)
static

Definition at line 528 of file ipmovie.c.

static int ipmovie_read_header ( AVFormatContext s)
static

Definition at line 541 of file ipmovie.c.

static int ipmovie_read_packet ( AVFormatContext s,
AVPacket pkt 
)
static

Definition at line 623 of file ipmovie.c.

Variable Documentation

const char signature[] = "Interplay MVE File\x1A\0\x1A"
static

Definition at line 526 of file ipmovie.c.

Referenced by ipmovie_probe(), ipmovie_read_header(), rl2_read_header(), and rtmp_handshake().

AVInputFormat ff_ipmovie_demuxer
Initial value:
= {
.name = "ipmovie",
.long_name = NULL_IF_CONFIG_SMALL("Interplay MVE"),
.priv_data_size = sizeof(IPMVEContext),
}

Definition at line 649 of file ipmovie.c.