[NUT-devel] NUT spec review - chapters

Rich Felker dalias at aerifal.cx
Sat Feb 9 10:44:45 CET 2008


I've been reviewing the NUT spec for clarity and bugs and found one
small issue with the way chapters are specified for info:

chapter_id (s)
    The ID of the chapter this packet applies to. If zero, the packet applies
    to the whole file. Positive chapter_id values represent real chapters and
    MUST NOT overlap.

chapter_start (t)
    timestamp of start of chapter

chapter_len (v)
    Length of chapter in the same timebase as chapter_start.

It's likely impossible to partition a file into chapters that cover
the whole file without overlapping due to the requirement that
chapter_len use the same timebase as chapter_start. Surely you could
just cut the chapter lengths short and in most places it would only
make a difference of a few frames, but it one wants to use chapters
for cutting a file and later being able to rejoin the parts to get the
original file, things would break badly.

Using chapter_end in its own timebase or having positive chapter_ids
implicitly ended by the start of the next chapter would both work, but
would break the frozen syntax.

Is this an issue anyone cares about? Is there a nice fix?

I'll post any more issues I see as I continue to review.

Rich



More information about the NUT-devel mailing list