Classes | |
class | TC::Math::Checksum |
Class defining the interface for calculating checksums With the method Append data can be added to the checksum calculation. More... | |
class | TC::Math::Coord2D< T > |
Class for handling 2D values with implementation of all common operators needed. More... | |
class | TC::Math::Coord3D< T > |
Class for handling 3D values With implementation of all common coordinate or vector operators needed. More... | |
class | TC::Math::Coord4D< T > |
Class for handling 3D values With implementation of all common coordinate or vector operators needed. More... | |
Namespaces | |
namespace | TC::Math::Factory |
Factory for creating TC::Math objects. | |
Files | |
file | TCMathApi.h |
This file provides the definition of TCMATH_API. | |
file | TCMathChecksum.h |
This file provides the definition of TC::Math::Checksum. | |
file | TCMathCoord2D.h |
This file provides the definition of TC::Math::Coord2D. | |
file | TCMathCoord3D.h |
This file provides the definition of TC::Math::Coord3D. | |
file | TCMathCoord4D.h |
This file provides the definition of TC::Math::Coord4D. | |
file | TCMathCoordUtil.h |
This file provides the definition of Coordinate utilities in the namespace TC::Math. | |
file | TCMathFactory.h |
This file provides the definition of TC::Math::Factory. | |
file | TCMathUtil.h |
This file provides the definition of Math utilities in the namespace TC::Math. | |
Defines | |
#define | TCMATH_API TC_IMPORT_DLL |
define for exporting or importing classes and functions from the TC::Math dll | |
Typedefs | |
typedef SharedPtr< Checksum > | TC::Math::ChecksumPtr |
Shared pointer of an checksum object. | |
Functions | |
template<class T > | |
const Coord2D< T > | TC::Math::operator* (const Coord2D< T > &v, const T &vIn) |
template<class T > | |
const Coord2D< T > | TC::Math::operator* (const T &vIn, const Coord2D< T > &v) |
template<class T > | |
const T | TC::Math::operator* (const Coord2D< T > &a, const Coord2D< T > &b) |
template<class T > | |
const Coord2D< T > | TC::Math::operator/ (const Coord2D< T > &v, const T &vIn) |
template<class T > | |
const Coord2D< T > | TC::Math::operator/ (const T &vIn, const Coord2D< T > &v) |
template<class T > | |
const Coord2D< T > | TC::Math::operator+ (const Coord2D< T > &v, const Coord2D< T > &b) |
template<class T > | |
const Coord2D< T > | TC::Math::operator+ (const Coord2D< T > &v, const T &b) |
template<class T > | |
const Coord2D< T > | TC::Math::operator- (const Coord2D< T > &v, const Coord2D< T > &b) |
template<class T > | |
const Coord2D< T > | TC::Math::operator- (const Coord2D< T > &v, const T &b) |
template<class T > | |
const Coord2D< T > | TC::Math::operator- (const Coord2D< T > &v) |
template<class T > | |
bool | TC::Math::operator> (const Coord2D< T > &a, const Coord2D< T > &b) |
template<class T > | |
bool | TC::Math::operator< (const Coord2D< T > &a, const Coord2D< T > &b) |
template<class T > | |
bool | TC::Math::operator== (const Coord2D< T > &a, const Coord2D< T > &b) |
template<class T > | |
bool | TC::Math::operator!= (const Coord2D< T > &a, const Coord2D< T > &b) |
template<class T > | |
bool | TC::Math::operator>= (const Coord2D< T > &a, const Coord2D< T > &b) |
template<class T > | |
bool | TC::Math::operator<= (const Coord2D< T > &a, const Coord2D< T > &b) |
template<class T > | |
StreamPtr | TC::Math::operator>> (StreamPtr stream, Coord2D< T > &coord) |
read operator for reading the data from a Stream | |
template<class T > | |
StreamPtr | TC::Math::operator<< (StreamPtr stream, const Coord2D< T > &coord) |
write operator for writing the data to a Stream | |
template<class T > | |
const Coord3D< T > | TC::Math::operator^ (const Coord3D< T > &a, const Coord3D< T > &b) |
template<class T > | |
const T | TC::Math::operator* (const Coord3D< T > &a, const Coord3D< T > &b) |
template<class T > | |
const Coord3D< T > | TC::Math::operator* (const Coord3D< T > &v, const T &vIn) |
template<class T > | |
const Coord3D< T > | TC::Math::operator* (const T &vIn, const Coord3D< T > &v) |
template<class T > | |
const Coord3D< T > | TC::Math::operator/ (const Coord3D< T > &v, const T &vIn) |
template<class T > | |
const Coord3D< T > | TC::Math::operator/ (const T &vIn, const Coord3D< T > &v) |
template<class T > | |
const Coord3D< T > | TC::Math::operator/ (const Coord3D< T > &in, const Coord3D< T > &in2) |
template<class T > | |
const Coord3D< T > | TC::Math::operator+ (const Coord3D< T > &v, const Coord3D< T > &b) |
template<class T > | |
const Coord3D< T > | TC::Math::operator+ (const Coord3D< T > &v, const T &b) |
template<class T > | |
const Coord3D< T > | TC::Math::operator- (const Coord3D< T > &v, const Coord3D< T > &b) |
template<class T > | |
const Coord3D< T > | TC::Math::operator- (const Coord3D< T > &v, const T &b) |
template<class T > | |
const Coord3D< T > | TC::Math::operator- (const Coord3D< T > &v) |
template<class T > | |
bool | TC::Math::operator> (const Coord3D< T > &a, const Coord3D< T > &b) |
template<class T > | |
bool | TC::Math::operator< (const Coord3D< T > &a, const Coord3D< T > &b) |
template<class T > | |
bool | TC::Math::operator== (const Coord3D< T > &a, const Coord3D< T > &b) |
template<class T > | |
bool | TC::Math::operator!= (const Coord3D< T > &a, const Coord3D< T > &b) |
template<class T > | |
bool | TC::Math::operator>= (const Coord3D< T > &a, const Coord3D< T > &b) |
template<class T > | |
bool | TC::Math::operator<= (const Coord3D< T > &a, const Coord3D< T > &b) |
template<class T > | |
StreamPtr | TC::Math::operator>> (StreamPtr stream, Coord3D< T > &coord) |
Read operator for reading the data from a TCStream. | |
template<class T > | |
StreamPtr | TC::Math::operator<< (StreamPtr stream, const Coord3D< T > &coord) |
Write operator for writing the data to a TCStream. | |
template<class T > | |
Coord4D< T > | TC::Math::operator* (const Coord4D< T > &v, const T &vIn) |
template<class T > | |
Coord4D< T > | TC::Math::operator* (const T &vIn, const Coord4D< T > &v) |
template<class T > | |
Coord4D< T > | TC::Math::operator/ (const Coord4D< T > &v, const T &vIn) |
template<class T > | |
Coord4D< T > | TC::Math::operator/ (const T &vIn, const Coord4D< T > &v) |
template<class T > | |
Coord4D< T > | TC::Math::operator+ (const Coord4D< T > &v, const Coord4D< T > &b) |
template<class T > | |
Coord4D< T > | TC::Math::operator- (const Coord4D< T > &v, const Coord4D< T > &b) |
template<class T > | |
Coord4D< T > | TC::Math::operator- (const Coord4D< T > &v) |
template<class T > | |
bool | TC::Math::operator> (const Coord4D< T > &a, const Coord4D< T > &b) |
template<class T > | |
bool | TC::Math::operator< (const Coord4D< T > &a, const Coord4D< T > &b) |
template<class T > | |
bool | TC::Math::operator== (const Coord4D< T > &a, const Coord4D< T > &b) |
template<class T > | |
bool | TC::Math::operator!= (const Coord4D< T > &a, const Coord4D< T > &b) |
template<class T > | |
bool | TC::Math::operator>= (const Coord4D< T > &a, const Coord4D< T > &b) |
template<class T > | |
bool | TC::Math::operator<= (const Coord4D< T > &a, const Coord4D< T > &b) |
template<class T > | |
StreamPtr | TC::Math::operator>> (StreamPtr stream, Coord4D< T > &coord) |
Read operator for reading the data from a TCStream. | |
template<class T > | |
StreamPtr | TC::Math::operator<< (StreamPtr stream, const Coord4D< T > &coord) |
Write operator for writing the data to a TCStream. | |
template<class COORD_TYPE > | |
double | TC::Math::Distance (const COORD_TYPE &a, const COORD_TYPE &b) |
Computes the distance of two 3-coordinates. | |
template<class COORD_TYPE > | |
double | TC::Math::Distance2 (const COORD_TYPE &a, const COORD_TYPE &b) |
Computes the square distance of two 3-coordinates. | |
template<class COORD_TYPE > | |
COORD_TYPE::DataType | TC::Math::DotProduct (const COORD_TYPE &a, const COORD_TYPE &b) |
Computes the dot product of two 3-coordinates (float-precision version). | |
template<class COORD_TYPE > | |
COORD_TYPE::DataType | TC::Math::DotProduct2 (const COORD_TYPE &a, const COORD_TYPE &b) |
Computes the square dot product of two 3-coordinates. | |
template<class COORD_TYPE > | |
COORD_TYPE | TC::Math::Normalize (const COORD_TYPE &coord) |
Computes the the normalized vector of the coord and returns it. | |
template<class COORD_TYPE > | |
COORD_TYPE | TC::Math::CrossProduct (const COORD_TYPE &a, const COORD_TYPE &b) |
Computes the cross product of two 3-coordinates. | |
template<class T > | |
Coord3D< T > | TC::Math::Max (const Coord3D< T > &a, const Coord3D< T > &b) |
template<class T > | |
Coord2D< T > | TC::Math::Max (const Coord2D< T > &a, const Coord2D< T > &b) |
template<class T > | |
Coord3D< T > | TC::Math::Min (const Coord3D< T > &a, const Coord3D< T > &b) |
template<class T > | |
Coord2D< T > | TC::Math::Min (const Coord2D< T > &a, const Coord2D< T > &b) |
template<class T > | |
Coord3D< T > | TC::Math::Normalvector (sint32 numPoints, const Coord3D< T > *coords) |
Calculates the normal vector of the plane defined by the points. | |
template<class COORD_TYPE > | |
double | TC::Math::Angle (const COORD_TYPE &a, const COORD_TYPE &b) |
Computes the angle between two 3d vectors. | |
template<class T > | |
bool | TC::Math::IsPointInCircle (const Coord2D< T > &Point, const Coord2D< T > ¢er, double radius) |
template<class T > | |
bool | TC::Math::CheckInsidePolygon (const Coord2D< T > &point, sint32 num_points, const Coord2D< T > *polygon) |
template<class T > | |
T | TC::Math::Abs (const T &x) |
template<class T > | |
T | TC::Math::Pow (T x, uint32 y) |
integer version of pow(. | |
uint32 | TC::Math::Align32 (uint32 size) |
aligns a given number to 32 | |
bool | TC::Math::Compare (double val1, double val2) |
Compare two double values if equal by checking their difference. | |
uint32 | TC::Math::Align16 (uint32 size) |
aligns a given number to 16 | |
template<class T > | |
double | TC::Math::Deg2Rad (T val) |
Function converts angle in degrees to angle in radians. | |
template<class T > | |
double | TC::Math::Rad2Deg (T val) |
Function converts angle in radians to angle in degrees. | |
template<class T > | |
T | TC::Math::Normalize (T minValue, T maxValue, T value) |
Function converts a value in the range between minValue and maxValue to a value between 0 and one. | |
template<class T > | |
double | TC::Math::SinXOverX (T x) |
This function calculates sin(x)/x in a safe way, i.e. | |
template<class T > | |
T | TC::Math::RoundToFirstSignificantValue (T val) |
Round any kind of value to the first significant value. | |
template<class T > | |
bool | TC::Math::Compare (const T &val1, const T &val2) |
compare double or float value with its specified system epsilon | |
bool | TC::Math::IsNaN (double val) |
function returns a true value if value is "not-a-number" (NaN), and false otherwise. | |
bool | TC::Math::IsFinite (double val) |
bool | TC::Math::IsInf (double val) |
Variables | |
const double | TC::Math::PI = 3.1415926535897932385E0 |
The constant value of PI. | |
const double | TC::Math::MEGA_BYTES = 1024. * 1024. |
The constant value one Megabyte in bytes. |
#define TCMATH_API TC_IMPORT_DLL |
define for exporting or importing classes and functions from the TC::Math dll
Definition at line 59 of file TCMathApi.h.
typedef SharedPtr<Checksum> TC::Math::ChecksumPtr |
const Coord2D<T> TC::Math::operator* | ( | const Coord2D< T > & | v, | |
const T & | vIn | |||
) | [inline] |
Definition at line 172 of file TCMathCoord2D.h.
const Coord2D<T> TC::Math::operator* | ( | const T & | vIn, | |
const Coord2D< T > & | v | |||
) | [inline] |
Definition at line 178 of file TCMathCoord2D.h.
const T TC::Math::operator* | ( | const Coord2D< T > & | a, | |
const Coord2D< T > & | b | |||
) | [inline] |
Definition at line 184 of file TCMathCoord2D.h.
const Coord2D<T> TC::Math::operator/ | ( | const Coord2D< T > & | v, | |
const T & | vIn | |||
) | [inline] |
Definition at line 190 of file TCMathCoord2D.h.
const Coord2D<T> TC::Math::operator/ | ( | const T & | vIn, | |
const Coord2D< T > & | v | |||
) | [inline] |
Definition at line 196 of file TCMathCoord2D.h.
const Coord2D<T> TC::Math::operator+ | ( | const Coord2D< T > & | v, | |
const Coord2D< T > & | b | |||
) | [inline] |
Definition at line 202 of file TCMathCoord2D.h.
const Coord2D<T> TC::Math::operator+ | ( | const Coord2D< T > & | v, | |
const T & | b | |||
) | [inline] |
Definition at line 208 of file TCMathCoord2D.h.
const Coord2D<T> TC::Math::operator- | ( | const Coord2D< T > & | v, | |
const Coord2D< T > & | b | |||
) | [inline] |
Definition at line 214 of file TCMathCoord2D.h.
const Coord2D<T> TC::Math::operator- | ( | const Coord2D< T > & | v, | |
const T & | b | |||
) | [inline] |
Definition at line 220 of file TCMathCoord2D.h.
const Coord2D<T> TC::Math::operator- | ( | const Coord2D< T > & | v | ) | [inline] |
Definition at line 226 of file TCMathCoord2D.h.
bool TC::Math::operator> | ( | const Coord2D< T > & | a, | |
const Coord2D< T > & | b | |||
) | [inline] |
Definition at line 235 of file TCMathCoord2D.h.
bool TC::Math::operator< | ( | const Coord2D< T > & | a, | |
const Coord2D< T > & | b | |||
) | [inline] |
Definition at line 245 of file TCMathCoord2D.h.
bool TC::Math::operator== | ( | const Coord2D< T > & | a, | |
const Coord2D< T > & | b | |||
) | [inline] |
Definition at line 255 of file TCMathCoord2D.h.
bool TC::Math::operator!= | ( | const Coord2D< T > & | a, | |
const Coord2D< T > & | b | |||
) | [inline] |
Definition at line 261 of file TCMathCoord2D.h.
bool TC::Math::operator>= | ( | const Coord2D< T > & | a, | |
const Coord2D< T > & | b | |||
) | [inline] |
Definition at line 267 of file TCMathCoord2D.h.
bool TC::Math::operator<= | ( | const Coord2D< T > & | a, | |
const Coord2D< T > & | b | |||
) | [inline] |
Definition at line 273 of file TCMathCoord2D.h.
StreamPtr TC::Math::operator>> | ( | StreamPtr | stream, | |
Coord2D< T > & | coord | |||
) | [inline] |
read operator for reading the data from a Stream
stream | stream where to read the data from | |
coord | The coordinate to read from the stream |
Definition at line 285 of file TCMathCoord2D.h.
StreamPtr TC::Math::operator<< | ( | StreamPtr | stream, | |
const Coord2D< T > & | coord | |||
) | [inline] |
write operator for writing the data to a Stream
stream | stream where to write the data to | |
coord | The coordinate to write to the stream |
Definition at line 296 of file TCMathCoord2D.h.
References TC::space().
const Coord3D<T> TC::Math::operator^ | ( | const Coord3D< T > & | a, | |
const Coord3D< T > & | b | |||
) | [inline] |
Definition at line 186 of file TCMathCoord3D.h.
const T TC::Math::operator* | ( | const Coord3D< T > & | a, | |
const Coord3D< T > & | b | |||
) | [inline] |
Definition at line 194 of file TCMathCoord3D.h.
const Coord3D<T> TC::Math::operator* | ( | const Coord3D< T > & | v, | |
const T & | vIn | |||
) | [inline] |
Definition at line 200 of file TCMathCoord3D.h.
const Coord3D<T> TC::Math::operator* | ( | const T & | vIn, | |
const Coord3D< T > & | v | |||
) | [inline] |
Definition at line 206 of file TCMathCoord3D.h.
const Coord3D<T> TC::Math::operator/ | ( | const Coord3D< T > & | v, | |
const T & | vIn | |||
) | [inline] |
Definition at line 212 of file TCMathCoord3D.h.
const Coord3D<T> TC::Math::operator/ | ( | const T & | vIn, | |
const Coord3D< T > & | v | |||
) | [inline] |
Definition at line 218 of file TCMathCoord3D.h.
const Coord3D<T> TC::Math::operator/ | ( | const Coord3D< T > & | in, | |
const Coord3D< T > & | in2 | |||
) | [inline] |
Definition at line 224 of file TCMathCoord3D.h.
const Coord3D<T> TC::Math::operator+ | ( | const Coord3D< T > & | v, | |
const Coord3D< T > & | b | |||
) | [inline] |
Definition at line 232 of file TCMathCoord3D.h.
const Coord3D<T> TC::Math::operator+ | ( | const Coord3D< T > & | v, | |
const T & | b | |||
) | [inline] |
Definition at line 238 of file TCMathCoord3D.h.
const Coord3D<T> TC::Math::operator- | ( | const Coord3D< T > & | v, | |
const Coord3D< T > & | b | |||
) | [inline] |
Definition at line 244 of file TCMathCoord3D.h.
const Coord3D<T> TC::Math::operator- | ( | const Coord3D< T > & | v, | |
const T & | b | |||
) | [inline] |
Definition at line 255 of file TCMathCoord3D.h.
const Coord3D<T> TC::Math::operator- | ( | const Coord3D< T > & | v | ) | [inline] |
Definition at line 261 of file TCMathCoord3D.h.
bool TC::Math::operator> | ( | const Coord3D< T > & | a, | |
const Coord3D< T > & | b | |||
) | [inline] |
Definition at line 271 of file TCMathCoord3D.h.
bool TC::Math::operator< | ( | const Coord3D< T > & | a, | |
const Coord3D< T > & | b | |||
) | [inline] |
Definition at line 283 of file TCMathCoord3D.h.
bool TC::Math::operator== | ( | const Coord3D< T > & | a, | |
const Coord3D< T > & | b | |||
) | [inline] |
Definition at line 295 of file TCMathCoord3D.h.
bool TC::Math::operator!= | ( | const Coord3D< T > & | a, | |
const Coord3D< T > & | b | |||
) | [inline] |
Definition at line 301 of file TCMathCoord3D.h.
bool TC::Math::operator>= | ( | const Coord3D< T > & | a, | |
const Coord3D< T > & | b | |||
) | [inline] |
Definition at line 307 of file TCMathCoord3D.h.
bool TC::Math::operator<= | ( | const Coord3D< T > & | a, | |
const Coord3D< T > & | b | |||
) | [inline] |
Definition at line 313 of file TCMathCoord3D.h.
StreamPtr TC::Math::operator>> | ( | StreamPtr | stream, | |
Coord3D< T > & | coord | |||
) | [inline] |
Read operator for reading the data from a TCStream.
stream | stream where to read the data from | |
coord | The coordinate to read from the stream |
Definition at line 326 of file TCMathCoord3D.h.
StreamPtr TC::Math::operator<< | ( | StreamPtr | stream, | |
const Coord3D< T > & | coord | |||
) | [inline] |
Write operator for writing the data to a TCStream.
stream | stream where to write the data to | |
coord | The coordinate to write on the stream |
Definition at line 338 of file TCMathCoord3D.h.
References TC::space().
Coord4D<T> TC::Math::operator* | ( | const Coord4D< T > & | v, | |
const T & | vIn | |||
) | [inline] |
Definition at line 207 of file TCMathCoord4D.h.
Coord4D<T> TC::Math::operator* | ( | const T & | vIn, | |
const Coord4D< T > & | v | |||
) | [inline] |
Definition at line 213 of file TCMathCoord4D.h.
Coord4D<T> TC::Math::operator/ | ( | const Coord4D< T > & | v, | |
const T & | vIn | |||
) | [inline] |
Definition at line 219 of file TCMathCoord4D.h.
Coord4D<T> TC::Math::operator/ | ( | const T & | vIn, | |
const Coord4D< T > & | v | |||
) | [inline] |
Definition at line 225 of file TCMathCoord4D.h.
Coord4D<T> TC::Math::operator+ | ( | const Coord4D< T > & | v, | |
const Coord4D< T > & | b | |||
) | [inline] |
Definition at line 231 of file TCMathCoord4D.h.
Coord4D<T> TC::Math::operator- | ( | const Coord4D< T > & | v, | |
const Coord4D< T > & | b | |||
) | [inline] |
Definition at line 237 of file TCMathCoord4D.h.
Coord4D<T> TC::Math::operator- | ( | const Coord4D< T > & | v | ) | [inline] |
Definition at line 243 of file TCMathCoord4D.h.
bool TC::Math::operator> | ( | const Coord4D< T > & | a, | |
const Coord4D< T > & | b | |||
) | [inline] |
Definition at line 253 of file TCMathCoord4D.h.
bool TC::Math::operator< | ( | const Coord4D< T > & | a, | |
const Coord4D< T > & | b | |||
) | [inline] |
Definition at line 267 of file TCMathCoord4D.h.
bool TC::Math::operator== | ( | const Coord4D< T > & | a, | |
const Coord4D< T > & | b | |||
) | [inline] |
Definition at line 281 of file TCMathCoord4D.h.
bool TC::Math::operator!= | ( | const Coord4D< T > & | a, | |
const Coord4D< T > & | b | |||
) | [inline] |
Definition at line 287 of file TCMathCoord4D.h.
bool TC::Math::operator>= | ( | const Coord4D< T > & | a, | |
const Coord4D< T > & | b | |||
) | [inline] |
Definition at line 293 of file TCMathCoord4D.h.
bool TC::Math::operator<= | ( | const Coord4D< T > & | a, | |
const Coord4D< T > & | b | |||
) | [inline] |
Definition at line 299 of file TCMathCoord4D.h.
StreamPtr TC::Math::operator>> | ( | StreamPtr | stream, | |
Coord4D< T > & | coord | |||
) | [inline] |
Read operator for reading the data from a TCStream.
stream | stream where to read the data from | |
coord | The coordinate to read from the stream |
Definition at line 312 of file TCMathCoord4D.h.
StreamPtr TC::Math::operator<< | ( | StreamPtr | stream, | |
const Coord4D< T > & | coord | |||
) | [inline] |
Write operator for writing the data to a TCStream.
stream | stream where to write the data to | |
coord | The coordinate to write on the stream |
Definition at line 324 of file TCMathCoord4D.h.
References TC::space().
double TC::Math::Distance | ( | const COORD_TYPE & | a, | |
const COORD_TYPE & | b | |||
) | [inline] |
Computes the distance of two 3-coordinates.
a | the 1st 3D coordinate | |
b | the 2nd 3D coordinate |
Definition at line 64 of file TCMathCoordUtil.h.
Referenced by TC::Math::Box< COORD_TYPE >::GetDiameter().
double TC::Math::Distance2 | ( | const COORD_TYPE & | a, | |
const COORD_TYPE & | b | |||
) | [inline] |
Computes the square distance of two 3-coordinates.
a | the 1st 3D coordinate | |
b | the 2nd 3D coordinate |
Definition at line 77 of file TCMathCoordUtil.h.
COORD_TYPE::DataType TC::Math::DotProduct | ( | const COORD_TYPE & | a, | |
const COORD_TYPE & | b | |||
) | [inline] |
Computes the dot product of two 3-coordinates (float-precision version).
a | the 1st 3D coordinate | |
b | the 2nd 3D coordinate |
Definition at line 90 of file TCMathCoordUtil.h.
Referenced by TC::Math::Angle().
COORD_TYPE::DataType TC::Math::DotProduct2 | ( | const COORD_TYPE & | a, | |
const COORD_TYPE & | b | |||
) | [inline] |
Computes the square dot product of two 3-coordinates.
a | the 1st 3D coordinate | |
b | the 2nd 3D coordinate |
Definition at line 102 of file TCMathCoordUtil.h.
COORD_TYPE TC::Math::Normalize | ( | const COORD_TYPE & | coord | ) | [inline] |
Computes the the normalized vector of the coord and returns it.
The cross product of a and b, written a x b, is defined by:
coord | The coord for which to get the normalized one |
Definition at line 115 of file TCMathCoordUtil.h.
COORD_TYPE TC::Math::CrossProduct | ( | const COORD_TYPE & | a, | |
const COORD_TYPE & | b | |||
) | [inline] |
Computes the cross product of two 3-coordinates.
The cross product of a and b, written a x b, is defined by:
a | the 1st vector | |
b | the 2nd vector |
Definition at line 130 of file TCMathCoordUtil.h.
Coord3D<T> TC::Math::Max | ( | const Coord3D< T > & | a, | |
const Coord3D< T > & | b | |||
) | [inline] |
Definition at line 136 of file TCMathCoordUtil.h.
Referenced by TC::Math::Box< COORD_TYPE >::BoundingBox(), TC::Math::Box< COORD_TYPE >::GetLongest(), TC::Math::Max(), TC::Math::Coord3D< T >::MaxValue(), TC::Math::Coord2D< T >::MaxValue(), TC::Math::Normalize(), and TC::Math::Box< COORD_TYPE >::Unite().
Coord2D<T> TC::Math::Max | ( | const Coord2D< T > & | a, | |
const Coord2D< T > & | b | |||
) | [inline] |
Definition at line 147 of file TCMathCoordUtil.h.
References TC::Math::Max().
Coord3D<T> TC::Math::Min | ( | const Coord3D< T > & | a, | |
const Coord3D< T > & | b | |||
) | [inline] |
Definition at line 157 of file TCMathCoordUtil.h.
Referenced by TC::Math::Box< COORD_TYPE >::BoundingBox(), TC::Math::Box< COORD_TYPE >::GetShortest(), TC::Math::Min(), TC::Math::Normalize(), and TC::Math::Box< COORD_TYPE >::Unite().
Coord2D<T> TC::Math::Min | ( | const Coord2D< T > & | a, | |
const Coord2D< T > & | b | |||
) | [inline] |
Definition at line 168 of file TCMathCoordUtil.h.
References TC::Math::Min().
Coord3D<T> TC::Math::Normalvector | ( | sint32 | numPoints, | |
const Coord3D< T > * | coords | |||
) | [inline] |
Calculates the normal vector of the plane defined by the points.
numPoints | Number of points defining the plane | |
coords | The coordinates of the points defining the plane |
Definition at line 184 of file TCMathCoordUtil.h.
double TC::Math::Angle | ( | const COORD_TYPE & | a, | |
const COORD_TYPE & | b | |||
) | [inline] |
Computes the angle between two 3d vectors.
a | the 1st 3D vector | |
b | the 2nd 3D vector |
Definition at line 205 of file TCMathCoordUtil.h.
References TC::Math::DotProduct(), and TC::Math::PI.
bool TC::Math::IsPointInCircle | ( | const Coord2D< T > & | Point, | |
const Coord2D< T > & | center, | |||
double | radius | |||
) | [inline] |
Definition at line 224 of file TCMathCoordUtil.h.
bool TC::Math::CheckInsidePolygon | ( | const Coord2D< T > & | point, | |
sint32 | num_points, | |||
const Coord2D< T > * | polygon | |||
) | [inline] |
Definition at line 235 of file TCMathCoordUtil.h.
T TC::Math::Abs | ( | const T & | x | ) | [inline] |
Definition at line 77 of file TCMathUtil.h.
Referenced by TC::Math::Compare(), and TC::Math::RoundToFirstSignificantValue().
T TC::Math::Pow | ( | T | x, | |
uint32 | y | |||
) | [inline] |
uint32 TC::Math::Align32 | ( | uint32 | size | ) | [inline] |
aligns a given number to 32
size | - value that should be aligned |
Definition at line 104 of file TCMathUtil.h.
bool TC::Math::Compare | ( | double | val1, | |
double | val2 | |||
) | [inline] |
Compare two double values if equal by checking their difference.
Definition at line 110 of file TCMathUtil.h.
References TC::Math::Abs().
uint32 TC::Math::Align16 | ( | uint32 | size | ) | [inline] |
aligns a given number to 16
size | - value that should be aligned |
Definition at line 120 of file TCMathUtil.h.
double TC::Math::Deg2Rad | ( | T | val | ) | [inline] |
Function converts angle in degrees to angle in radians.
val | angle value in degrees |
Definition at line 131 of file TCMathUtil.h.
References TC::Math::PI.
double TC::Math::Rad2Deg | ( | T | val | ) | [inline] |
Function converts angle in radians to angle in degrees.
val | angle value in radians |
Definition at line 142 of file TCMathUtil.h.
References TC::Math::PI.
T TC::Math::Normalize | ( | T | minValue, | |
T | maxValue, | |||
T | value | |||
) | [inline] |
Function converts a value in the range between minValue and maxValue to a value between 0 and one.
minValue | The value defines the minuimum when the value is 0 | |
maxValue | The value defines the maximum when the value is 1 | |
value | The value which should be converted to a value between 0 and one |
Definition at line 156 of file TCMathUtil.h.
References TC::Math::Max(), TC::Math::Min(), and TC::Util::Swap().
double TC::Math::SinXOverX | ( | T | x | ) | [inline] |
This function calculates sin(x)/x in a safe way, i.e.
without overflows near 0.
x | Trivial. |
Definition at line 183 of file TCMathUtil.h.
T TC::Math::RoundToFirstSignificantValue | ( | T | val | ) | [inline] |
Round any kind of value to the first significant value.
e.g. 53465 > 50000 0.0875 > 0.08 -234 > -200
val | The value which to round |
Definition at line 202 of file TCMathUtil.h.
References TC::Math::Abs().
bool TC::Math::Compare | ( | const T & | val1, | |
const T & | val2 | |||
) | [inline] |
compare double or float value with its specified system epsilon
Definition at line 226 of file TCMathUtil.h.
References TC::Math::Abs().
bool TC::Math::IsNaN | ( | double | val | ) |
function returns a true value if value is "not-a-number" (NaN), and false otherwise.
bool TC::Math::IsFinite | ( | double | val | ) |
bool TC::Math::IsInf | ( | double | val | ) |
const double TC::Math::PI = 3.1415926535897932385E0 |
The constant value of PI.
Definition at line 71 of file TCMathUtil.h.
Referenced by TC::Math::Angle(), TC::Math::Deg2Rad(), and TC::Math::Rad2Deg().
const double TC::Math::MEGA_BYTES = 1024. * 1024. |