vtf-logo

BRep< 3, T > Class Template Reference

A class for a b-rep in 3-D. More...

List of all members.

Public Types

typedef Base::SizeType SizeType
 The size type.
typedef T Number
 The number type.
typedef ads::FixedArray<
3, Number
Point
 A point in 3-D.
typedef ads::FixedArray<
3, int > 
Index
 A multi-index in 3-D.
typedef geom::BBox< 3, NumberBBox
 A bounding box.
typedef geom::RegularGrid<
3, T > 
Lattice
 The lattice.
typedef Grid< 3, NumberGrid
 The grid type stores the arrays for distance, closest point, etc.

Public Member Functions

 BRep ()
 Default constructor. An empty b-rep.
 BRep (const BRep &other)
 Copy constructor.
BRep & operator= (const BRep &other)
 Assignment operator.
 ~BRep ()
 Destructor.
 BRep (const SizeType verticesSize, const void *vertices, const SizeType simplicesSize, const void *indexedSimplices, const BBox &cartesianDomain, const Number maximumDistance)
 Construct from vertices and faces. Throw away irrelevant ones.
void make (const SizeType verticesSize, const void *vertices, const SizeType simplicesSize, const void *indexedSimplices)
 Make from vertices and faces.
void make (const SizeType verticesSize, const void *vertices, const SizeType simplicesSize, const void *indexedSimplices, const BBox &cartesianDomain, const Number maximumDistance)
 Make from vertices and faces.
int getMaximumFaceIdentifier () const
 Return the maximum face identifier.
std::pair< int, int > computeClosestPoint (const Lattice &lattice, std::vector< Grid > *grids, Number maximumDistance) const
 Calculate the closest point transform with signed distance to this b-rep.
std::pair< int, int > computeClosestPointUnsigned (const Lattice &lattice, std::vector< Grid > *grids, Number maximumDistance) const
 Calculate the closest point transform with unsigned distance to this b-rep.
std::pair< int, int > computeClosestPointUsingBBox (const Lattice &lattice, std::vector< Grid > *grids, Number maximumDistance) const
 Use bounding boxes around the characteristic polyhedra instead of polyhedron scan conversion.
std::pair< int, int > computeClosestPointUnsignedUsingBBox (const Lattice &lattice, std::vector< Grid > *grids, Number maximumDistance) const
 Use bounding boxes around the characteristic polyhedra instead of polyhedron scan conversion.
std::pair< int, int > computeClosestPointUsingBruteForce (const Lattice &lattice, std::vector< Grid > *grids, Number maximumDistance) const
 Use bounding boxes around the primitives instead of polyhedron scan conversion.
std::pair< int, int > computeClosestPointUnsignedUsingBruteForce (const Lattice &lattice, std::vector< Grid > *grids, Number maximumDistance) const
 Use bounding boxes around the primitives instead of polyhedron scan conversion.
BBox computeBBox () const
 Return the bounding box that contains the mesh.
void displayInformation (std::ostream &out) const
 Display information about the b-rep.
void display (std::ostream &out) const
 Display the b-rep.


Detailed Description

template<typename T>
class BRep< 3, T >

A class for a b-rep in 3-D.


Constructor & Destructor Documentation

template<typename T>
BRep< 3, T >::BRep ( const SizeType  verticesSize,
const void *  vertices,
const SizeType  simplicesSize,
const void *  indexedSimplices,
const BBox cartesianDomain,
const Number  maximumDistance 
) [inline]

Construct from vertices and faces. Throw away irrelevant ones.

Parameters:
verticesSize The number of vertices.
vertices The vertices.
simplicesSize The number of triangle faces.
indexedSimplices The indexed triangle faces.
cartesianDomain is the domain of interest.
maximumDistance is how far the distance will be computed.
Make the b-rep from vertex coordinates and face indices. Clip the b-rep so that faces outside the relevant Cartesian domain are thrown away. (Any face within maximumDistance of cartesianDomain is regarded as relevant.)

This constructor calls make() with the same arguments.


Member Function Documentation

template<typename T>
std::pair< int, int > BRep< 3, T >::computeClosestPoint ( const Lattice lattice,
std::vector< Grid > *  grids,
Number  maximumDistance 
) const [inline]

Calculate the closest point transform with signed distance to this b-rep.

Calculate the signed distance, closest point, etc. to this b-rep for all the points in the grid.

Parameters:
lattice is the lattice on which the grids lie.
grids is the container of grids. Each one holds the distance, closest point, etc. arrays.
maximumDistance is the distance to calculate distance away from the surface.
Returns:
Return the number of points scan converted and the number of points for which the distance was computed.

template<typename T>
std::pair< int, int > BRep< 3, T >::computeClosestPointUnsigned ( const Lattice lattice,
std::vector< Grid > *  grids,
Number  maximumDistance 
) const [inline]

Calculate the closest point transform with unsigned distance to this b-rep.

Calculate the unsigned distance, closest point, etc. to this b-rep for all the points in the grid.

Parameters:
lattice is the lattice on which the grids lie.
grids is the container of grids. Each one holds the distance, closest point, etc. arrays.
maximumDistance is the distance to calculate distance away from the surface.
Returns:
Return the number of points scan converted and the number of points for which the distance was set.

template<typename T>
void BRep< 3, T >::displayInformation ( std::ostream &  out  )  const [inline]

Display information about the b-rep.

Report if the manifold is closed.

template<typename T>
void BRep< 3, T >::make ( const SizeType  verticesSize,
const void *  vertices,
const SizeType  simplicesSize,
const void *  indexedSimplices,
const BBox cartesianDomain,
const Number  maximumDistance 
) [inline]

Make from vertices and faces.

Parameters:
verticesSize The number of vertices.
vertices The vertices.
simplicesSize The number of triangle faces.
indexedSimplices The indexed triangle faces.
cartesianDomain is the domain of interest.
maximumDistance is how far the distance will be computed.
Make the b-rep from vertex coordinates and face indices. Clip the b-rep so that faces outside the relevant Cartesian domain are thrown away. (Any face within maximumDistance of cartesianDomain is regarded as relevant.)

template<typename T>
void BRep< 3, T >::make ( const SizeType  verticesSize,
const void *  vertices,
const SizeType  simplicesSize,
const void *  indexedSimplices 
) [inline]

Make from vertices and faces.

Parameters:
verticesSize The number of vertices.
vertices The vertices.
simplicesSize The number of triangle faces.
indexedSimplices The indexed triangle faces.


The documentation for this class was generated from the following file:
Generated on Fri Aug 24 12:55:43 2007 for Closest Point Transform by  doxygen 1.4.7