1
0
mirror of https://github.com/VCMP-SqMod/SqMod.git synced 2025-02-20 19:57:12 +01:00

Add hepter variables and typedefs to the shared basic header.

This commit is contained in:
Sandu Liviu Catalin 2016-08-04 03:08:59 +03:00
parent c17414fe8e
commit 9c4198770d

View File

@ -7,6 +7,51 @@
// ------------------------------------------------------------------------------------------------
namespace SqMod {
/* ------------------------------------------------------------------------------------------------
* Constant for PI.
*/
constexpr Float32 SQMOD_PI = 3.14159265359f;
/* ------------------------------------------------------------------------------------------------
* Constant for reciprocal of PI.
*/
constexpr Float32 SQMOD_RECIPROCAL_PI = (1.0f / SQMOD_PI);
/* ------------------------------------------------------------------------------------------------
* Constant for half of PI.
*/
constexpr Float32 SQMOD_HALF_PI = (SQMOD_PI / 2.0f);
/* ------------------------------------------------------------------------------------------------
* Constant for 64 bit PI.
*/
constexpr Float64 SQMOD_PI64 = 3.1415926535897932384626433832795028841971693993751;
/* ------------------------------------------------------------------------------------------------
* Constant for 64 bit reciprocal of PI.
*/
constexpr Float64 SQMOD_RECIPROCAL_PI64 = 1.0/SQMOD_PI64;
/* ------------------------------------------------------------------------------------------------
* 32bit Constant for converting from degrees to radians.
*/
constexpr Float32 SQMOD_DEGTORAD = SQMOD_PI / 180.0f;
/* ------------------------------------------------------------------------------------------------
* 32bit constant for converting from radians to degrees. (formally known as GRAD_PI)
*/
constexpr Float32 SQMOD_RADTODEG = 180.0f / SQMOD_PI;
/* ------------------------------------------------------------------------------------------------
* 64 bit constant for converting from degrees to radians. (formally known as GRAD_PI2)
*/
constexpr Float64 SQMOD_DEGTORAD64 = SQMOD_PI64 / 180.0;
/* ------------------------------------------------------------------------------------------------
* 64 bit constant for converting from radians to degrees.
*/
constexpr Float64 SQMOD_RADTODEG64 = 180.0 / SQMOD_PI64;
/* ------------------------------------------------------------------------------------------------
* Forward declarations of the logging functions to avoid including the logger everywhere.
* Primary logging functions.