## marching cubes and shared points between cubes

### marching cubes and shared points between cubes

I have just implemented the marching cubes algorithm, but it generates
an excessive amount of points.
Finding shared points and edges locally within each cube is trivial
because of the edge table used.
What I cannot figure out, is how to calculate shared points and edges
between adjacent cubes. All points calculated lie on the edges of the
cube, which means that, a point can be shared by up to four cubes (this
would almost never happen in reality).
If anyone got a realtime solution that solves this problem, I would be
grateful if they would share it with me.

--
-Gorm Lai aka. Pharao^Cromatics--
2nd year CS & Math Student
http://www.daimi.aau.dk/~pharao/

### marching cubes and shared points between cubes

>  I have just implemented the marching cubes algorithm, but it generates
>  an excessive amount of points.
>  Finding shared points and edges locally within each cube is trivial
>  because of the edge table used.
>  What I cannot figure out, is how to calculate shared points and edges
>  between adjacent cubes. All points calculated lie on the edges of the
>  cube, which means that, a point can be shared by up to four cubes (this
>  would almost never happen in reality).

I use a point table, an edge table and a cube table. An edge belonging to
multple cubes is not replicated several times but has a single entry into
the edge table (cubes have references to the edges and vertices, edges have
references to the extreme points). So when you evaluate one subdivision for
an edge just switch a flag on and first time you use a cube sharing the same
edge (since you have a reference) you just have to check the flag and get
the subdivision point found (that is an entry into the points table).

Hope this help.

--
Andrea Bottino
Politecnico di Torino, DAUIN
Corso Duca degli Abruzzi, 24
10129 Torino ITALY
Tel +39 011 5647084 / Fax +39 011 5647099
http://www.polito.it/~bottino

Hello everyone,

I am writing a code to build Isosurfaces using marching cube method. My
question is if there is an algorithm of finding "seed cubes" with
constant or linear time.  Specificly, I have a "ni" by "nj" by "nk" grid
and a surface intersecting it. How to find the first cube intersected by
the surface with constant or linear time?

Any of your suggestion is appreciated.

Xinlong Wang