Skip to content

Fix/core matid preservation#3

Open
HellAngel18 wants to merge 2 commits into
mainfrom
fix/core-matid-preservation
Open

Fix/core matid preservation#3
HellAngel18 wants to merge 2 commits into
mainfrom
fix/core-matid-preservation

Conversation

@HellAngel18
Copy link
Copy Markdown
Owner

No description provided.

- CMakeLists: add binary dir include path and link VCGSimplifier for CLI target
- SaveGLB: keep images in BIN chunk instead of Base64 data URI encoding
- main: recover material IDs after simplification via nearest-centroid matching
- Fixes issue where simplified GLB lost all textures (all faces mapped to mat 0)
  and output file was larger than input due to Base64 image bloat

Made-with: Cursor
- Add nearest-centroid matId recovery in SimplifyDetailed() so all callers
  (CLI, DLL API, engine plugins) benefit from material preservation
- Remove CLI-only workaround from main.cpp
- matId is now saved before simplification and restored after via centroid
  matching, compensating for VCG QEM not propagating custom face attributes

Made-with: Cursor
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant