FFmpeg
Functions
vorbis_parser.c File Reference

Vorbis audio parser. More...

#include "libavutil/log.h"
#include "get_bits.h"
#include "parser.h"
#include "xiph.h"
#include "vorbis_parser_internal.h"

Functions

int av_vorbis_parse_frame_flags (AVVorbisParseContext *s, const uint8_t *buf, int buf_size, int *flags)
 Get the duration for a Vorbis packet. More...
 
int av_vorbis_parse_frame (AVVorbisParseContext *s, const uint8_t *buf, int buf_size)
 Get the duration for a Vorbis packet. More...
 
void av_vorbis_parse_reset (AVVorbisParseContext *s)
 
void av_vorbis_parse_free (AVVorbisParseContext **s)
 Free the parser and everything associated with it.
 
AVVorbisParseContextav_vorbis_parse_init (const uint8_t *extradata, int extradata_size)
 Allocate and initialize the Vorbis parser using headers in the extradata.
 

Detailed Description

Vorbis audio parser.

Determines the duration for each packet.

Function Documentation

§ av_vorbis_parse_frame()

int av_vorbis_parse_frame ( AVVorbisParseContext s,
const uint8_t *  buf,
int  buf_size 
)

Get the duration for a Vorbis packet.

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

§ av_vorbis_parse_frame_flags()

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

Get the duration for a Vorbis packet.

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