main
Name Last commit message Last updated
optimize.mjs Optimize project hero GLB while preserving layers and fan animation · John Lauer
package-lock.json Optimize project hero GLB while preserving layers and fan animation · John Lauer
package.json Optimize project hero GLB while preserving layers and fan animation · John Lauer
README.md Optimize project hero GLB while preserving layers and fan animation · John Lauer

Hero GLB optimizer

With Node 22 or newer, run npm ci in this folder, then node optimize.mjs. Dependencies are pinned in package-lock.json.

Creates the display-only side-fan-hero.glb; does not replace the engineering assembly or simulator collision model. Uses glTF Transform weld and Draco (18-bit positions, 12-bit normals). No decimation, flattening, or node joining. Layer tags, hierarchy, materials, animation channels, keyframes, and authored asset metadata are retained.

Validation: mechanical/side-fan-r10/hero-optimization.json. Compressed geometry was decoded, compared, and rendered in the canonical viewer. The standard validator reports zero errors/warnings but cannot validate Draco payloads itself; the independent decoder/render checks cover that boundary.

The reduction is primarily download/storage size; decoded GPU geometry remains about 0.3 million vertices. No frame-rate or peak-memory improvement is claimed.