-
-
Notifications
You must be signed in to change notification settings - Fork 241
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
VoxelMeshSDF BAKE_MODE_ACCURATE_PARTITIONED does not accurately bake PrismMesh #659
Comments
That mode creates a data structure referencing triangles in chunks, and I suspect triangles are missing near the area that has the "gap" you mention. That mode uses a Looking more into it, I think it's simply not working properly when triangles are too big relatively to chunks: i.e if you have a mesh with only a few triangles, but subdivided so much that the AABB of triangles cover a lot of chunks, the tricks What issue is that really causing? |
It's not really causing big noticable issues (it can be noticed using |
Added some info in the docs in cab1b7e Some ideas to improve the algorithm: godot_voxel/edition/mesh_sdf.cpp Lines 423 to 433 in 2972862
|
Describe the bug
VoxelMeshSDF'S BAKE_MODE_ACCURATE_PARTITIONED produces big gap between SDF values when baking PrismMesh. This does not happen with BAKE_MODE_ACCURATE_NAIVE.
More specifically, baking a mesh with BAKE_MODE_ACCURATE_PARTITIONED, one can notice "SDF gap" in visualisation between layers 13 and 14.
Switching to BAKE_MODE_ACCURATE_NAIVE and checking visualised SDF between layers 13 and 14 show no "SDF gap".
Additional info:
I've noticed this issue happen with pyramid mesh as well.
See video:
2024-06-12.23-37-10.mp4
To Reproduce
Steps to reproduce the behavior:
VoxelModifierMesh
node to scene.VoxelModifierMesh
create PrismMesh.BAKE_MODE_ACCURATE_PARTITIONED
.Bake
.BAKE_MODE_ACCURATE_NAIVE
instead.Expected behavior
SDF produced values by
BAKE_MODE_ACCURATE_PARTITIONED
should be very similar toBAKE_MODE_ACCURATE_NAIVE
.Environment
MRP
Test VoxelMeshSDF partitioned pyramid bake issue.zip
The text was updated successfully, but these errors were encountered: