struct ndx_header {
u8 major_version; /* 2 */
u8 minor_version; /* 2 */
u8 flags; /* 0x01 = copy protected; none others seen */
u8 unused[29]; /* all 0s */
};
struct ndx_record
{
u8 flag_1; /* all unknown; different between 520410600 and
520411140. Update: looked like a single flag in
520410600, but appears unused & uninitialized in
520411140 and the very first software release */
u8 comm_flag; /* 0x01 == part of a commercial break; 0x02 ==
candidate to be the beginning or ending of a
commercial break */
u16 video_offset; /* offset, relative to the stream_position member, of
the start of the first video PES packet in this
pack */
u8 unk_fe; /* always 0xfe as far as I've seen; I think this is
read directly from one of the mpeg encoder's
registers, but I don't know what it means */
u8 macrovision; /* always 0 or 3 as far as I've seen; I think this too
is read directly from one of the mpeg encoder's
registers, and '3' means 'macrovision possibly
detected' */
u16 macrovision_count; /* counts the number of consecutive frames with
macrovision fields equal to 3; I think if this
reaches 361 (more than 3 consecutive minutes), then
the 'copy-protected' flag is set -- details on when the flag is set
have changed in 4.1.1 */
u32 audio_offset; /* offset, relative to the video PES pointed at by
video_offset, of the beginning of the first audio
PES in the pack */
u32 unused; /* always 0; related somehow to the timestamp, it
looks like */
u64 timestamp; /* timestamp in nanoseconds, from an unknown base,
possibly system startup time. What *exactly* it's
a timestamp of is still somewhat in question; it
doesn't match up with any of the timestamps in the
MPEG file. I think it's probably the time the
record was written, as measured by a clock that
isn't exactly synchronous with the MPEG encoder's
clock */
u64 stream_position; /* the offset into the MPEG file of the start of the
32k cluster the pack this record is about starts
in. */
};
struct ndx5000_record {
u64 timestamp; /* 8 byte timestamp, in nanoseconds */
u32 empty1; /* apparently empty(?)
could be part of the video packet offset,
to accomodate some insanely large files */
u32 video_offset; /* video stream packet offset */
u32 video_length; /* video stream packet length(?) */
u32 empty2; /* apparently empty(?) */
};
Those two empty 32-bit words could be used for something else. Like I said earlier, I only analyzed one or two .NDX files.
Hope that helps.
-- TimLee - 13 Jan 2003
struct ndx5000_record {
u64 timestamp; /* 8 byte timestamp, in nanoseconds */
u64 filepos_iframe; /* File position to an I-frame */
u32 iframe_size; /* Size of the I-Frame (including PES Headers) */
u32 empty; /* Always Zero, possibly for alignment */
};
(Thanks to Anon!)
-- LeeThompson - 29 Jun 2003
| Topic Ndx . { Edit | Attach | Ref-By | Printable | Diffs | r1.22 | > | r1.21 | > | r1.20 | More } |
|
Revision r1.22 - 30 Jul 2003 - 06:17 GMT - LeeThompson Parents: WebHome |
Copyright © 2001 by the contributing authors.
All material on this collaboration tool is the property of the contributing authors. Ideas, requests, problems regarding TWiki? Send feedback. |