Clean up GLM_FORCE_NO_CTOR_INIT and fixed tests
This commit is contained in:
@@ -342,23 +342,14 @@ namespace detail
|
||||
# if !GLM_HAS_DEFAULTED_FUNCTIONS
|
||||
template<>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_SIMD vec<4, float, aligned_lowp>::vec()
|
||||
# ifndef GLM_FORCE_NO_CTOR_INIT
|
||||
: data(_mm_setzero_ps())
|
||||
# endif
|
||||
{}
|
||||
|
||||
template<>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_SIMD vec<4, float, aligned_mediump>::vec()
|
||||
# ifndef GLM_FORCE_NO_CTOR_INIT
|
||||
: data(_mm_setzero_ps())
|
||||
# endif
|
||||
{}
|
||||
|
||||
template<>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_SIMD vec<4, float, aligned_highp>::vec()
|
||||
# ifndef GLM_FORCE_NO_CTOR_INIT
|
||||
: data(_mm_setzero_ps())
|
||||
# endif
|
||||
{}
|
||||
# endif//!GLM_HAS_DEFAULTED_FUNCTIONS
|
||||
|
||||
|
||||
@@ -133,6 +133,12 @@ namespace glm
|
||||
template<typename T, precision P>
|
||||
GLM_FUNC_DECL bool operator!=(tdualquat<T, P> const & q1, tdualquat<T, P> const & q2);
|
||||
|
||||
/// Creates an identity dual quaternion.
|
||||
///
|
||||
/// @see gtx_dual_quaternion
|
||||
template <typename T, precision P>
|
||||
GLM_FUNC_DECL tdualquat<T, P> dual_quat_identity();
|
||||
|
||||
/// Returns the normalized quaternion.
|
||||
///
|
||||
/// @see gtx_dual_quaternion
|
||||
|
||||
@@ -218,6 +218,14 @@ namespace glm
|
||||
|
||||
// -- Operations --
|
||||
|
||||
template<typename T, precision P>
|
||||
GLM_FUNC_QUALIFIER tdualquat<T, P> dual_quat_identity()
|
||||
{
|
||||
return tdualquat<T, P>(
|
||||
tquat<T, P>(static_cast<T>(1), static_cast<T>(0), static_cast<T>(0), static_cast<T>(0)),
|
||||
tquat<T, P>(static_cast<T>(0), static_cast<T>(0), static_cast<T>(0), static_cast<T>(0)));
|
||||
}
|
||||
|
||||
template<typename T, precision P>
|
||||
GLM_FUNC_QUALIFIER tdualquat<T, P> normalize(tdualquat<T, P> const & q)
|
||||
{
|
||||
|
||||
@@ -32,6 +32,12 @@ namespace glm
|
||||
/// @addtogroup gtx_quaternion
|
||||
/// @{
|
||||
|
||||
/// Create an identity quaternion.
|
||||
///
|
||||
/// @see gtx_quaternion
|
||||
template<typename T, precision P>
|
||||
GLM_FUNC_DECL tquat<T, P> quat_identity();
|
||||
|
||||
/// Compute a cross product between a quaternion and a vector.
|
||||
///
|
||||
/// @see gtx_quaternion
|
||||
|
||||
@@ -6,6 +6,12 @@
|
||||
|
||||
namespace glm
|
||||
{
|
||||
template<typename T, precision P>
|
||||
GLM_FUNC_QUALIFIER tquat<T, P> quat_identity()
|
||||
{
|
||||
return tquat<T, P>(static_cast<T>(1), static_cast<T>(0), static_cast<T>(0), static_cast<T>(0));
|
||||
}
|
||||
|
||||
template<typename T, precision P>
|
||||
GLM_FUNC_QUALIFIER vec<3, T, P> cross(vec<3, T, P> const& v, tquat<T, P> const& q)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user