#[SOLVED] Holes in my marching cubes implementation

10 messages · Page 1 of 1 (latest)

hexed osprey
#

I have been trying to make my marching cubes implementation work without success.

I made some checks to make sure that its not my mesh builder what is not working.

I believe there's something wrong with the marching cubes implementation, but I'm copying it from the Paul Borke's one, and Im checking other implementations and I fail to understand what can be happening.

I also tried with the tetrahedron approach in Paul Borke website and it leads to the same issue.

Here it is the code:
https://github.com/alesegdia/aether/blob/master/src/aether/plugin/marchingcubes/MarchingCubes.cpp

Also the code of the example that makes use of the marching cubes implementation:
https://github.com/alesegdia/aether/blob/master/examples/11-marching-cubes/MarchingCubesApp.cpp

Here it is a video showing the issue. For illustrating it, I generated a sphere so the issues can be properly seen:

https://www.youtube.com/watch?v=BTkAp3VxbmU

I'm a bit lost. I am mostly sure that it's not an issue of the mesh generation itself, but something tells me that there are some issues with the triangles somehow.

Maybe someone can think of some clues that I have not covered yet to investigate about this issue. Thanks in advance!

GitHub

Game development framework with multi platform intentions - alesegdia/aether

GitHub

Game development framework with multi platform intentions - alesegdia/aether

burnt saddle
#

Unless it's something simple that one can recognize a mile away, you're going to have hard time finding people willing that are willing to download, build and debug your code, as as general debugging here are a few tips:

  1. Instead of copying code, understand it.
  2. Instead of debugging large piece of code with unknown inputs, debug small pieces of code with known inputs
hexed osprey
#

hello @burnt saddle ! I fixed it just a bit after posting the message 😅

#

the issue was that I was not getting the proper order on the vertices of the voxel

#

when feeding the polygonise method

#

can I set this question as answered?

burnt saddle
#

Do you feel it has been answered/solved? then yes 😄

hexed osprey
#

aaah the thing is I don't see how 😂

#

maybe just change the title?

#

[SOLVED] Holes in my marching cubes implementation