[vorbis-dev] Header

Monty xiphmont at xiph.org
Fri May 12 13:30:46 PDT 2000



> If you could provide me with brief details on the location/encoding of
> the info within the files, I can get started writing the PHP script I need for
> this to add OGG support to AudioPhilez.

Magic to detect Ogg (and detect Ogg/Vorbis) is easy.  Extracting the details of
the file takes more effort because Ogg and Vorbis generally don't bound field
lengths if possible.  The headers will need to be parsed (First the Ogg pages
need to be parsed, then the first three packets extracted from however many
pages they take up.  Then these header packets can be parsed).

Whipping up docs for this now.

> Is the source for this easy enough to understand? I'm hardly
> an accomplished C/C++ programmer but if it is straightforward enough
> and commented, I should be able to get something happening in PHP.

It's easy to deal with, you just need to know that there is more than one layer
of parsing.  First at the Ogg bitstream level, then at the Vorbis packet level.

Monty

--- >8 ----
List archives:  http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/



More information about the Vorbis-dev mailing list