FMath Namespace Reference
[Mathematics Classes.]

A namespace for common math functions. More...


Functions

double RadToDeg (double val)
 Convert radians to degrees.
float RadToDeg (float val)
 Convert radians to degrees.
double DegToRad (double val)
 Convert degrees to radians.
float DegToRad (float val)
 Convert degrees to radians.
int IsNotANumber (float f)
 Determines if given float is encoding for not a number (NAN).
double Sign (double val)
 Determine the sign of a number.
float Sign (float val)
 Determine the sign of a number.
int32 Sign (int32 val)
 Determine the sign of a number.
template<class T>
Clamp (T val, T mn, T mx)
 Clamp the specified object within a range specified by two other objects of the same class.

Variables

const double Pi = 3.14159
 Mathematical value of pi to 5 decimals.


Detailed Description

A namespace for common math functions.

Function Documentation

template<class T>
T FMath::Clamp val,
mn,
mx
[inline]
 

Clamp the specified object within a range specified by two other objects of the same class.

Clamp refers to setting a value within a given range. If the value is lower than the minimum of the range, it is set to the minimum; same for the maximum.

Parameters:
val The object to clamp.
mx The highest object of the range.
mn The lowest object of the range.
Returns:
The clamped value.

float FMath::DegToRad float  val  )  [inline]
 

Convert degrees to radians.

Parameters:
val The value in degrees.
Returns:
The value in radians.

double FMath::DegToRad double  val  )  [inline]
 

Convert degrees to radians.

Parameters:
val The value in degrees.
Returns:
The value in radians.

int FMath::IsNotANumber float  f  )  [inline]
 

Determines if given float is encoding for not a number (NAN).

Parameters:
f The float to check.
Returns:
0 if it is a number, something else if is NAN.

float FMath::RadToDeg float  val  )  [inline]
 

Convert radians to degrees.

Parameters:
val The value in radians.
Returns:
The value in degrees.

double FMath::RadToDeg double  val  )  [inline]
 

Convert radians to degrees.

Parameters:
val The value in radians.
Returns:
The value in degrees.

int32 FMath::Sign int32  val  )  [inline]
 

Determine the sign of a number.

Parameters:
val The number to check.
Returns:
1 if positive, -1 if negative.

float FMath::Sign float  val  )  [inline]
 

Determine the sign of a number.

Parameters:
val The number to check.
Returns:
1.0f if positive, -1.0f if negative.

double FMath::Sign double  val  )  [inline]
 

Determine the sign of a number.

Parameters:
val The number to check.
Returns:
1.0 if positive, -1.0 if negative.


Generated on Fri May 12 16:44:44 2006 for FCollada by  doxygen 1.4.6-NO