grid-simplification
Geometry based simplification of a 3 dimensional tetrahedral grids.
Demo
The tetrahedralization is a bit weird, so some points are falsely classified, but it's enough to terminate the algorithm and demonstrate the general approach.
Basically the grid is simplified by collapsing cell edges. To keep the characteristic boundary of the grid, only complete inner or complete boundary edges are collapsed. The algorithms works roughly like this:
- Classify all vertices as inner, surfce or corner/edge
- Calculate the cost of possible edge collapses (here the simple approach is to let cost be driven by the edge length.)
- Choose the cheapest collapse (shorted edge)
- Collapse the edge onto its midpoint, for a edge e(a,b) move 'a' to the midpoint and remove 'b'
- Update all cells affected by the collapse
- Remove all cells which where incident on the collapsed edge
- goto #2
- The algorithms terminates if there are no more edges which can be considered for a collapse.
The cost function can be easily expanded to consider values stored at vertices thus retaining iso surfaces of the volumen data.