Various triangle functions. More...
#include <meshTools/triangleFuncs.H>
Various triangle functions.
Definition at line 55 of file triangleFuncs.H.
Public Types | |
enum | proxType { NONE, POINT, EDGE } |
Enumeration defining nearness classification. More... | |
Static Public Member Functions | |
static bool | intersectAxesBundle (const point &V0, const point &V10, const point &V20, const label i0, const pointField &origin, const scalar maxLength, point &pInter) |
Intersect triangle with parallel edges aligned with axis i0.
| |
static bool | intersectBb (const point &p0, const point &p1, const point &p2, const treeBoundBox &cubeBb) |
Does triangle intersect bounding box.
| |
static bool | intersect (const point &va0, const point &va10, const point &va20, const point &basePoint, const vector &normal, point &pInter0, point &pInter1) |
Does triangle intersect plane. Return bool and set intersection segment.
| |
static bool | intersect (const point &va0, const point &va10, const point &va20, const point &vb0, const point &vb10, const point &vb20, point &pInter0, point &pInter1) |
Do triangles intersect. Return bool and set intersection segment.
|
enum proxType |
Enumeration defining nearness classification.
Definition at line 63 of file triangleFuncs.H.
bool intersectAxesBundle | ( | const point & | V0, |
const point & | V10, | ||
const point & | V20, | ||
const label | i0, | ||
const pointField & | origin, | ||
const scalar | maxLength, | ||
point & | pInter | ||
) | [static]
|
Intersect triangle with parallel edges aligned with axis i0.
Returns true (and intersection in pInter) if any of them intersects triangle. Used in intersectBb.
Definition at line 85 of file triangleFuncs.C.
References beta(), Foam::det(), forAll, Foam::mag(), v1, and v2.
bool intersectBb | ( | const point & | p0, |
const point & | p1, | ||
const point & | p2, | ||
const treeBoundBox & | cubeBb | ||
) | [static]
|
Does triangle intersect bounding box.
Definition at line 172 of file triangleFuncs.C.
References treeBoundBox::intersects(), boundBox::max(), Foam::max(), Foam::min(), boundBox::min(), Vector< Cmpt >::x(), Vector< Cmpt >::y(), and Vector< Cmpt >::z().
Referenced by octreeDataTriSurface::overlaps(), octreeDataFace::overlaps(), treeDataTriSurface::overlaps(), and treeDataFace::overlaps().
bool intersect | ( | const point & | va0, |
const point & | va10, | ||
const point & | va20, | ||
const point & | basePoint, | ||
const vector & | normal, | ||
point & | pInter0, | ||
point & | pInter1 | ||
) | [static]
|
Does triangle intersect plane. Return bool and set intersection segment.
Definition at line 526 of file triangleFuncs.C.
References Foam::mag(), and Foam::sqrt().
bool intersect | ( | const point & | va0, |
const point & | va10, | ||
const point & | va20, | ||
const point & | vb0, | ||
const point & | vb10, | ||
const point & | vb20, | ||
point & | pInter0, | ||
point & | pInter1 | ||
) | [static]
|
Do triangles intersect. Return bool and set intersection segment.
Definition at line 644 of file triangleFuncs.C.
References SortableList< T >::indices(), Foam::mag(), and SortableList< T >::sort().