This description is deprecated, read the comments for accurate context
Description
Vertices are being multiplied by matrixWorld and then passed to the DataView as float32.
In JavaScript, numbers are float64 by default, so applying matrixWorld to the vertex might produce more precision than a float32 type can handle.
Solution
- Replace
output.setFloat32 with output.setFloat64
- Replace
float with float64 (double) in header
- Fix the ArrayBuffer allocation size to accommodate the new changes
Alternatives
Doing the same for normals might also be useful
Additional context
Related: #31710