Пример #1
0
        public Kip(Stream stream)
        {
            StreamSource = new SharedStreamSource(stream);
            Header       = new KipHeader(StreamSource.CreateStream());

            Size = HeaderSize;

            for (int index = 0; index < Header.Sections.Length; index++)
            {
                int sectionSize = Header.Sections[index].CompressedSize;
                SectionOffsets[index] = Size;
                Size += sectionSize;
            }
        }
Пример #2
0
        public Kip(IStorage storage)
        {
            Storage = storage;
            Header  = new KipHeader(Storage);

            Size = HeaderSize;

            for (int index = 0; index < Header.Sections.Length; index++)
            {
                int sectionSize = Header.Sections[index].CompressedSize;
                SectionOffsets[index] = Size;
                Size += sectionSize;
            }
        }