Mesh._isWorldMatrixFrozen not serialized

Version: git HEAD

TransformNode._isWorldMatrixFrozen is currently not serialized nor parsed for TransformNode, but it’s parsed for mesh:

But in curr codebase there is nowhere parsedMesh.freezeWorldMatrix get serialized after a quick search, so serialization will lost this config.

Also, ever considered extending this to TransformNodes?

Good catch, thanks for the report (and for digging into the source)!

You’re right on both counts:

  1. Mesh.Parse was reading freezeWorldMatrix but nothing on the producer side ever wrote it, so the value was always lost on a .babylon round-trip.
  2. TransformNode had no support at all even though _isWorldMatrixFrozen lives there.

Fixed in PR #18373:

  • Mesh.serialize() and TransformNode.serialize() now emit freezeWorldMatrix: true when the node is frozen.
  • TransformNode.Parse() defers the freeze via an internal waiting flag (declared, not initialized, to avoid pushing every instance past V8’s dictionary-mode threshold).
  • babylonFileLoader runs a freeze pass for transform nodes after parent wiring, before the existing mesh freeze pass.

Round-trip unit test added.