[vlc-devel] fixing a bug: preferred audio language select for .ogg
remi at remlab.net
Thu Sep 16 02:52:28 CEST 2010
On Wednesday 15 September 2010, Karl Ostmo wrote:
> The problem is that unlike with .mkv files, with .ogm files the
> es->fmt.psz_language variable is not set by the time that EsOutAdd()
> is called. In fact, currently the variable is never set for Vorbis
> audio streams. Ideally, the variable would be set in
> Ogg_ReadVorbisHeader() of ogg.c. However, it looks like the header
> data is not fully extracted until up to 3 packets have been read in
In other words, OGG is a retarded format that you do NOT want to use for your
> At that point the function Ogg_ExtractMeta() is called, which itself
> makes a call to vorbis_ParseComment() where the stream's language
> attribute could be extracted. Unfortunately, this finally happens
> well after Ogg_BeginningOfStream() had been called (which is where
> EsOutAdd() happens).
> I was wondering if someone familiar with this code could give me some
> pointers or suggestions about how to proceed. Would there be a way to
> "read ahead" a few packets
> from within Ogg_ReadVorbisHeader() so that the header info can be
> fully populated and parsed?
I say blame it on OGG's brain damage and mark the bug wontfix.
More information about the vlc-devel