mirror of
https://github.com/g-truc/glm.git
synced 2024-11-10 04:31:47 +00:00
parent
e4ffe16bed
commit
22c88fd821
@ -698,7 +698,7 @@
|
|||||||
|
|
||||||
#if GLM_HAS_CONSTEXPR || GLM_HAS_CONSTEXPR_PARTIAL
|
#if GLM_HAS_CONSTEXPR || GLM_HAS_CONSTEXPR_PARTIAL
|
||||||
# define GLM_CONSTEXPR constexpr
|
# define GLM_CONSTEXPR constexpr
|
||||||
# if GLM_COMPILER & GLM_COMPILER_VC // Visual C++ has a bug #594 https://github.com/g-truc/glm/issues/594
|
# if ((GLM_COMPILER & GLM_COMPILER_VC) && (GLM_COMPILER <= GLM_COMPILER_VC14)) // Visual C++ has a bug #594 https://github.com/g-truc/glm/issues/594
|
||||||
# define GLM_CONSTEXPR_CTOR
|
# define GLM_CONSTEXPR_CTOR
|
||||||
# else
|
# else
|
||||||
# define GLM_CONSTEXPR_CTOR constexpr
|
# define GLM_CONSTEXPR_CTOR constexpr
|
||||||
|
@ -339,20 +339,6 @@ namespace detail
|
|||||||
};
|
};
|
||||||
}//namespace detail
|
}//namespace detail
|
||||||
|
|
||||||
# if !GLM_HAS_DEFAULTED_FUNCTIONS
|
|
||||||
template<>
|
|
||||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_SIMD vec<4, float, aligned_lowp>::vec()
|
|
||||||
{}
|
|
||||||
|
|
||||||
template<>
|
|
||||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_SIMD vec<4, float, aligned_mediump>::vec()
|
|
||||||
{}
|
|
||||||
|
|
||||||
template<>
|
|
||||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_SIMD vec<4, float, aligned_highp>::vec()
|
|
||||||
{}
|
|
||||||
# endif//!GLM_HAS_DEFAULTED_FUNCTIONS
|
|
||||||
|
|
||||||
template<>
|
template<>
|
||||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_SIMD vec<4, float, aligned_lowp>::vec(float _s) :
|
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_SIMD vec<4, float, aligned_lowp>::vec(float _s) :
|
||||||
data(_mm_set1_ps(_s))
|
data(_mm_set1_ps(_s))
|
||||||
|
@ -228,7 +228,7 @@ namespace glm
|
|||||||
template<typename T, precision P>
|
template<typename T, precision P>
|
||||||
GLM_FUNC_QUALIFIER tquat<T, P> quatLookAtRH(vec<3, T, P> const& direction, vec<3, T, P> const& up)
|
GLM_FUNC_QUALIFIER tquat<T, P> quatLookAtRH(vec<3, T, P> const& direction, vec<3, T, P> const& up)
|
||||||
{
|
{
|
||||||
tmat3x3<T, P> Result;
|
mat<3, 3, T, P> Result;
|
||||||
|
|
||||||
Result[2] = -normalize(direction);
|
Result[2] = -normalize(direction);
|
||||||
Result[0] = normalize(cross(up, Result[2]));
|
Result[0] = normalize(cross(up, Result[2]));
|
||||||
@ -240,7 +240,7 @@ namespace glm
|
|||||||
template<typename T, precision P>
|
template<typename T, precision P>
|
||||||
GLM_FUNC_QUALIFIER tquat<T, P> quatLookAtLH(vec<3, T, P> const& direction, vec<3, T, P> const& up)
|
GLM_FUNC_QUALIFIER tquat<T, P> quatLookAtLH(vec<3, T, P> const& direction, vec<3, T, P> const& up)
|
||||||
{
|
{
|
||||||
tmat3x3<T, P> Result;
|
mat<3, 3, T, P> Result;
|
||||||
|
|
||||||
Result[2] = normalize(direction);
|
Result[2] = normalize(direction);
|
||||||
Result[0] = normalize(cross(up, Result[2]));
|
Result[0] = normalize(cross(up, Result[2]));
|
||||||
|
Loading…
Reference in New Issue
Block a user