Go to the documentation of this file.
50 if (!(bytestream2_peek_byte(&p) & 1))
53 if (bytestream2_peek_byte(&p) == 1) {
56 if (bytestream2_peek_byte(&p) ==
'v'){
60 tag = bytestream2_get_le32(&p);
65 }
else if (bytestream2_peek_byte(&p) ==
't') {
70 uint8_t acid[5] = { 0 };
83 size = bytestream2_get_le32(&p);
85 time_unit = bytestream2_get_le64(&p);
86 spu = bytestream2_get_le64(&p);
87 if (!time_unit || !spu) {
121 }
else if (bytestream2_peek_byte(&p) == 3) {
133 struct ogg *
ogg =
s->priv_data;
157 }
else if(t == 0x05589f81){
174 struct ogg *
ogg =
s->priv_data;
182 lb = ((*p & 2) << 1) | ((*p >> 6) & 3);
183 if (os->
psize < lb + 1)
190 os->
pduration += (uint64_t)p[lb+1] << (lb*8);
196 .
magic =
"\001video",
200 .granule_is_start = 1,
205 .
magic =
"\001audio",
209 .granule_is_start = 1,
218 .granule_is_start = 1,
223 .
magic =
"\001Direct Show Samples embedded in Ogg",
227 .granule_is_start = 1,
uint8_t * extradata
Extra binary data needed for initializing the decoder, codec-dependent.
enum AVMediaType codec_type
General type of the encoded data.
const struct ogg_codec ff_ogm_old_codec
const AVCodecTag ff_codec_wav_tags[]
uint32_t codec_tag
Additional information about the codec (corresponds to the AVI FOURCC).
int nb_channels
Number of channels in this layout.
#define AV_PKT_FLAG_KEY
The packet contains a keyframe.
static av_always_inline void bytestream2_skip(GetByteContext *g, unsigned int size)
#define AV_LOG_ERROR
Something went wrong and cannot losslessly be recovered.
uint64_t_TMPL AV_WL64 unsigned int_TMPL AV_WL32 unsigned int_TMPL AV_WL24 unsigned int_TMPL AV_RL16
enum AVStreamParseType need_parsing
AVCodecParameters * codecpar
Codec parameters associated with this stream.
const struct ogg_codec ff_ogm_text_codec
static av_always_inline unsigned int bytestream2_get_buffer(GetByteContext *g, uint8_t *dst, unsigned int size)
AVChannelLayout ch_layout
Audio only.
struct ogg_stream * streams
int sample_rate
Audio only.
static av_always_inline int bytestream2_get_bytes_left(GetByteContext *g)
int extradata_size
Size of the extradata content in bytes.
static int ogm_header(AVFormatContext *s, int idx)
Copyright (C) 2005 Michael Ahlberg, Måns Rullgård.
const struct ogg_codec ff_ogm_video_codec
static int ogm_dshow_header(AVFormatContext *s, int idx)
@ AV_CODEC_ID_TEXT
raw UTF-8 text
uint64_t_TMPL AV_WL64 unsigned int_TMPL AV_RL32
const AVCodecTag ff_codec_bmp_tags[]
const struct ogg_codec ff_ogm_audio_codec
static int ogm_packet(AVFormatContext *s, int idx)
int ff_vorbis_stream_comment(AVFormatContext *as, AVStream *st, const uint8_t *buf, int size)
Parse Vorbis comments and add metadata to an AVStream.
enum AVCodecID codec_id
Specific type of the encoded data (the codec used).
Copyright (C) 2005 Michael Ahlberg, Måns Rullgård.
static av_always_inline void bytestream2_init(GetByteContext *g, const uint8_t *buf, int buf_size)
int need_context_update
Whether the internal avctx needs to be updated from codecpar (after a late change to codecpar)
int64_t bit_rate
The average bitrate of the encoded data (in bits per second).
#define AVERROR_INVALIDDATA
Invalid data found when processing input.