[Vorbis] brainfart #67453 - hyper-index

John Morton jwm
Mon Jul 26 07:53:58 PDT 2004


<200407262114.35691.jwm at eslnz.co.nz>
<200407261514.42528.haxe at pansensack.de>
Message-ID: <200407270253.58473.jwm at eslnz.co.nz>

On Tue, 27 Jul 2004 01:14, Haxe wrote:
>  On Monday 26 July 2004 11:14, John Morton wrote:
>  > Players can, in principle, do this already by treating each logical
>  > stream within a physical stream as a 'track'.
>
>  To me, that doesn't sound like a good solution.
>
>  Imagine I  have a seekable Ogg/Vorbis file that has a size of several
>  gigabytes and contains, say, 20 "tracks". Of course, I want the 20
>  track marks to be listed without having the player seek through all the
>  gigabytes of the file (which would be the case with just treating
>  concatenated logical streams as tracks, or am I getting it wrong
>  here?).

Some observations:

- vorbisfile already scans the entire physical stream, if it's seekable, to
find logical streams, so what I'm doing is just exploiting this fact. If you
want to avoid this, you'll probably need to roll your own open function out
of libvorbis.

- How is one big file and a pregenerated index better than several small
files? After all, the "pregenerated index" is exactly what the file system is
doing, and existing players all know how to ask the file system where each
file begins right now, where as you'd have to train them to use some separate
index system.

>  With Vorbis content, it seems a rare case to have a several gigabyte
>  seekable Ogg file, but with Theora content this sounds perfectly
>  sensible. And the track marks in question would be like the chapters of
>  a DVD. Is there possibly already a solution for such listed-in-advance
>  trackmarks in Ogg/Theora, which could then be used for Ogg/Vorbis as
>  well?

DVD's tend to break down films into separate vob files for titles, at least.
Given the relative easy of joining multiple chapters together for, say,
bittorrent network transport, and spliting them for faster access, you'll
probably find the leaving that kind of course grained  indexing to the
filesystem is much less bother.

John



More information about the Vorbis mailing list