diff options
author | Chris Robinson <[email protected]> | 2018-12-22 20:32:00 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2018-12-22 20:32:00 -0800 |
commit | ebfe818d2eb3a5c4e27040f139ae3fb349f13865 (patch) | |
tree | 754a905c80e4f7b4378899468cc592384cbf11a8 /common | |
parent | bfa98be48a4e84902d4c4bb2836f58cbbf582583 (diff) |
Fix narrowing conversion from double to float
Diffstat (limited to 'common')
-rw-r--r-- | common/math_defs.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/common/math_defs.h b/common/math_defs.h index 4686e96b..6471e2e7 100644 --- a/common/math_defs.h +++ b/common/math_defs.h @@ -13,7 +13,7 @@ #define SQRTF_3 1.73205080756887719318f -constexpr inline float Deg2Rad(float x) noexcept { return x * float{M_PI/180.0}; } -constexpr inline float Rad2Deg(float x) noexcept { return x * float{180.0/M_PI}; } +constexpr inline float Deg2Rad(float x) noexcept { return x * static_cast<float>(M_PI/180.0); } +constexpr inline float Rad2Deg(float x) noexcept { return x * static_cast<float>(180.0/M_PI); } #endif /* AL_MATH_DEFS_H */ |