|
World of Rigid Bodies (WoRB)
|
Physical and mathematical constants. More...
#include <Constants.h>

Static Public Member Functions | |
| static bool | IsNaN (double x) |
| Returns true if the argument is NaN. | |
| static int | IsInf (double x) |
| Returns +1/-1 if the argument is positive/negative infinity. | |
Static Public Attributes | |
| static const Quaternion | X |
| Represents X-axis unit vector. | |
| static const Quaternion | Y |
| Represents Y-axis unit vector. | |
| static const Quaternion | Z |
| Represents Z-axis unit vector. | |
| static const Quaternion | g_n |
| Gets standard gravity (standard acceleration due to free fall in kg m/s^2). | |
| static const double | Pi = 4 * std::atan(1.0) |
| Represents Pi. | |
| static const double | Max = std::numeric_limits<double>::max () |
| Represents the maximum finite value for a double floating-point number. | |
| static const double | Min = std::numeric_limits<double>::min () |
| Represents the minimum finite value for a double floating-point number. | |
| static const double | Eps = std::numeric_limits<double>::epsilon () |
Gets the smallest positive x such that x + Eps + x is representable. | |
| static const double | Inf = std::numeric_limits<double>::infinity () |
| Returns the representation of positive infinity. | |
| static const double | NaN = std::numeric_limits<double>::quiet_NaN () |
| Returns the representation of a quiet not a number (NaN). | |
Physical and mathematical constants.
Definition at line 23 of file Constants.h.
| static int WoRB::Const::IsInf | ( | double | x | ) | [inline, static] |
Returns +1/-1 if the argument is positive/negative infinity.
Definition at line 85 of file Constants.h.
{
double delta = x - x;
if ( x == x && delta != 0.0 ) {
return x < 0.0 ? -1 : 1;
}
return 0;
}
| static bool WoRB::Const::IsNaN | ( | double | x | ) | [inline, static] |
const double Const::Eps = std::numeric_limits<double>::epsilon () [static] |
Gets the smallest positive x such that x + Eps + x is representable.
Definition at line 66 of file Constants.h.
const Quaternion Const::g_n [static] |
Gets standard gravity (standard acceleration due to free fall in kg m/s^2).
Definition at line 46 of file Constants.h.
Referenced by WoRB_TestBed::ReconfigureTestBed().
const double Const::Inf = std::numeric_limits<double>::infinity () [static] |
Returns the representation of positive infinity.
Definition at line 70 of file Constants.h.
const double Const::Max = std::numeric_limits<double>::max () [static] |
Represents the maximum finite value for a double floating-point number.
Definition at line 58 of file Constants.h.
Referenced by WoRB::Cuboid::Check().
const double Const::Min = std::numeric_limits<double>::min () [static] |
Represents the minimum finite value for a double floating-point number.
Definition at line 62 of file Constants.h.
const double Const::NaN = std::numeric_limits<double>::quiet_NaN () [static] |
Returns the representation of a quiet not a number (NaN).
Definition at line 74 of file Constants.h.
const double Const::Pi = 4 * std::atan(1.0) [static] |
Represents Pi.
Definition at line 52 of file Constants.h.
Referenced by WoRB_TestBed::MotionEventHandler(), WoRB_TestBed::ReconfigureTestBed(), and WoRB::Sphere::Volume().
const Quaternion Const::X [static] |
Represents X-axis unit vector.
Definition at line 31 of file Constants.h.
Referenced by WoRB_TestBed::ClearTestBed(), and WoRB_TestBed::ReconfigureTestBed().
const Quaternion Const::Y [static] |
Represents Y-axis unit vector.
Definition at line 35 of file Constants.h.
Referenced by WoRB_TestBed::ClearTestBed().
const Quaternion Const::Z [static] |
Represents Z-axis unit vector.
Definition at line 39 of file Constants.h.
Referenced by WoRB_TestBed::ClearTestBed().