vtf-logo

geom::ScanConversionPolyhedron< T > Class Template Reference

A class for a polyhedron in 3-D designed for scan conversion. More...

#include <ScanConversionPolyhedron.h>

List of all members.

Public Types

typedef T Number
 The floating point number type.
typedef ads::FixedArray<
3, Number
Point
 The representation of a point in 3 dimensions.
typedef SegmentMath< 3, NumberSegment
 A line segment that supports mathematical operations.

Public Member Functions

Constructors etc.
 ScanConversionPolyhedron ()
 Default constructor. Uninitialized memory.
 ScanConversionPolyhedron (const ScanConversionPolyhedron &other)
 Copy constructor.
ScanConversionPolyhedronoperator= (const ScanConversionPolyhedron &other)
 Assignment operator.
ScanConversionPolyhedronoperator= (const IndexedEdgePolyhedron< Number > &x)
 Assignment operator from an IndexedEdgePolyhedron.
 ~ScanConversionPolyhedron ()
 Trivial destructor.
Mathematical functions.
void computeBBox (BBox< 3, Number > *bb) const
 Make a BBox containing the polyhedron.
void convertLocationsToIndices (const RegularGrid< 3, Number > &grid)
 Convert the Cartesian coordinates of this polyhedron to index coordinates.
template<typename IndexOutputIterator>
void scanConvert (IndexOutputIterator coordinates, const RegularGrid< 3, Number > &grid) const
 Scan convert the polyhedron.
Accesors.
const std::vector< Segment > & getEdges () const
 Return a const reference to the edges.
Manipulators.
void clear ()
 Clear the edges.
void insertEdge (const Point &p, const Point &q)
 Add an edge to the polyhedron.

Related Functions

(Note that these are not member functions.)

std::ostream & operator<< (std::ostream &out, const ScanConversionPolyhedron< T > &polyhedron)
 Write the edges.
void mathematicaPrint (std::ostream &out, const ScanConversionPolyhedron< T > &polyhedron)
 Write the edges in Mathematica readable format.
std::istream & operator>> (std::istream &in, ScanConversionPolyhedron< T > &polyhedron)
 Read as a list of edges.
bool operator== (const ScanConversionPolyhedron< T > &a, const ScanConversionPolyhedron< T > &b)
 Return true if the polyhedra are equal.
bool operator!= (const ScanConversionPolyhedron< T > &a, const ScanConversionPolyhedron< T > &b)
 Return true if the polyhedra are not equal.


Detailed Description

template<typename T = double>
class geom::ScanConversionPolyhedron< T >

A class for a polyhedron in 3-D designed for scan conversion.

Parameters:
T is the number type. By default it is double.
As the name suggests, this class is designed for 3-D polyhedron scan conversion. The Polyhedron is represented as a set of edges. The edges support mathematical operations that enable efficient slicing to obtain polygons. This, in turn, enables efficient scan conversion.


Member Function Documentation

template<typename T = double>
template<typename IndexOutputIterator>
void geom::ScanConversionPolyhedron< T >::scanConvert ( IndexOutputIterator  coordinates,
const RegularGrid< 3, Number > &  grid 
) const

Scan convert the polyhedron.

Parameters:
coordinates is an output iterator for the set of coordinates inside.
grid describes the grid on which to perform the scan conversion.


The documentation for this class was generated from the following file:
Generated on Fri Aug 24 12:56:03 2007 for Computational Geometry Package by  doxygen 1.4.7