Public Types | |
| typedef T | Number |
| The number type. | |
|
typedef ads::FixedArray< 3, Number > | Point |
| A Cartesian point. | |
|
typedef geom::IndexedEdgePolyhedron< Number > | Polyhedron |
| An indexed edge polyhedron type. | |
Public Member Functions | |
Constructors, etc. | |
| Face () | |
| Default constructor. Unititialized memory. | |
| Face (const Point &vertex1, const Point &vertex2, const Point &vertex3, const Point &normal, const int index) | |
| Construct a face from three vertices, a normal and the face index. | |
| Face (const Face &other) | |
| Copy constructor. | |
| Face & | operator= (const Face &other) |
| Assignment operator. | |
| void | make (const Point &vertex1, const Point &vertex2, const Point &vertex3, const Point &normal, const int index) |
| Make a face from three vertices, a normal and the face index. | |
| ~Face () | |
| Trivial destructor. | |
Accessors. | |
|
const ads::FixedArray< 3, Point > & | getVertices () const |
| Return the vertices. | |
| const Plane & | getSupportingPlane () const |
| Return the face. | |
|
const ads::FixedArray< 3, Plane > & | getSides () const |
| Return the sides. | |
| const Point & | getNormal () const |
| Return the normal to the face. | |
| const Point & | getSideNormal (const int i) const |
| Return the i_th side normal. | |
| int | getFaceIndex () const |
| Return the index of this face in the b-rep. | |
Mathematical operations. | |
| bool | isValid () const |
| Return true if the face is valid. | |
| Number | computeDistance (const Point &p) const |
| Return the signed distance to the supporting plane of the face. | |
| Number | computeDistanceChecked (const Point &p) const |
| Compute distance with checking. | |
| Number | computeDistanceUnsigned (const Point &p) const |
| Return the unsigned distance to the supporting plane of the face. | |
| Number | computeDistanceUnsignedChecked (const Point &p) const |
| Return the unsigned distance to the face. | |
| Number | computeClosestPoint (const Point &p, Point *cp) const |
| Return the distance and find the closest point. | |
| Number | computeClosestPointChecked (const Point &p, Point *cp) const |
| Return the distance and find the closest point. | |
| Number | computeClosestPointUnsigned (const Point &p, Point *cp) const |
| Return the unsigned distance and find the closest point. | |
| Number | computeClosestPointUnsignedChecked (const Point &p, Point *cp) const |
| Return the unsigned distance and find the closest point. | |
| Number | computeGradient (const Point &p, Point *grad) const |
| Return the distance and find the gradient of the distance. | |
| Number | computeGradientChecked (const Point &p, Point *grad) const |
| Return the distance and find the gradient of the distance. | |
| Number | computeGradientUnsigned (const Point &p, Point *grad) const |
| Return the unsigned distance and find the gradient of the unsigned distance. | |
| Number | computeGradientUnsignedChecked (const Point &p, Point *grad) const |
| Return the unsigned distance and find the gradient of the unsigned distance. | |
| Number | computeClosestPointAndGradient (const Point &p, Point *cp, Point *grad) const |
| Return the distance and find the closest point and gradient of distance. | |
| Number | computeClosestPointAndGradientChecked (const Point &p, Point *cp, Point *grad) const |
| Return the distance and find the closest point and gradient of distance. | |
| Number | computeClosestPointAndGradientUnsigned (const Point &p, Point *cp, Point *grad) const |
| Return the distance and find the closest point and gradient of distance. | |
| Number | computeClosestPointAndGradientUnsignedChecked (const Point &p, Point *cp, Point *grad) const |
| Return the distance and find the closest point and gradient of distance. | |
| void | buildCharacteristicPolyhedron (Polyhedron *polyhedron, const Number height) const |
| Make the characteristic polyhedron containing the closest points. | |
| void Face< 3, T >::buildCharacteristicPolyhedron | ( | Polyhedron * | polyhedron, | |
| const Number | height | |||
| ) | const [inline] |
Make the characteristic polyhedron containing the closest points.
The face is a triangle. Consider the larger triangle made by moving the sides outward by delta. Make a triangular prizm of height, 2 * height, with the given triangle at its center.
| Face< 3, T >::Number Face< 3, T >::computeClosestPointAndGradientChecked | ( | const Point & | p, | |
| Point * | cp, | |||
| Point * | grad | |||
| ) | const [inline] |
Return the distance and find the closest point and gradient of distance.
The points that are closest to the face lie in a triangular prizm. If the point, p, is within a distance, delta, of being inside the prizm then return the distance. Otherwise return infinity.
| Face< 3, T >::Number Face< 3, T >::computeClosestPointAndGradientUnsignedChecked | ( | const Point & | p, | |
| Point * | cp, | |||
| Point * | grad | |||
| ) | const [inline] |
Return the distance and find the closest point and gradient of distance.
The points that are closest to the face lie in a triangular prizm. If the point, p, is within a distance, delta, of being inside the prizm then return the distance. Otherwise return infinity.
| Face< 3, T >::Number Face< 3, T >::computeClosestPointChecked | ( | const Point & | p, | |
| Point * | cp | |||
| ) | const [inline] |
Return the distance and find the closest point.
The points that are closest to the face lie in a triangular prizm. If the point, p, is within a distance, delta, of being inside the prizm then return the distance. Otherwise return infinity.
| Number Face< 3, T >::computeClosestPointUnsignedChecked | ( | const Point & | p, | |
| Point * | cp | |||
| ) | const [inline] |
Return the unsigned distance and find the closest point.
The points that are closest to the face lie in a triangular prizm. If the point, p, is within a distance, delta, of being inside the prizm then return the distance. Otherwise return infinity.
| Face< 3, T >::Number Face< 3, T >::computeDistanceChecked | ( | const Point & | p | ) | const [inline] |
Compute distance with checking.
The points that are closest to the face lie in a triangular prizm. If the point, p, is within a distance, delta, of being inside the prizm then return the distance. Otherwise return infinity.
| Number Face< 3, T >::computeDistanceUnsignedChecked | ( | const Point & | p | ) | const [inline] |
Return the unsigned distance to the face.
The points that are closest to the face lie in a triangular prizm. If the point, p, is within a distance, delta, of being inside the prizm then return the distance. Otherwise return infinity.
| Face< 3, T >::Number Face< 3, T >::computeGradientChecked | ( | const Point & | p, | |
| Point * | grad | |||
| ) | const [inline] |
Return the distance and find the gradient of the distance.
The points that are closest to the face lie in a triangular prizm. If the point, p, is within a distance, delta, of being inside the prizm then return the distance. Otherwise return infinity.
| Face< 3, T >::Number Face< 3, T >::computeGradientUnsignedChecked | ( | const Point & | p, | |
| Point * | grad | |||
| ) | const [inline] |
Return the unsigned distance and find the gradient of the unsigned distance.
The points that are closest to the face lie in a triangular prizm. If the point, p, is within a distance, delta, of being inside the prizm then return the distance. Otherwise return infinity.
1.4.7