24 lines
323 B
C++
24 lines
323 B
C++
#pragma once
|
|
|
|
#include <numbers>
|
|
|
|
namespace math
|
|
{
|
|
|
|
/**
|
|
* pi
|
|
*/
|
|
constexpr float PI = std::numbers::pi_v<float>;
|
|
|
|
/**
|
|
* Degrees to radians conversion factor
|
|
*/
|
|
constexpr float DEG_TO_RAD = PI / 180.0f;
|
|
|
|
/**
|
|
* Radians to degrees conversion factor
|
|
*/
|
|
constexpr float RAD_TO_DEG = 1.0f / DEG_TO_RAD;
|
|
|
|
} // namespace math
|