FFmpeg
Data Structures | Macros | Functions | Variables
wc3movie.c File Reference
#include "libavutil/avstring.h"
#include "libavutil/channel_layout.h"
#include "libavutil/intreadwrite.h"
#include "libavutil/dict.h"
#include "avformat.h"
#include "internal.h"

Go to the source code of this file.

Data Structures

struct  Wc3DemuxContext
 

Macros

#define FORM_TAG   MKTAG('F', 'O', 'R', 'M')
 
#define MOVE_TAG   MKTAG('M', 'O', 'V', 'E')
 
#define PC__TAG   MKTAG('_', 'P', 'C', '_')
 
#define SOND_TAG   MKTAG('S', 'O', 'N', 'D')
 
#define BNAM_TAG   MKTAG('B', 'N', 'A', 'M')
 
#define SIZE_TAG   MKTAG('S', 'I', 'Z', 'E')
 
#define PALT_TAG   MKTAG('P', 'A', 'L', 'T')
 
#define INDX_TAG   MKTAG('I', 'N', 'D', 'X')
 
#define BRCH_TAG   MKTAG('B', 'R', 'C', 'H')
 
#define SHOT_TAG   MKTAG('S', 'H', 'O', 'T')
 
#define VGA__TAG   MKTAG('V', 'G', 'A', ' ')
 
#define TEXT_TAG   MKTAG('T', 'E', 'X', 'T')
 
#define AUDI_TAG   MKTAG('A', 'U', 'D', 'I')
 
#define WC3_DEFAULT_WIDTH   320
 
#define WC3_DEFAULT_HEIGHT   165
 
#define WC3_SAMPLE_RATE   22050
 
#define WC3_AUDIO_CHANNELS   1
 
#define WC3_AUDIO_BITS   16
 
#define WC3_FRAME_FPS   15
 
#define PALETTE_SIZE   (256 * 3)
 

Functions

static int wc3_read_close (AVFormatContext *s)
 
static int wc3_probe (const AVProbeData *p)
 
static int wc3_read_header (AVFormatContext *s)
 
static int wc3_read_packet (AVFormatContext *s, AVPacket *pkt)
 

Variables

const AVInputFormat ff_wc3_demuxer
 

Detailed Description

Wing Commander III Movie file demuxer by Mike Melanson (melan.nosp@m.son@.nosp@m.pcisy.nosp@m.s.ne.nosp@m.t) for more information on the WC3 .mve file format, visit: http://www.pcisys.net/~melanson/codecs/

Definition in file wc3movie.c.

Macro Definition Documentation

◆ FORM_TAG

#define FORM_TAG   MKTAG('F', 'O', 'R', 'M')

Definition at line 37 of file wc3movie.c.

◆ MOVE_TAG

#define MOVE_TAG   MKTAG('M', 'O', 'V', 'E')

Definition at line 38 of file wc3movie.c.

◆ PC__TAG

#define PC__TAG   MKTAG('_', 'P', 'C', '_')

Definition at line 39 of file wc3movie.c.

◆ SOND_TAG

#define SOND_TAG   MKTAG('S', 'O', 'N', 'D')

Definition at line 40 of file wc3movie.c.

◆ BNAM_TAG

#define BNAM_TAG   MKTAG('B', 'N', 'A', 'M')

Definition at line 41 of file wc3movie.c.

◆ SIZE_TAG

#define SIZE_TAG   MKTAG('S', 'I', 'Z', 'E')

Definition at line 42 of file wc3movie.c.

◆ PALT_TAG

#define PALT_TAG   MKTAG('P', 'A', 'L', 'T')

Definition at line 43 of file wc3movie.c.

◆ INDX_TAG

#define INDX_TAG   MKTAG('I', 'N', 'D', 'X')

Definition at line 44 of file wc3movie.c.

◆ BRCH_TAG

#define BRCH_TAG   MKTAG('B', 'R', 'C', 'H')

