#include <OpenGUI_Math.h>
This math lib exists so that the function they represent can be replaced with high speed alternatives or hardware acceleration where appropriate.
Static Public Member Functions | |
| static float | DegreesToRadians (float degrees) |
| converts degrees into radians | |
| static float | RadiansToDegrees (float radians) |
| converts radians into degrees | |
| static float | Sin (float fValue) |
| sine | |
| static float | Cos (float fValue) |
| cosine | |
| static float | Tan (float fValue) |
| tangent | |
| static float | ASin (float fValue) |
| arc sine | |
| static float | ACos (float fValue) |
| arc cosine | |
| static float | ATan (float fValue) |
| arc tangent | |
| static float | ATan2 (float fY, float fX) |
| arc tangent of y/x | |
| static float | Ceil (float fValue) |
| ceiling | |
| static float | Floor (float fValue) |
| floor | |
| static float | Exp (float fValue) |
| exponential | |
| static float | FAbs (float fValue) |
| absolute value of floating-point | |
| static float | FMod (float fX, float fY) |
| floating point modular division | |
| static float | Log (float fValue) |
| natural logarithm | |
| static float | Pow (float fBase, float fExponent) |
| numeric power | |
| static float | Sqr (float fValue) |
| square | |
| static float | Sqrt (float fValue) |
| square root | |
| static float | InvSqrt (float fValue) |
| inverse square root | |
| static float | AngleOfPoint (float x, float y) |
| Returns the angle from the origin to the given point, in float radians. | |
Static Public Attributes | |
| static const float | PI = float( 4.0 * atan( 1.0 ) ) |
| value for Pi | |
| static const float | TWO_PI = float( 2.0 * Math::PI ) |
| value for 2 * Pi | |
| static const float | HALF_PI = float( 0.5 * Math::PI ) |
| value for Pi / 2 | |
| static float OpenGUI::Math::ACos | ( | float | fValue | ) | [inline, static] |
arc cosine
| static float OpenGUI::Math::AngleOfPoint | ( | float | x, | |
| float | y | |||
| ) | [inline, static] |
Returns the angle from the origin to the given point, in float radians.
| static float OpenGUI::Math::ASin | ( | float | fValue | ) | [inline, static] |
arc sine
| static float OpenGUI::Math::ATan | ( | float | fValue | ) | [inline, static] |
arc tangent
| static float OpenGUI::Math::ATan2 | ( | float | fY, | |
| float | fX | |||
| ) | [inline, static] |
arc tangent of y/x
| static float OpenGUI::Math::Ceil | ( | float | fValue | ) | [inline, static] |
ceiling
| static float OpenGUI::Math::Cos | ( | float | fValue | ) | [inline, static] |
cosine
| static float OpenGUI::Math::DegreesToRadians | ( | float | degrees | ) | [inline, static] |
converts degrees into radians
| static float OpenGUI::Math::Exp | ( | float | fValue | ) | [inline, static] |
exponential
| static float OpenGUI::Math::FAbs | ( | float | fValue | ) | [inline, static] |
absolute value of floating-point
| static float OpenGUI::Math::Floor | ( | float | fValue | ) | [inline, static] |
floor
| static float OpenGUI::Math::FMod | ( | float | fX, | |
| float | fY | |||
| ) | [inline, static] |
floating point modular division
| static float OpenGUI::Math::InvSqrt | ( | float | fValue | ) | [inline, static] |
inverse square root
| static float OpenGUI::Math::Log | ( | float | fValue | ) | [inline, static] |
natural logarithm
| static float OpenGUI::Math::Pow | ( | float | fBase, | |
| float | fExponent | |||
| ) | [inline, static] |
numeric power
| static float OpenGUI::Math::RadiansToDegrees | ( | float | radians | ) | [inline, static] |
converts radians into degrees
| static float OpenGUI::Math::Sin | ( | float | fValue | ) | [inline, static] |
sine
| static float OpenGUI::Math::Sqr | ( | float | fValue | ) | [inline, static] |
square
| static float OpenGUI::Math::Sqrt | ( | float | fValue | ) | [inline, static] |
square root
| static float OpenGUI::Math::Tan | ( | float | fValue | ) | [inline, static] |
tangent
const float OpenGUI::Math::HALF_PI = float( 0.5 * Math::PI ) [static] |
value for Pi / 2
const float OpenGUI::Math::PI = float( 4.0 * atan( 1.0 ) ) [static] |
value for Pi
const float OpenGUI::Math::TWO_PI = float( 2.0 * Math::PI ) [static] |
value for 2 * Pi