The .drft container · interface
DrftManifest
What the file says is coming, known from the first few kilobytes.
Explained in The .drft container.
interface DrftManifestimport type { DrftManifest } from '@driftengine/drft';In depth
The chunk table is a manifest and always was: a fixed 32-byte header, then
chunkCount x 16 bytes naming every chunk's kind, offset and length. For a 187-mesh car
that is about 3 KB, so a reader holding the first three kilobytes of a 74 MB file knows
exactly what the rest of it contains and how big each piece is. That is what lets a loading
bar say "142 of 187 parts" rather than counting bytes and hoping.
Properties
| Name | Type | Description |
|---|---|---|
totalBytesreadonly | number | |
meshCountreadonly | number | |
textureCountreadonly | number | |
meshBytesreadonly | number | Bytes of geometry, of images, and of everything else, from the table alone. |
textureBytesreadonly | number | |
lodCountreadonly | number | How many coarse levels of detail this file carries, which is normally one or none.MoreWorth reporting rather than leaving to be discovered, because it is the difference between a load that opens on an outline and one that opens on an empty room, and a caller composing words for a progress readout wants to know that before the first stage rather than after it. |
splatBlockCountreadonly | number | How many SPLT blocks this file carries, and how many bytes they are between them.MoreBlocks, not splats, because the number a progress readout wants is how many refinements are still coming — the splat count is in every block's own header and a caller has it from the first one. Zero for a file with no capture, which is most of them. |
splatBytesreadonly | number |