FourError INVALID_SCENE_GRAPH (§85) when the record is malformed —
no bones, a duplicate id, or a matrix array that is not 16 floats per bone.
The matrix contents are validated by Skeleton's constructor at
resolution, and the bone count by Mesh.skeleton's setter.
Hands a
Meshits saved §79 skeleton reference — bone ids in joint-index order plus the inverse bind matrices — to be resolved on the first Mesh.skeleton read (RFC 0003; §79: intra-file references are by id).The seam exists for the reason
restoreNodeIddoes: a §79 node factory runs while the tree is still being assembled, so the bones a reference names may not exist yet, and the earliest moment the mesh and its bones are guaranteed to share a tree is the first read after instantiation — which is exactly when the serializer's writer, the render list, or the application asks.packages/fourjs/src/scene-serializers.tsis the caller; an application's own factory may call it for the same purpose. Any previously assigned or pending skeleton is replaced.