-
Notifications
You must be signed in to change notification settings - Fork 226
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat request / question : exporting optimized meshes with no redundant vertices (possible workaround via Blender) #387
Comments
Thanks for the detailed explanation. Currently goxel uses meshoptimzer [1] to simplify the meshes before glTF export. Maybe there are better alternatives? Or the options I used are not optimal. I am not too sure about that. |
NOTEs the code making it happen is here goxel/src/volume_to_vertices.c Lines 370 to 422 in 292588c
it uses this struct Lines 74 to 92 in 292588c
and is being called from there goxel/src/volume_to_vertices.c Lines 422 to 463 in 292588c
@guillaumechereau a question: I have a feeling it might be easier to just implement the algorithm from scratch, instead of messing with the general purpose library. I may give it a try. |
I'm having a problem with this too. Im trying to bring this rather large model into unity. 2024-08-18.14-20-43.mp4It has way to many verticies. I tried goxel's simplifiy gltf feature to Blender Decimate (No simplifiy on export):
Yes, Blender seems to "decimate" the colors too lol. Jokes aside, thank you these videos are helpful, it gives me a starting point |
I've figured it out! You were right on track! You actually need to select Delimit UVs!
2024-08-18.15-22-41.mp4I don't know if I can be of any help in regards to re writing the algo. But it seems that it needs to focus on grouping voxels of like colors on surfaces and taking those into account before simplifying vertices. Maybe some code from the magic wand tool with the |
Hey yet again,
Right away, I'm just gonna say this is most likely a dupe of #315
I opened a new ticket as the other one is pretty lengthy already and mine will be too.
I'm looking for a way to export meshes that are "kinda production-ready", with as little amount of vertices as possible and with colors included. As I understand the problem with colors is well known (e.g. #203) and solvable depending on the format of exported file. The problem with vertices is a bit bigger though.
There are two issues with vertices (mostly tested with .gltf and .obj):
2024-08-08_18-27-52.mp4
So, I solved both those issues via Blender.
Pasting instructions here in case someone has a similar problem:
2024-08-08_18-57-23.mp4
However, my solution isn't perfect. I already noticed that depending on which step is applied as the first one, this can either mess the colors (as seen on video above) or leave the vertices inside of geometry. I'm still looking for something better and will try to automate it at some point.
Is there a way to export meshes without those problems?
Is there any better workaround to the one I use?
Thanks
The text was updated successfully, but these errors were encountered: