Math helper class.
More...
#include <external/RadixEngine/include/radix/core/math/Math.hpp>
|
static constexpr float | PI = 3.141592653589793238462643383279502884197169399375105820974944592307 |
|
static constexpr float | DEG_TO_RAD = PI / 180 |
|
static constexpr float | RAD_TO_DEG = 180 / PI |
|
template<typename T >
static constexpr T radix::Math::clamp |
( |
T |
v, |
|
|
T |
low, |
|
|
T |
high |
|
) |
| |
|
inlinestatic |
Restricts a value to a range.
- Parameters
-
v | Value |
low | Low bound |
high | High bound |
template<typename T >
static constexpr T radix::Math::sign |
( |
T |
v | ) |
|
|
inlinestatic |
Returns the sign of value.
- Parameters
-
- Returns
- 1 if v is positive -1 if v is negative 0 if v is 0
constexpr float radix::Math::DEG_TO_RAD = PI / 180 |
|
static |
constexpr float radix::Math::PI = 3.141592653589793238462643383279502884197169399375105820974944592307 |
|
static |
constexpr float radix::Math::RAD_TO_DEG = 180 / PI |
|
static |
The documentation for this class was generated from the following files:
- external/RadixEngine/include/radix/core/math/Math.hpp
- external/RadixEngine/source/core/math/Math.cpp