Overture
Version 25
|
#include <TriangleClass.h>
Public Member Functions | |
Triangle () | |
Triangle (const real x1[3], const real x2[3], const real x3[3]) | |
Triangle (const RealArray &x1, const RealArray &x2, const RealArray &x3) | |
Triangle (const realArray &grid, const int &i1, const int &i2, const int &i3, const int &choice=0, const int &axis=axis3) | |
~Triangle () | |
real | area () const |
void | setVertices (const real x1_[3], const real x2_[3], const real x3_[3]) |
void | setVertices (const RealArray &x1, const RealArray &x2, const RealArray &x3) |
void | setVertices (const realArray &grid, const int &i1, const int &i2, const int &i3, const int &choice=0, const int &axis=axis3) |
bool | intersects (Triangle &triangle, real xi1[3], real xi2[3]) const |
bool | intersects (Triangle &triangle, RealArray &xi1, RealArray &xi2) const |
bool | intersects (real x[3], real xi[3]) const |
bool | intersects (RealArray &x, RealArray &xi) const |
bool | intersects (real x[3], real xi[3], real b0[3], real b1[3], real b2[3]) const |
bool | intersects (RealArray &x, RealArray &xi, real b0[3], real b1[3], real b2[3]) const |
int | getRelativeCoordinates (const real x[3], real &alpha1, real &alpha2, const bool &shouldBeInside=TRUE) const |
void | display (const aString &label=blankString) const |
double | tetrahedralVolume (const real a[], const real b[], const real c[], const real d[]) const |
void | computeNormal () |
Public Attributes | |
real | x1 [3] |
real | x2 [3] |
real | x3 [3] |
real | normal [4] |
Triangle::Triangle | ( | ) |
References computeNormal(), x1, x2, and x3.
References setVertices(), x1, x2, and x3.
References setVertices().
Triangle::Triangle | ( | const realArray & | grid, |
const int & | i1, | ||
const int & | i2, | ||
const int & | i3, | ||
const int & | choice = 0 , |
||
const int & | axis = axis3 |
||
) |
References setVertices().
Triangle::~Triangle | ( | ) |
void Triangle::computeNormal | ( | ) |
References normal, SQR, SQRT, x1, x2, and x3.
Referenced by setVertices(), and Triangle().
void Triangle::display | ( | const aString & | label = blankString | ) | const |
References normal.
Referenced by ApproximateGlobalInverse::countCrossingsWithPolygon(), UnstructuredMapping::insideOrOutside(), and intersects().
int Triangle::getRelativeCoordinates | ( | const real | x[3], |
real & | alpha1, | ||
real & | alpha2, | ||
const bool & | shouldBeInside = TRUE |
||
) | const |
References fabs(), REAL_EPSILON, SQR, and x.
Referenced by ApproximateGlobalInverse::countCrossingsWithPolygon(), IntersectionMapping::determineIntersection(), and UnstructuredMapping::insideOrOutside().
References Mapping::debug, display(), fabs(), FALSE, intersect3D(), max(), min(), normal, REAL_EPSILON, sign(), TRUE, x1, x2, and x3.
Referenced by ApproximateGlobalInverse::countCrossingsWithPolygon(), IntersectionMapping::determineIntersection(), and UnstructuredMapping::insideOrOutside().
References Mapping::debug, display(), fabs(), FALSE, max(), min(), normal, REAL_EPSILON, sign(), TETRAHEDRALVOLUME, and x.
bool Triangle::intersects | ( | RealArray & | x, |
RealArray & | xi, | ||
real | b0[3], | ||
real | b1[3], | ||
real | b2[3] | ||
) | const |
References x.
References computeNormal(), x1, x2, and x3.
Referenced by ApproximateGlobalInverse::countCrossingsWithPolygon(), UnstructuredMapping::insideOrOutside(), setVertices(), and Triangle().
References setVertices().
double Triangle::tetrahedralVolume | ( | const real | a[], |
const real | b[], | ||
const real | c[], | ||
const real | d[] | ||
) | const |
References c.
real Triangle::normal[4] |
Referenced by computeNormal(), and intersects().
real Triangle::x1[3] |
real Triangle::x2[3] |
real Triangle::x3[3] |