mirror of
https://github.com/g-truc/glm.git
synced 2024-11-22 17:04:35 +00:00
Add tau constant ##1153
This commit is contained in:
parent
08f2fd1099
commit
85f2e6b998
@ -39,6 +39,11 @@ namespace glm
|
|||||||
template<typename genType>
|
template<typename genType>
|
||||||
GLM_FUNC_DECL GLM_CONSTEXPR genType two_pi();
|
GLM_FUNC_DECL GLM_CONSTEXPR genType two_pi();
|
||||||
|
|
||||||
|
/// Return unit-circle circumference, or pi * 2.
|
||||||
|
/// @see gtc_constants
|
||||||
|
template<typename genType>
|
||||||
|
GLM_FUNC_DECL GLM_CONSTEXPR genType tau() { return glm::two_pi<genType>(); }
|
||||||
|
|
||||||
/// Return square root of pi.
|
/// Return square root of pi.
|
||||||
/// @see gtc_constants
|
/// @see gtc_constants
|
||||||
template<typename genType>
|
template<typename genType>
|
||||||
|
@ -20,6 +20,12 @@ namespace glm
|
|||||||
return genType(6.28318530717958647692528676655900576);
|
return genType(6.28318530717958647692528676655900576);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
template<typename genType>
|
||||||
|
GLM_FUNC_QUALIFIER GLM_CONSTEXPR genType tau()
|
||||||
|
{
|
||||||
|
return two_pi<genType>();
|
||||||
|
}
|
||||||
|
|
||||||
template<typename genType>
|
template<typename genType>
|
||||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR genType root_pi()
|
GLM_FUNC_QUALIFIER GLM_CONSTEXPR genType root_pi()
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user