FFmpeg
Loading...
Searching...
No Matches
amr_parser.c File Reference

AMR audio parser. More...

Go to the source code of this file.

Data Structures

struct  AMRParseContext
 

Functions

static av_cold int amr_parse_init (AVCodecParserContext *s1)
 
static int amr_parse (AVCodecParserContext *s1, AVCodecContext *avctx, const uint8_t **poutbuf, int *poutbuf_size, const uint8_t *buf, int buf_size)
 

Variables

static const uint8_t amrnb_packed_size [16]
 
static const uint8_t amrwb_packed_size [16]
 
const FFCodecParser ff_amr_parser
 

Detailed Description

AMR audio parser.

Splits packets into individual blocks.

Definition in file amr_parser.c.

Function Documentation

◆ amr_parse_init()

static av_cold int amr_parse_init ( AVCodecParserContext * s1)
static

Definition at line 48 of file amr_parser.c.

◆ amr_parse()

static int amr_parse ( AVCodecParserContext * s1,
AVCodecContext * avctx,
const uint8_t ** poutbuf,
int * poutbuf_size,
const uint8_t * buf,
int buf_size )
static

Definition at line 55 of file amr_parser.c.

Variable Documentation

◆ amrnb_packed_size

const uint8_t amrnb_packed_size[16]
static
Initial value:
= {
13, 14, 16, 18, 20, 21, 27, 32, 6, 1, 1, 1, 1, 1, 1, 1
}

Definition at line 33 of file amr_parser.c.

Referenced by amr_parse().

◆ amrwb_packed_size

const uint8_t amrwb_packed_size[16]
static
Initial value:
= {
18, 24, 33, 37, 41, 47, 51, 59, 61, 6, 1, 1, 1, 1, 1, 1
}

Definition at line 36 of file amr_parser.c.

Referenced by amr_parse().

◆ ff_amr_parser

const FFCodecParser ff_amr_parser
Initial value:
= {
.priv_data_size = sizeof(AMRParseContext),
}
static int amr_parse(AVCodecParserContext *s1, AVCodecContext *avctx, const uint8_t **poutbuf, int *poutbuf_size, const uint8_t *buf, int buf_size)
Definition amr_parser.c:55
static av_cold int amr_parse_init(AVCodecParserContext *s1)
Definition amr_parser.c:48
static int parse(AVCodecParserContext *s, AVCodecContext *avctx, const uint8_t **poutbuf, int *poutbuf_size, const uint8_t *buf, int buf_size)
Definition apv_parser.c:92
static av_cold void close(AVCodecParserContext *s)
Definition apv_parser.c:197
int(* init)(AVBSFContext *ctx)
Definition dts2pts.c:608
@ AV_CODEC_ID_AMR_NB
Definition codec_id.h:434
@ AV_CODEC_ID_AMR_WB
Definition codec_id.h:435
av_cold void ff_parse_close(AVCodecParserContext *s)
Definition parser.c:300
#define PARSER_CODEC_LIST(...)

Definition at line 126 of file amr_parser.c.