Fixed quaternion array access #942

This commit is contained in:
Christophe Riccio 2019-09-08 15:58:42 +02:00
parent 9ffa3f8a3d
commit 4db8f89aac

View File

@ -74,14 +74,14 @@ namespace detail
GLM_FUNC_QUALIFIER GLM_CONSTEXPR T & qua<T, Q>::operator[](typename qua<T, Q>::length_type i)
{
assert(i >= 0 && i < this->length());
return (&w)[i];
return (&x)[i];
}
template<typename T, qualifier Q>
GLM_FUNC_QUALIFIER GLM_CONSTEXPR T const& qua<T, Q>::operator[](typename qua<T, Q>::length_type i) const
{
assert(i >= 0 && i < this->length());
return (&w)[i];
return (&x)[i];
}
// -- Implicit basic constructors --