#include <cg3d.h>
Public Member Functions | |
Planar3d (PointSet3d *ps_) | |
int | getPoints (void) const |
int | getPointIndex (int p) const |
const CkVector3d & | getPoint (int p) const |
void | addPoint (int ptIdx) |
Add a new point along our boundary. Points must be presented in order. | |
void | addPoint (int pt0, int pt1, int pt2) |
void | addPoint (int pt0, int pt1, int pt2, int pt3) |
bool | addConstraint (int halfspace) |
Clip this shape to lie within this halfspace. | |
Private Types | |
enum | { maxPts = 4+2*6 } |
Private Attributes | |
PointSet3d * | ps |
int | nPts |
int | pts [maxPts] |
This typically represents the face of some shape.
The representation is a chain of boundary points, which are split and queried as each halfspace is intersected.
Definition at line 105 of file cg3d.h.
Planar3d::Planar3d | ( | PointSet3d * | ps_ | ) |
int cg3d::Planar3d::getPoints | ( | void | ) | const [inline] |
Definition at line 112 of file cg3d.h.
References nPts.
Referenced by cg3d::Volume3dDest::addFace(), and cg3d::intersect().
Definition at line 113 of file cg3d.h.
References pts.
Referenced by cg3d::intersect().
const CkVector3d& cg3d::Planar3d::getPoint | ( | int | p | ) | const [inline] |
Definition at line 114 of file cg3d.h.
References cg3d::PointSet3d::getPoint(), ps, and pts.
Referenced by addConstraint(), and cg3d::Volume3dDest::addFace().
void cg3d::Planar3d::addPoint | ( | int | ptIdx | ) | [inline] |
Add a new point along our boundary. Points must be presented in order.
Definition at line 118 of file cg3d.h.
Referenced by cg3d::Tet3d::getFace().
Clip this shape to lie within this halfspace.
Returns false if we are made empty by the intersection.
Returns true if we are made empty by the intersection.
Definition at line 73 of file cg3d.C.
References cg3d::PointSet3d::addPoint(), cg3d::PointSet3d::getHalfspace(), getPoint(), h, CkHalfspace3d::intersectPt(), cg3d::PointSet3d::isOutside(), maxPts, nPts, ps, and pts.
Referenced by cg3d::intersect().
PointSet3d* cg3d::Planar3d::ps [private] |
int cg3d::Planar3d::nPts [private] |
Definition at line 107 of file cg3d.h.
Referenced by addConstraint(), addPoint(), getPoints(), and Planar3d().
int cg3d::Planar3d::pts[maxPts] [private] |
Definition at line 108 of file cg3d.h.
Referenced by addConstraint(), addPoint(), getPoint(), and getPointIndex().