示例#1
0
        public override void ReadHeader(BinaryReaderWriter br)
        {
            base.ReadCommonHeader(br, Type);

            Filesections.ClearSections();

            br.ReadBytes(Unknown_x15);
            ContentsBlock = new ShortDataBlock(br);

            if (Headerlength > 0x1D)      // i.A. 0x001D; auch 0x25 gesehen mit 8 zusätzlichen Byte: 00 00 35 00 00 00 10 00

            {
                Unknown_x1D = new byte[Headerlength - 0x1D];
                br.ReadBytes(Unknown_x1D);
            }
        }
示例#2
0
        public override void SetSectionsAlign()
        {
            // durch Pseudo-Offsets die Reihenfolge der Abschnitte festlegen
            uint pos = 0;

            Filesections.SetOffset((int)InternalFileSections.ContentsBlock, pos++);
            Filesections.SetOffset((int)InternalFileSections.DescriptionBlock, pos++);
            Filesections.SetOffset((int)InternalFileSections.CharacterLookupTableBlock, pos++);

            Filesections.AdjustSections(DataOffset);  // lückenlos ausrichten

            // mit den endgültigen Offsets setzen
            SetData2Filesection((int)InternalFileSections.ContentsBlock, true);

            DataBlockWithRecordsize tmp = Filesections.GetPosition((int)InternalFileSections.ContentsBlock);

            ContentsBlock = new ShortDataBlock(tmp.Offset, (ushort)tmp.Length);
        }