FFmpeg
Data Structures | Macros | Functions | Variables
aadec.c File Reference
#include "avformat.h"
#include "demux.h"
#include "internal.h"
#include "libavutil/avstring.h"
#include "libavutil/dict.h"
#include "libavutil/intreadwrite.h"
#include "libavutil/mem.h"
#include "libavutil/tea.h"
#include "libavutil/opt.h"

Go to the source code of this file.

Data Structures

struct  AADemuxContext
 

Macros

#define AA_MAGIC   1469084982 /* this identifies an audible .aa file */
 
#define MAX_TOC_ENTRIES   16
 
#define MAX_DICTIONARY_ENTRIES   128
 
#define TEA_BLOCK_SIZE   8
 
#define CHAPTER_HEADER_SIZE   8
 
#define TIMEPREC   1000
 
#define MP3_FRAME_SIZE   104
 
#define OFFSET(x)   offsetof(AADemuxContext, x)
 

Functions

static int get_second_size (char *codec_name)
 
static int aa_read_header (AVFormatContext *s)
 
static int aa_read_packet (AVFormatContext *s, AVPacket *pkt)
 
static int aa_read_seek (AVFormatContext *s, int stream_index, int64_t timestamp, int flags)
 
static int aa_probe (const AVProbeData *p)
 
static int aa_read_close (AVFormatContext *s)
 

Variables

static const AVOption aa_options []
 
static const AVClass aa_class
 
const FFInputFormat ff_aa_demuxer
 

Macro Definition Documentation

◆ AA_MAGIC

#define AA_MAGIC   1469084982 /* this identifies an audible .aa file */

Definition at line 36 of file aadec.c.

◆ MAX_TOC_ENTRIES

#define MAX_TOC_ENTRIES   16

Definition at line 37 of file aadec.c.

◆ MAX_DICTIONARY_ENTRIES

#define MAX_DICTIONARY_ENTRIES   128

Definition at line 38 of file aadec.c.

◆ TEA_BLOCK_SIZE

#define TEA_BLOCK_SIZE   8

Definition at line 39 of file aadec.c.

◆ CHAPTER_HEADER_SIZE

#define CHAPTER_HEADER_SIZE   8

Definition at line 40 of file aadec.c.

◆ TIMEPREC

#define TIMEPREC   1000

Definition at line 41 of file aadec.c.

◆ MP3_FRAME_SIZE

#define MP3_FRAME_SIZE   104

Definition at line 42 of file aadec.c.

◆ OFFSET

#define OFFSET (   x)    offsetof(AADemuxContext, x)

Definition at line 359 of file aadec.c.

Function Documentation

◆ get_second_size()

static int get_second_size ( char *  codec_name)
static

Definition at line 59 of file aadec.c.

Referenced by aa_read_header().

◆ aa_read_header()

static int aa_read_header ( AVFormatContext s)
static

Definition at line 74 of file aadec.c.

◆ aa_read_packet()

static int aa_read_packet ( AVFormatContext s,
AVPacket pkt 
)
static

Definition at line 238 of file aadec.c.

◆ aa_read_seek()

static int aa_read_seek ( AVFormatContext s,
int  stream_index,
int64_t  timestamp,
int  flags 
)
static

Definition at line 289 of file aadec.c.

◆ aa_probe()

static int aa_probe ( const AVProbeData p)
static

Definition at line 339 of file aadec.c.

◆ aa_read_close()

static int aa_read_close ( AVFormatContext s)
static

Definition at line 350 of file aadec.c.

Variable Documentation

◆ aa_options

const AVOption aa_options[]
static
Initial value:
= {
{ "aa_fixed_key",
"Fixed key used for handling Audible AA files", OFFSET(aa_fixed_key),
AV_OPT_TYPE_BINARY, {.str="77214d4b196a87cd520045fd2a51d673"},
{ NULL },
}

Definition at line 360 of file aadec.c.

◆ aa_class

const AVClass aa_class
static
Initial value:
= {
.class_name = "aa",
.item_name = av_default_item_name,
.option = aa_options,
}

Definition at line 368 of file aadec.c.

◆ ff_aa_demuxer

const FFInputFormat ff_aa_demuxer
Initial value:
= {
.p.name = "aa",
.p.long_name = NULL_IF_CONFIG_SMALL("Audible AA format files"),
.p.priv_class = &aa_class,
.p.extensions = "aa",
.priv_data_size = sizeof(AADemuxContext),
.flags_internal = FF_INFMT_FLAG_INIT_CLEANUP,
}

Definition at line 375 of file aadec.c.

AVFMT_NO_BYTE_SEEK
#define AVFMT_NO_BYTE_SEEK
Format does not allow seeking by bytes.
Definition: avformat.h:487
aa_read_packet
static int aa_read_packet(AVFormatContext *s, AVPacket *pkt)
Definition: aadec.c:238
aa_read_seek
static int aa_read_seek(AVFormatContext *s, int stream_index, int64_t timestamp, int flags)
Definition: aadec.c:289
aa_read_close
static int aa_read_close(AVFormatContext *s)
Definition: aadec.c:350
aa_class
static const AVClass aa_class
Definition: aadec.c:368
AV_OPT_TYPE_BINARY
@ AV_OPT_TYPE_BINARY
Underlying C type is a uint8_t* that is either NULL or points to an array allocated with the av_mallo...
Definition: opt.h:286
read_seek
static int read_seek(AVFormatContext *ctx, int stream_index, int64_t timestamp, int flags)
Definition: libcdio.c:151
read_close
static av_cold int read_close(AVFormatContext *ctx)
Definition: libcdio.c:143
read_packet
static int read_packet(void *opaque, uint8_t *buf, int buf_size)
Definition: avio_read_callback.c:42
aa_options
static const AVOption aa_options[]
Definition: aadec.c:360
aa_probe
static int aa_probe(const AVProbeData *p)
Definition: aadec.c:339
FF_INFMT_FLAG_INIT_CLEANUP
#define FF_INFMT_FLAG_INIT_CLEANUP
For an FFInputFormat with this flag set read_close() needs to be called by the caller upon read_heade...
Definition: demux.h:35
LIBAVUTIL_VERSION_INT
#define LIBAVUTIL_VERSION_INT
Definition: version.h:85
read_header
static int read_header(FFV1Context *f)
Definition: ffv1dec.c:540
NULL
#define NULL
Definition: coverity.c:32
av_default_item_name
const char * av_default_item_name(void *ptr)
Return the context name.
Definition: log.c:237
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:94
aa_read_header
static int aa_read_header(AVFormatContext *s)
Definition: aadec.c:74
OFFSET
#define OFFSET(x)
Definition: aadec.c:359
AVFMT_NOGENSEARCH
#define AVFMT_NOGENSEARCH
Format does not allow to fall back on generic search.
Definition: avformat.h:486
AV_OPT_FLAG_DECODING_PARAM
#define AV_OPT_FLAG_DECODING_PARAM
A generic parameter which can be set by the user for demuxing or decoding.
Definition: opt.h:356
read_probe
static int read_probe(const AVProbeData *p)
Definition: cdg.c:30
AADemuxContext
Definition: aadec.c:44