Commit Graph
4 Commits
Author SHA1 Message Date
alphafetusandClaude Sonnet 5 a315cbc543 feat: implement material loading and rendering
Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-10 12:24:30 -04:00
alphafetusandClaude Sonnet 5 4d9a0c8b43 feat: route mesh access through AssetManager instead of MeshRegistry
AssetManager now owns scene loading and single-model registration
(MeshRegistry::register_mesh appends a mesh into the shared buffers
and rebuilds them), and exposes vertex/index buffers and mesh lookups.
app.rs and RenderBatch now go through AssetManager rather than talking
to MeshRegistry directly, so material lookups can be added there later
without touching callers again.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01986QNHM1cUsnRskKvBbbuo
2026-09-10 11:42:09 -04:00
alphafetusandClaude Sonnet 5 9a93c0d189 feat: add submesh support for mesh loading and rendering
Meshes now track per-primitive submesh ranges (index range + source
material index) instead of one flat index range each. glTF meshes get
one submesh per primitive; OBJ meshes get a single default submesh
until .mtl loading exists. MeshRegistry rewrites these into offsets
into its shared index buffer, and the renderer issues one draw call
per submesh so each can later be bound to its own material.

Also fixes app.rs to match the current MeshRegistry API (load_scene
instead of the removed from_scene, and Option-wrapped buffers).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01986QNHM1cUsnRskKvBbbuo
2026-09-10 11:31:05 -04:00
alphafetusandClaude Sonnet 5 fb64fa50e4 wip: checkpoint mid-refactor of asset loading before submesh work
Moves mesh/material loaders under src/assets/loaders, renames Mesh to
MeshHandle, and begins scaffolding the material loader. Known-broken
build state (MeshRegistry::from_scene call site and asset_manager
mesh registration are out of sync) — committed as a rollback point
before implementing submeshes.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01986QNHM1cUsnRskKvBbbuo
2026-09-10 11:20:39 -04:00