Export the normal. Keep the tangent straight.
The glTF exporter has an important orientation boundary: normal maps use glTF's top-left texture convention, while Three.js materials expose a signed normal-scale Y. This lab keeps an OpenGL-style map beside a DirectX-style map, then inspects what the binary exporter and loader preserve.
Building two planes with opposite tangent-space Y conventions…
- backend
- —
- source
- —
- artifact
- —
- round-trip
- —
- frame ms
- —
Export GLB serializes the two source meshes; Load GLB parses that exact ArrayBuffer through GLTFLoader.
normalScale.y +0.75
normalScale.y -0.75
plane attribute policy
binary glTF
independent parse
The official example demonstrates paired OpenGL and DirectX normal maps, a glTF UV alternative, and binary export. This local contract also makes the sign-preservation boundary observable.
Generated normal maps keep the study deterministic and offline-friendly.
Derived from the official glTF normals exporter example, GLTFExporter, and MeshStandardMaterial.