![]() |
|
Public Types | |
enum | proxType { NONE, POINT, EDGE } |
Return types for classify. More... | |
Public Member Functions | |
triangle (const Point &a, const Point &b, const Point &c) | |
Construct from three points. | |
triangle (Istream &) | |
Construct from Istream. | |
const Point & | a () const |
Return first vertex. | |
const Point & | b () const |
Return second vertex. | |
const Point & | c () const |
Return third vertex. | |
Point | centre () const |
Return centre (centroid). | |
scalar | mag () const |
Return scalar magnitude. | |
vector | normal () const |
Return vector normal. | |
vector | circumCentre () const |
Return circum-centre. | |
scalar | circumRadius () const |
Return circum-radius. | |
scalar | quality () const |
Return quality: Ratio triangle and circum-circle area. | |
scalar | sweptVol (const triangle &t) const |
Return swept-volume. | |
pointHit | ray (const point &p, const vector &q, const intersection::algorithm=intersection::FULL_RAY, const intersection::direction dir=intersection::VECTOR) const |
Return point intersection with a ray. | |
pointHit | nearestPoint (const point &p) const |
Return nearest point to p on triangle. | |
bool | classify (const point &p, const scalar tol, label &nearType, label &nearLabel) const |
Classify point in triangle plane w.r.t. triangle edges. | |
Friends | |
Istream & | operator>> (Istream &, triangle &) |
Ostream & | operator (Ostream &, const triangle &) |
|
Return types for classify.
Definition at line 130 of file triangle.H. |
|
Construct from three points.
Definition at line 286 of file triangleI.H. |
|
Construct from Istream.
Definition at line 299 of file triangleI.H. |
|
Return first vertex.
Definition at line 317 of file triangleI.H. |
|
Return second vertex.
Definition at line 323 of file triangleI.H. |
|
Return third vertex.
Definition at line 329 of file triangleI.H. Referenced by triangle::circumCentre(). |
|
Return centre (centroid).
Definition at line 336 of file triangleI.H. References Foam::mag(), and triangle::normal(). |
Here is the call graph for this function:
|
Return circum-centre.
Definition at line 357 of file triangleI.H. References triangle::c(). |
Here is the call graph for this function:
|
Return circum-radius.
Definition at line 377 of file triangleI.H. |
|
Classify point in triangle plane w.r.t. triangle edges.
Definition at line 537 of file triangleI.H. References Foam::label, and Foam::vector. |
|
Return scalar magnitude.
Definition at line 343 of file triangleI.H. |
|
Return nearest point to p on triangle.
Definition at line 522 of file triangleI.H. |
|
Return vector normal.
Definition at line 350 of file triangleI.H. Referenced by triangle::centre(). |
|
Return quality: Ratio triangle and circum-circle area.
Definition at line 399 of file triangleI.H. |
|
Return point intersection with a ray. For a hit, the distance is signed. Positive number represents the point in front of triangle. In case of miss pointHit is set to nearest point on triangle and its distance to the distance between the original point and the plane intersection point Definition at line 426 of file triangleI.H. References Foam::vector. |
|
Return swept-volume.
Definition at line 413 of file triangleI.H. |
|
|
|
|