FFmpeg
Data Structures | Macros | Enumerations | Functions | Variables
pp_bnk.c File Reference
#include "avformat.h"
#include "internal.h"
#include "libavutil/intreadwrite.h"
#include "libavutil/avassert.h"
#include "libavutil/channel_layout.h"
#include "libavutil/internal.h"

Go to the source code of this file.

Data Structures

struct  PPBnkHeader
 
struct  PPBnkTrack
 
struct  PPBnkCtxTrack
 
struct  PPBnkCtx
 

Macros

#define PP_BNK_MAX_READ_SIZE   4096
 
#define PP_BNK_FILE_HEADER_SIZE   20
 
#define PP_BNK_TRACK_SIZE   20
 

Enumerations

enum  { PP_BNK_FLAG_PERSIST = (1 << 0), PP_BNK_FLAG_MUSIC = (1 << 1), PP_BNK_FLAG_MASK = (PP_BNK_FLAG_PERSIST | PP_BNK_FLAG_MUSIC) }
 

Functions

static void pp_bnk_parse_header (PPBnkHeader *hdr, const uint8_t *buf)
 
static void pp_bnk_parse_track (PPBnkTrack *trk, const uint8_t *buf)
 
static int pp_bnk_probe (const AVProbeData *p)
 
static int pp_bnk_read_header (AVFormatContext *s)
 
static int pp_bnk_read_packet (AVFormatContext *s, AVPacket *pkt)
 
static int pp_bnk_read_close (AVFormatContext *s)
 
static int pp_bnk_seek (AVFormatContext *s, int stream_index, int64_t pts, int flags)
 

Variables

const AVInputFormat ff_pp_bnk_demuxer
 

Macro Definition Documentation

◆ PP_BNK_MAX_READ_SIZE

#define PP_BNK_MAX_READ_SIZE   4096

Definition at line 29 of file pp_bnk.c.

◆ PP_BNK_FILE_HEADER_SIZE

#define PP_BNK_FILE_HEADER_SIZE   20

Definition at line 30 of file pp_bnk.c.

◆ PP_BNK_TRACK_SIZE

#define PP_BNK_TRACK_SIZE   20

Definition at line 31 of file pp_bnk.c.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
PP_BNK_FLAG_PERSIST 
PP_BNK_FLAG_MUSIC 
PP_BNK_FLAG_MASK 

Definition at line 62 of file pp_bnk.c.

Function Documentation

◆ pp_bnk_parse_header()

static void pp_bnk_parse_header ( PPBnkHeader hdr,
const uint8_t *  buf 
)
static

Definition at line 68 of file pp_bnk.c.

Referenced by pp_bnk_read_header().

◆ pp_bnk_parse_track()

static void pp_bnk_parse_track ( PPBnkTrack trk,
const uint8_t *  buf 
)
static

Definition at line 77 of file pp_bnk.c.

Referenced by pp_bnk_read_header().

◆ pp_bnk_probe()

static int pp_bnk_probe ( const AVProbeData p)
static

Definition at line 86 of file pp_bnk.c.

◆ pp_bnk_read_header()

static int pp_bnk_read_header ( AVFormatContext s)
static

Definition at line 109 of file pp_bnk.c.

◆ pp_bnk_read_packet()

static int pp_bnk_read_packet ( AVFormatContext s,
AVPacket pkt 
)
static

Definition at line 229 of file pp_bnk.c.

◆ pp_bnk_read_close()

static int pp_bnk_read_close ( AVFormatContext s)
static

Definition at line 296 of file pp_bnk.c.

◆ pp_bnk_seek()

static int pp_bnk_seek ( AVFormatContext s,
int  stream_index,
int64_t  pts,
int  flags 
)
static

Definition at line 305 of file pp_bnk.c.

Variable Documentation

◆ ff_pp_bnk_demuxer

const AVInputFormat ff_pp_bnk_demuxer
Initial value:
= {
.name = "pp_bnk",
.long_name = NULL_IF_CONFIG_SMALL("Pro Pinball Series Soundbank"),
.priv_data_size = sizeof(PPBnkCtx),
.flags_internal = FF_FMT_INIT_CLEANUP,
}

Definition at line 324 of file pp_bnk.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:48
pp_bnk_seek
static int pp_bnk_seek(AVFormatContext *s, int stream_index, int64_t pts, int flags)
Definition: pp_bnk.c:305
read_seek
static int read_seek(AVFormatContext *ctx, int stream_index, int64_t timestamp, int flags)
Definition: libcdio.c:149
read_close
static av_cold int read_close(AVFormatContext *ctx)
Definition: libcdio.c:141
pp_bnk_probe
static int pp_bnk_probe(const AVProbeData *p)
Definition: pp_bnk.c:86
pp_bnk_read_close
static int pp_bnk_read_close(AVFormatContext *s)
Definition: pp_bnk.c:296
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
PPBnkCtx
Definition: pp_bnk.c:55
pp_bnk_read_header
static int pp_bnk_read_header(AVFormatContext *s)
Definition: pp_bnk.c:109
read_packet
static int read_packet(void *opaque, uint8_t *buf, int buf_size)
Definition: avio_reading.c:42
pp_bnk_read_packet
static int pp_bnk_read_packet(AVFormatContext *s, AVPacket *pkt)
Definition: pp_bnk.c:229