[vorbis-dev] Feedback on Ogg Speex file format
Michael Smith
msmith at labyrinth.net.au
Wed Aug 14 02:10:23 PDT 2002
At 11:38 PM 8/13/02 -0400, you wrote:
>Hi,
>
>I'm the main author of Speex (http://speex.sourceforge.net), an
>open-source speech codec that uses Ogg for file storage. I'd like to
>have feedback on the way we store Speex data in Ogg files to make sure
>we do the right thing. The Speex documentation can be found at
>http://speex.sourceforge.net/manual/ but here's the part about Ogg:
>
>
>
>Speex bit-streams can be stored in Ogg files. In this case, the first
>packet of the Ogg file contains the Speex header described in table 4.
>All integer fields in the headers are stored as little-endian. The
>speex_string field must contain the ``Speex `` (with 3 training
>spaces), which identifies the bit-stream. The next field, speex_version
>contains the version of Speex that encoded the file. For now, refer to
>speex_header.[ch] for more info. The beginning of stream (b_o_s) flag is
>set to 1 for the header. The header packet has packetno=0 and
>granulepos=0.
This all looks fine, though space-padding 'Speex ' seems silly to me.
I wouldn't do that.
>
>The second packet contains a user-comment string, without terminating
>null. The content/format of the comment string is not defined. This
>packet has packetno=1 and granulepos=0.
Why not just define the content/format of the comment header as the
same as the vorbis comment header (though obviously without the "vorbis"
at the start, etc.)? That would seem more useful to me.
>
>The third and subsequant packets each contain one or more (number found
>in header) Speex frames. These are identified with packetno starting
>from 2 and the granulepos is the number of the first sample encoded in
>that packet.
granulepos must be the _last_ sample decodable from that packet, not
the first.
>
>The stream is terminated by a packet containing the string ``END OF
>STREAM'' (without terminating null). The the end of stream (e_o_s) flag
>set to 1. The decoder should rely on the e_o_s flag and not on the
>content of the packet.
The final audio packet should have e_o_s set, and there should NOT be
a seperate terminating packet like this - there's no need.
Mike
--- >8 ----
List archives: http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/
To unsubscribe from this list, send a message to 'vorbis-dev-request at xiph.org'
containing only the word 'unsubscribe' in the body. No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.
More information about the Vorbis-dev
mailing list