Two members of the archive, meta/meta.dat and model.dat, are
trees of tagged values. meta.dat is small and its tags are listed below.
model.dat holds the whole model and only its first levels have been
examined. All numbers are little-endian.
Elements
Both files are made of elements, each a tag, a length and a value:
| Offset | Size | Type | Name | Meaning |
|---|---|---|---|---|
| 0 | 2 | u16 | Tag | What the element is. |
| 2 | 4 | u32 | Length | The length of the value in bytes. |
| 6 | length | bytes | Value | Either a value (a number, ASCII text, a GUID) or further elements. |
The element does not say whether its value is plain data or more elements; that
depends on the tag. OpenSKP keeps a list of the tags that hold elements, and for
meta.dat the explorer does the same, with the tags
0x0064, 0x0067, 0x0068, 0x0078,
0x00C8, 0x00C9, 0x00CA and
0x2328.
To read a tree: read the tag (u16) and the length (u32); if the tag is one that holds elements, read elements from the value until its end, which they must fill exactly; otherwise take the value as it is. Then go on with the next element after the value. Numbers in values are little-endian, and text is ASCII without a terminating zero.
model.dat
model.dat was 17.5 MB to 86.6 MB once inflated in the files seen (3.8 MB
to 21.9 MB stored). The whole member is one element, tag 0x01F4, whose
value is a run of elements that fill it exactly: 26 of them in a 2023 file. Its first
children:
| Tag | Holds |
|---|---|
0x0063 | A u32, 0. |
0x020A | The text meta/meta.dat. |
0x0209 | Dynamic property dictionaries: 0x36B1 → 0x36B2 → 0x36B3 → 0x36B4 with a name such as ModelProperties, keys in 0x36B6 such as Description, IsClassified, IsDynamic, IsLive and Name, and typed values: the type in 0x38A4, then 0x38AA a true or false, 0x38A7 an integer, 0x38A9 an f64 or 0x38AD a string. |
0x0200 | The option groups: names in 0x61AB (UnitsOptions, PageOptions, SlideshowOptions, NamedOptions, PrintOptions) and keys in 0x61AD with typed values, the same groups and keys as the options of the older files. |
0x01F5 | Not examined. |
0x01FA | Not examined. |
00000000 F4 01 xx xx xx xx 63 00 04 00 00 00 00 00 00 00
Beyond these, nothing in model.dat was checked for this site.
The explorer’s outline
The explorer inflates up to the first 64 MB of model.dat and lists the
top element and two levels below it, with each element’s offset, tag and length. It
reads a value as elements only where they fill it exactly, and otherwise shows the
value as bytes or text. That a value which divides exactly into elements is elements
is an inference, and the outline says so.