gltforge_unity_export/node_data.rs
1/// A Unity GameObject to be exported as a glTF node.
2/// Transform values are in Unity's left-handed coordinate system; the build step
3/// inverts handedness to produce right-handed glTF output.
4pub struct NodeData {
5 /// Node name, or `None` to omit from the glTF output.
6 pub name: Option<String>,
7
8 /// Index of the parent node, or `None` for root nodes.
9 pub parent: Option<u32>,
10
11 /// Index into the export context's mesh list, if this node has a mesh.
12 pub mesh_index: Option<u32>,
13
14 /// Local position `[x, y, z]` in Unity space, or `None` to omit (glTF default: origin).
15 pub translation: Option<[f32; 3]>,
16
17 /// Local rotation as a unit quaternion `[x, y, z, w]` in Unity space,
18 /// or `None` to omit (glTF default: identity).
19 pub rotation: Option<[f32; 4]>,
20
21 /// Local scale `[x, y, z]`, or `None` to omit (glTF default: ones).
22 pub scale: Option<[f32; 3]>,
23}