Skip navigation

The description on Wikipedia is ok, but here’s more.

Marching cubes is all about filling the space with cubes, and “cutting the cubes” by triangles if the isosurface cuts through the cube.

This talk by Shewchuk is great to help understand what an isosurface is, etc.

Now, there’s all this talk about 256 possible cube configurations. What’s that about.

Well the cube has 8 vertices. Pretend being inside the isosurface means the vertex is “wet”. Assuming the cube could dip in and out of the isosurface on any of those 8 vertices, means there are 2^8=256 possible configurations for the vertices to be “wet” (inside the isosurface).

The case where the cube is “completely dry” is when no vertices are inside the isosurface. If I put one corner in the isosurface, then one vertex is “wet”. But wait! There are 8 ways that “one corner” can be wet, because there are 8 corners on a cube. So each of the 8 corners can be in one of 2 states (“wet” or “dry”), means there are 2^8 possible configurations for the corners to be wet and dry. This actually boils down to just 14 cases if you exploit symmetry (ie consider the case of “one vertex being wet” as one case, not 8 cases).

This is easier to understand if you look at a square.

So there, we have 4 vertices, so 2^4=16 cases. case 0 is “dry”. case 1 has 1 vertex wet, and there are 4 symmetric cases. Case 2 has 2 adjacent corners.. etc. Just look at the diagram.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: