|
|
|
triangle< Point, PointRef > Class Template ReferenceA triangle primitive used to calculate face normals and swept volumes. More...
Detailed Descriptiontemplate<class Point, class PointRef>
A triangle primitive used to calculate face normals and swept volumes.
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| enum proxType |
| triangle | ( | const Point & | a, | |
| const Point & | b, | |||
| const Point & | c | |||
| ) | [inline] |
| const Point & a | ( | ) | const [inline] |
| const Point & b | ( | ) | const [inline] |
| const Point & c | ( | ) | const [inline] |
| Point centre | ( | ) | const [inline] |
| scalar mag | ( | ) | const [inline] |
Return scalar magnitude.
Definition at line 240 of file triangleI.H.
Referenced by triangle< Point, PointRef >::normal().

Definition at line 247 of file triangleI.H.
References triangle< Point, PointRef >::mag().

| vector circumCentre | ( | ) | const [inline] |
| scalar circumRadius | ( | ) | const [inline] |
| scalar quality | ( | ) | const [inline] |
Return quality: Ratio triangle and circum-circle area.
Definition at line 296 of file triangleI.H.
References Foam::max(), Foam::min(), and Foam::sqrt().

| pointHit ray | ( | const point & | p, | |
| const vector & | q, | |||
| const intersection::algorithm | alg = intersection::FULL_RAY, |
|||
| const intersection::direction | dir = intersection::VECTOR | |||
| ) | const [inline] |
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 327 of file triangleI.H.
| pointHit intersection | ( | const point & | p, | |
| const vector & | q, | |||
| const intersection::algorithm | alg, | |||
| const scalar | tol = 0.0 | |||
| ) | const [inline] |
Fast intersection with a ray.
For a hit, the pointHit.distance() is the line parameter t : intersection=p+t*q. Only defined for VISIBLE, FULL_RAY or HALF_RAY. tol increases the virtual size of the triangle by a relative factor.
Definition at line 443 of file triangleI.H.
| bool classify | ( | const point & | p, | |
| const scalar | tol, | |||
| label & | nearType, | |||
| label & | nearLabel | |||
| ) | const [inline] |
Classify point in triangle plane w.r.t. triangle edges.
Definition at line 541 of file triangleI.H.