Definition at line 45 of file wc3movie.c.

◆ SHOT_TAG

#define SHOT_TAG   MKTAG('S', 'H', 'O', 'T')

Definition at line 46 of file wc3movie.c.

◆ VGA__TAG

#define VGA__TAG   MKTAG('V', 'G', 'A', ' ')

Definition at line 47 of file wc3movie.c.

◆ TEXT_TAG

#define TEXT_TAG   MKTAG('T', 'E', 'X', 'T')

Definition at line 48 of file wc3movie.c.

◆ AUDI_TAG

#define AUDI_TAG   MKTAG('A', 'U', 'D', 'I')

Definition at line 49 of file wc3movie.c.

◆ WC3_DEFAULT_WIDTH

#define WC3_DEFAULT_WIDTH   320

Definition at line 52 of file wc3movie.c.

◆ WC3_DEFAULT_HEIGHT

#define WC3_DEFAULT_HEIGHT   165

Definition at line 53 of file wc3movie.c.

◆ WC3_SAMPLE_RATE

#define WC3_SAMPLE_RATE   22050

Definition at line 56 of file wc3movie.c.

◆ WC3_AUDIO_CHANNELS

#define WC3_AUDIO_CHANNELS   1

Definition at line 57 of file wc3movie.c.

◆ WC3_AUDIO_BITS

#define WC3_AUDIO_BITS   16

Definition at line 58 of file wc3movie.c.

◆ WC3_FRAME_FPS

#define WC3_FRAME_FPS   15

Definition at line 61 of file wc3movie.c.

◆ PALETTE_SIZE

#define PALETTE_SIZE   (256 * 3)

Definition at line 63 of file wc3movie.c.

Function Documentation

◆ wc3_read_close()

static int wc3_read_close ( AVFormatContext s)
static

Definition at line 76 of file wc3movie.c.

◆ wc3_probe()

static int wc3_probe ( const AVProbeData p)
static

Definition at line 85 of file wc3movie.c.

◆ wc3_read_header()

static int wc3_read_header ( AVFormatContext s)
static

Definition at line 97 of file wc3movie.c.

◆ wc3_read_packet()

static int wc3_read_packet ( AVFormatContext s,
AVPacket pkt 
)
static

Definition at line 209 of file wc3movie.c.

Variable Documentation

◆ ff_wc3_demuxer

const AVInputFormat ff_wc3_demuxer
Initial value:
= {
.name = "wc3movie",
.long_name = NULL_IF_CONFIG_SMALL("Wing Commander III movie"),
.priv_data_size = sizeof(Wc3DemuxContext),
.flags_internal = FF_FMT_INIT_CLEANUP,
}

Definition at line 298 of file wc3movie.c.

FF_FMT_INIT_CLEANUP
#define FF_FMT_INIT_CLEANUP
For an AVInputFormat with this flag set read_close() needs to be called by the caller upon read_heade...
Definition: internal.h:49
Wc3DemuxContext
Definition: wc3movie.c:65
wc3_read_header
static int wc3_read_header(AVFormatContext *s)
Definition: wc3movie.c:97
read_close
static av_cold int read_close(AVFormatContext *ctx)
Definition: libcdio.c:141
read_header
static int read_header(FFV1Context *f)
Definition: ffv1dec.c:527
read_probe
static int read_probe(const AVProbeData *pd)
Definition: jvdec.c:55
NULL_IF_CONFIG_SMALL
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification.
Definition: internal.h:117
wc3_probe
static int wc3_probe(const AVProbeData *p)
Definition: wc3movie.c:85
wc3_read_packet
static int wc3_read_packet(AVFormatContext *s, AVPacket *pkt)
Definition: wc3movie.c:209
wc3_read_close
static int wc3_read_close(AVFormatContext *s)
Definition: wc3movie.c:76
read_packet
static int read_packet(void *opaque, uint8_t *buf, int buf_size)
Definition: avio_reading.c:42