CGFX: Difference between revisions
Planetarian (talk | contribs) |
Planetarian (talk | contribs) |
||
Line 292: | Line 292: | ||
|- | |- | ||
| 0x0 | | 0x0 | ||
| | | 0x4 | ||
| Flags ? | | Flags (bit 4: model; bit 1: skeleton) | ||
|- | |||
| 0x4 | |||
| 0x4 | |||
| Magic "SOBJ" | |||
|- | |||
| 0x8 | |||
| 0x4 | |||
| ? | |||
|- | |||
| 0xC | |||
| 0x4 | |||
| Unknown symbol offset (self-relative) | |||
|- | |||
| 0x10 | |||
| 0xC | |||
| ? | |||
|- | |||
| 0x1C | |||
| 0x4 | |||
| Unknown offset (self-relative) (appears to hold array of floats) ? | |||
|- | |||
| 0x20 | |||
| 0xC | |||
| ? | |||
|- | |||
| 0x2C | |||
| 0x4 | |||
| Face groups count | |||
|- | |||
| 0x30 | |||
| 0x4 | |||
| Offset (self-relative) to face groups offset array | |||
|- | |||
| 0x34 | |||
| 0x4 | |||
| ? | |||
|- | |||
| 0x38 | |||
| 0x4 | |||
| Vertex groups count | |||
|- | |||
| 0x3C | |||
| 0x4 | |||
| Offset (self-relative) to vertex groups offset array | |||
|- | |||
| 0x40 | |||
| 0x4 | |||
| Unknown offset (self-relative) ? | |||
|} | |||
Face groups: | |||
{| class="wikitable" | |||
|- | |||
! Offset | |||
! Length | |||
! Description | |||
|- | |||
| 0x0 | |||
| 0x4 | |||
| Bone groups count | |||
|- | |||
| 0x4 | |||
| 0x4 | |||
| Offset (self-relative) to 4-byte bone group IDs array | |||
|- | |||
| 0x8 | |||
| 0x4 | |||
| ? | |||
|- | |||
| 0xC | |||
| 0x4 | |||
| Unknown1 count | |||
|- | |||
| 0x10 | |||
| 0x4 | |||
| Offset (self-relative) to Unknown1 offset array | |||
|} | |||
Unknown1: | |||
{| class="wikitable" | |||
|- | |||
! Offset | |||
! Length | |||
! Description | |||
|- | |||
| 0x0 | |||
| 0x4 | |||
| Face group descriptor count | |||
|- | |||
| 0x4 | |||
| 0x4 | |||
| Offset (self-relative) to face group descriptors offset array | |||
|- | |||
| 0x8 | |||
| 0x4 | |||
| Unknown3 count | |||
|- | |||
| 0xC | |||
| 0x4 | |||
| Offset (self-relative) to 4-byte Unknown2 array | |||
|- | |||
| 0x10 | |||
| 0x8 | |||
| ? | |||
|} | |||
Face array descriptor: | |||
{| class="wikitable" | |||
|- | |||
! Offset | |||
! Length | |||
! Description | |||
|- | |||
| 0x0 | |||
| 0x4 | |||
| Flags (bit 1: vertex index format: 0=byte, 1=short) | |||
|- | |||
| 0x4 | |||
| 0x4 | |||
| ? | |||
|- | |||
| 0x8 | |||
| 0x4 | |||
| Vertex index array size (in bytes) | |||
|- | |||
| 0xC | |||
| 0x4 | |||
| Offset (self-relative) to vertex index array | |||
|} | |||
Vertex group objects come in one of several formats, specified by the flags field. | |||
Vertex group format 0x40000001: (?) | |||
{| class="wikitable" | |||
|- | |||
! Offset | |||
! Length | |||
! Description | |||
|- | |||
| 0x0 | |||
| 0x4 | |||
| Flags (0x40000001) | |||
|- | |||
| 0x4 | |||
| 0x4 | |||
| Type ? | |||
|- | |||
| 0x8 | |||
| 0x4 | |||
| ? | |||
|- | |||
| 0xC | |||
| 0x4 | |||
| ? | |||
|- | |||
| 0x10 | |||
| 0x4 | |||
| ? | |||
|- | |||
| 0x14 | |||
| 0x4 | |||
| Vertex array size (in bytes) | |||
|- | |||
| 0x18 | |||
| 0x4 | |||
| Offset (self-relative) to vertex array | |||
|- | |||
| 0x1C | |||
| 0x4 | |||
| ? | |||
|- | |||
| 0x20 | |||
| 0x4 | |||
| ? | |||
|- | |- | ||
| | | 0x24 | ||
| 0x1 | | 0x1 | ||
| | | ? | ||
|- | |||
| 0x25 | |||
| 0x1 | |||
| ? | |||
|- | |||
| 0x26 | |||
| 0x1 | |||
| ? | |||
|- | |||
| 0x27 | |||
| 0x1 | |||
| ? | |||
|- | |||
| 0x28 | |||
| 0x4 | |||
| ? | |||
|- | |||
| 0x2C | |||
| 0x4 | |||
| ? (float) | |||
|- | |- | ||
| 0x30 | |||
| 0x4 | | 0x4 | ||
| ? | |||
|} | |||
Vertex group format 0x40000002: | |||
{| class="wikitable" | |||
|- | |||
! Offset | |||
! Length | |||
! Description | |||
|- | |||
| 0x0 | |||
| 0x4 | | 0x4 | ||
| | | Flags (0x40000002) | ||
|- | |||
| 0x4 | |||
| 0x4 | |||
| ? | |||
|- | |- | ||
| | | 0x8 | ||
| 0x4 | | 0x4 | ||
| | | ? | ||
|- | |- | ||
| | | 0xC | ||
| 0x4 | | 0x4 | ||
| | | ? | ||
|- | |- | ||
| | | 0x10 | ||
| 0x4 | | 0x4 | ||
| | | ? | ||
|- | |- | ||
| | | 0x14 | ||
| 0x4 | | 0x4 | ||
| | | Vertex array size (in bytes) | ||
|- | |- | ||
| | | 0x18 | ||
| | | 0x4 | ||
| | | Offset (self-relative) to vertex array | ||
|- | |- | ||
| | | 0x1C | ||
| 0x4 | | 0x4 | ||
| | | ? | ||
|- | |- | ||
| | | 0x20 | ||
| 0x4 | | 0x4 | ||
| | | ? | ||
|- | |- | ||
| | | 0x24 | ||
| 0x4 | | 0x4 | ||
| Vertex | | Vertex format size (see below) | ||
|- | |- | ||
| | | 0x28 | ||
| 0x4 | | 0x4 | ||
| | | Unknown3 count | ||
|- | |- | ||
| | | 0x2C | ||
| | | 0x4 | ||
| | | Offset (self-relative) to 0x40000001 offset array | ||
|} | |} | ||
Vertex formats: | |||
{| class="wikitable" | {| class="wikitable" |