Basic Image AlgorithmS Library  2.8.0
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Public Member Functions | Protected Member Functions | List of all members
BIAS::MarchingCubes Class Reference

creates a closed mesh from a set of points. More...

#include <Utils/MarchingCubes.hh>

Public Member Functions

 MarchingCubes ()
 
int PolygoniseCube (MarchingCubesGridCell grid, double isolevel, MarchingCubesTriangle *triangles)
 Given a grid cell and an isolevel, calculate the triangular facets required to represent the isosurface through the cell. More...
 
virtual ~MarchingCubes ()
 

Protected Member Functions

BIAS::Vector3< double > InterpolateVertex_ (double isolevel, BIAS::Vector3< double > p1, BIAS::Vector3< double > p2, double valp1, double valp2)
 

Detailed Description

creates a closed mesh from a set of points.

This class only calculates the intersecting triangles of one cube, call multiple times for all points in the point cloud. Implements the algorithm in Lornsen1987:Marching Cubes

Author
ischiller
Date
08/2010

Definition at line 54 of file MarchingCubes.hh.

Constructor & Destructor Documentation

BIAS::MarchingCubes::MarchingCubes ( )

Definition at line 357 of file MarchingCubes.cpp.

BIAS::MarchingCubes::~MarchingCubes ( )
virtual

Definition at line 360 of file MarchingCubes.cpp.

Member Function Documentation

BIAS::Vector3< double > BIAS::MarchingCubes::InterpolateVertex_ ( double  isolevel,
BIAS::Vector3< double >  p1,
BIAS::Vector3< double >  p2,
double  valp1,
double  valp2 
)
protected

Definition at line 442 of file MarchingCubes.cpp.

int BIAS::MarchingCubes::PolygoniseCube ( MarchingCubesGridCell  grid,
double  isolevel,
MarchingCubesTriangle triangles 
)

Given a grid cell and an isolevel, calculate the triangular facets required to represent the isosurface through the cell.

Parameters
grid[in],:the 8 grid cell corners which include coordinates and weights the weight of unoccupied corners should be 0, the weight if valid corners should be > 0 and > isolevel (parameter 2). The surface through the cube will be calculated according to these weights.
isolevel[in],:isolevel of the cube
triangles[out],:output triangles will be loaded up with the vertices at most 5 triangular facets.
Returns
the number of triangular facets 0 will be returned if the grid cell is either totally above of totally below the isolevel.

Definition at line 365 of file MarchingCubes.cpp.

References BIAS::edgeTable, BIAS::MarchingCubesTriangle::p, BIAS::MarchingCubesGridCell::p, BIAS::triTable, and BIAS::MarchingCubesGridCell::val.


The documentation for this class was generated from the following files: