FFmpeg
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Functions
vorbis_parser_internal.h File Reference

Vorbis audio parser. More...

#include "avcodec.h"
#include "vorbis_parser.h"

Go to the source code of this file.

Data Structures

struct  AVVorbisParseContext
 

Functions

int avpriv_vorbis_parse_extradata (AVCodecContext *avctx, AVVorbisParseContext *s)
 Initialize the Vorbis parser using headers in the extradata.
 
int avpriv_vorbis_parse_frame_flags (AVVorbisParseContext *s, const uint8_t *buf, int buf_size, int *flags)
 Get the duration for a Vorbis packet.
 
int avpriv_vorbis_parse_frame (AVVorbisParseContext *s, const uint8_t *buf, int buf_size)
 Get the duration for a Vorbis packet.
 
void avpriv_vorbis_parse_reset (AVVorbisParseContext *s)
 

Detailed Description

Vorbis audio parser.

Determines the duration for each packet.

Definition in file vorbis_parser_internal.h.

Function Documentation

int avpriv_vorbis_parse_extradata ( AVCodecContext avctx,
AVVorbisParseContext s 
)

Initialize the Vorbis parser using headers in the extradata.

Parameters
avctxcodec context
sVorbis parser context

Definition at line 300 of file vorbis_parser.c.

int avpriv_vorbis_parse_frame_flags ( AVVorbisParseContext s,
const uint8_t buf,
int  buf_size,
int *  flags 
)

Get the duration for a Vorbis packet.

avpriv_vorbis_parse_extradata() must have been successfully called prior to this in order for a correct duration to be returned. If flags is NULL, special frames are considered invalid.

Parameters
sVorbis parser context
bufbuffer containing a Vorbis frame
buf_sizesize of the buffer
flagsflags for special frames

Definition at line 313 of file vorbis_parser.c.

int avpriv_vorbis_parse_frame ( AVVorbisParseContext s,
const uint8_t buf,
int  buf_size 
)

Get the duration for a Vorbis packet.

avpriv_vorbis_parse_extradata() must have been successfully called prior to this in order for a correct duration to be returned.

Parameters
sVorbis parser context
bufbuffer containing a Vorbis frame
buf_sizesize of the buffer

Definition at line 308 of file vorbis_parser.c.

void avpriv_vorbis_parse_reset ( AVVorbisParseContext s)

Definition at line 304 of file vorbis_parser.c.