Represents an entry of a single file within the Archive. More...
#include <ArchiveInterfaceStructs.h>
Public Attributes | |
AZ::u64 | m_uncompressedSize: 35 |
AZ::u64 | m_compressedSizeInSectors: 26 |
AZ::u64 | m_compressionAlgoIndex: 3 |
AZ::u64 | m_blockLineTableFirstIndex: 25 |
AZ::u64 | m_offset: 39 |
AZ::Crc32 | m_crc32 {} |
AZStd::byte | m_unused [12] {} |
Represents an entry of a single file within the Archive.
AZ::u64 Archive::ArchiveTocFileMetadata::m_blockLineTableFirstIndex |
Index of the first block which line contains compressed data for this file Up to 2^25 ~ 33.55 million block lines can be referenced Each block line can represent up to 3 "2 MiB" blocks of content data that has been compressed Therefore a total of (2^25 * 3) ~ 100.66 million blocks can be stored
NOTE: This is only used if the file is stored compressed If the compressionAlgorithm index is UncompressedAlgorithmIndex then the file is stored uncompressed and the m_offset
member represents a contiguous block that is 512 byte aligned
AZ::u64 Archive::ArchiveTocFileMetadata::m_compressedSizeInSectors |
Stores compressed blocks that stored aligned on 512-byte sectors Therefore this can represent bytes sizes up to 35-bits as well while the value actually being stored is a 512-byte sector size 2^26 sectors * 512 bytes = 2^26 * 2^9 = 2^35 bytes Each 2 MiB chunk of a file compressed sectors are aggregated in this member For example if a 4 MiB file was compressed and the 2 "2 MiB" block compressed down to 513 and 511 bytes each, then compressed size in 512-byte sectors would be 3 due to rounding up each block to the nearest 512 byte boundary AlignUpToMultiple512(513) / 512 = 2
3
AZ::u64 Archive::ArchiveTocFileMetadata::m_compressionAlgoIndex |
Stores an index into Compression ID table to indicate the compression algorithm the file uses or UncompressedAlgorithmIndex if the value is set to UncompressedAlgorithmIndex, the block table index is not used
AZ::Crc32 Archive::ArchiveTocFileMetadata::m_crc32 {} |
offset = 16 Stores a checksum value of the file uncompressed data This can be used to validate that uncompressed file contents
AZ::u64 Archive::ArchiveTocFileMetadata::m_offset |
Offset within the archive where the file actually starts Due to files within the archive being aligned on 512-byte boundaries This can represent a offset of up to (39 + 9) bits or 2^48 = 256TiB The actual cap for Archive V1 layout is around 64TiB, since the m_blockTable can only represent 2^25 "2 MiB" blocks, which is (2^25 * 2^21) = 2^46 = 64TiB
AZ::u64 Archive::ArchiveTocFileMetadata::m_uncompressedSize |
represents the file after it has been uncompressed on disk Can represent a file up to 2^35 = 32GiB
AZStd::byte Archive::ArchiveTocFileMetadata::m_unused[12] {} |
offset = 20 Add padding bytes to fill the File Metadata structure with 0 bytes on construction