paper · 3D optimization for everyone

Inspiration

Shipping a 3D model to a mobile game today means installing Blender, learning the Decimate Modifier, configuring texture compression, and iterating until something works; or paying a tech artist $80/hour. Tools like Blender, Maya, and AutoCAD are powerful but built for experts. We wanted to compress that workflow into three sliders and a button.

What it does

Drop in any GLB, pick a target; Mobile, VR, Mid PC, or High PC, and walk away with a platform-ready file in seconds. paper gives you:

  • Three real-time sliders: topology, texture quality, and vertex precision
  • Live platform compatibility rings showing headroom on each tier
  • An AI co-pilot (Llama 3.3 70B via Groq) that diagnoses your asset and recommends a preset for the chosen platform
  • A silent visual-integrity check (windowed SSIM) that warns the AI about hole-like damage when sliders go too aggressive
  • One-click GLB export with a SHA-256 integrity hash

Everything runs client-side; your asset never leaves your browser.

How we built it

Vite + React + TypeScript shell, three.js + react-three-fiber for the WebGL viewer, meshoptimizer WASM for decimation, and three.js's GLTFExporter for binary GLB output. Groq powers live AI recommendations with Zod schema validation; a hand-tuned fallback cache keeps the demo bulletproof if Groq rate-limits mid-pitch.

The optimization pipeline is a four-stage transform: LOD swap → texture downsample → vertex quantization → re-analyze. Each fires on every slider change. Visual fidelity is computed by rendering pristine + current to a 192² offscreen canvas and running windowed SSIM:

$$ \text{score} = 0.6\,\overline{\mathrm{SSIM}} + 0.4\,\overline{\mathrm{SSIM}}_{\text{worst }10\%} $$

Worst-decile weighting catches localized damage that global SSIM averages away.

Challenges

  • SSIM globally averaged is useless for catching holes. A baseball with a visible tear scored 0.96. Switching to windowed SSIM with worst-decile weighting fixed it.
  • Polyhaven scans hit a topology floor because photogrammetry meshes have disconnected fragments. Aggressive mergeVertices pre-pass + iterative simplifySloppy fallback unlocked further reduction.
  • LOD swap silently broke vertex quantization; mesh.geometry references change, dropping the quantized state. Fix: combined the two effects into one ordered pipeline.
  • Per-asset budgets aren't scene budgets. Initial draw-call caps were meaningless for single-material assets. We replaced them with vertex-buffer memory, which actually scales.
  • Live demos can't fail. A 12-entry fallback cache (3 assets × 4 platforms) with a one-click toggle keeps the AI panel populated even with zero tokens.

What we learned

The hard part of 3D optimization isn't the algorithms; meshoptimizer, Draco, and three.js's exporters all exist as libraries. The hard part is making them legible to someone who isn't already a tech artist. That's UX work, not graphics work, and it's where the win is.

What's next

Rigged-asset support, LPIPS for better perceptual quality, more platform tiers (Switch, Web, AR), and CLI/CI integrations.

Built With

Share this project:

Updates