-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathReality Binary Model.txt
74 lines (60 loc) · 1.88 KB
/
Reality Binary Model.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
HEADER - 16 Bytes
MAGIC ID - 4 Bytes - "RBM\0"
OFFSET VERTICES - 4 Bytes
OFFSET FACES - 4 Bytes
OFFSET MATS - 4 Bytes
OFFSET STRINGS - 4 Bytes
+--------+
| Arrays |
+--------+
VERTICES ARRAY
HEADER - 8 Bytes
MAGIC ID - ASCII - 4 Bytes - "VTX\0"
LENGTH - USHORT - 2 Bytes
DATA
N*LENGTH - VERTEX[] - 16 Bytes * LENGTH
FACES ARRAY
HEADER - 8 Bytes
MAGIC ID - ASCII - 4 Bytes - "FAC\0"
LENGTH - USHORT - 2 Bytes
DATA
N*LENGTH - FACE[] - 10 Bytes * LENGTH
MATS ARRAY
HEADER - 8 Bytes
MAGIC ID - ASCII - 4 Bytes - "MAT\0"
LENGTH - USHORT - 2 Bytes
DATA
N*LENGTH - FACE[] - 10 Bytes * LENGTH
STRING ARRAY
HEADER - 8 Bytes
MAGIC ID - ASCII - 4 Bytes - "STR\0"
LENGTH - USHORT - 2 Bytes
DATA
Null terminated strings, hard to define clearly tbh
+------------+
| NODE TYPES |
+------------+
VERTEX - 16 Bytes
POS X - SHORT - 2 Bytes
POS Y - SHORT - 2 Bytes
POS Z - SHORT - 2 Bytes
DATA X - [U]SHORT - 2 Bytes
DATA Y - [U]SHORT - 2 Bytes
DATA Z - [U]SHORT - 2 Bytes
TEX U - SHORT - 2 Bytes
TEX V - SHORT - 2 Bytes
FACE - 10 Bytes
MAT - INDEX MAT - 2 Bytes
VERT 1 - INDEX VERT - 2 Bytes
VERT 2 - INDEX VERT - 2 Bytes
VERT 3 - INDEX VERT - 2 Bytes
TYPE - BYTE - 1 Byte
COLOUR - 0
NORMAL - 1
BOTH - 2
ALPHA - BYTE - 1 Byte
MAT(Material) - 10 Bytes
TEX - INDEX PATH - 2 Bytes
GMODE C - UINT - 4 Bytes
GMODE S - UINT - 4 Bytes
Strings are null-terminated.