Просмотр исходного кода

Fixed vec equality check function from the compute_vector_decl.hpp file

Forest Fox 1 год назад
Родитель
Сommit
45008b225e
1 измененных файлов с 2 добавлено и 2 удалено
  1. 2 2
      glm/detail/compute_vector_decl.hpp

+ 2 - 2
glm/detail/compute_vector_decl.hpp

@@ -159,8 +159,8 @@ namespace glm {
 			GLM_FUNC_QUALIFIER GLM_CONSTEXPR static bool call(vec<L, T, Q> const& v1, vec<L, T, Q> const& v2)
 			{
 				bool b = true;
-				for (length_t i = 0; i < L; ++i)
-					b = b && detail::compute_equal<T, std::numeric_limits<T>::is_iec559>::call(v1.x, v2.x);
+				for (length_t i = 0; b && i < L; ++i)
+					b = detail::compute_equal<T, std::numeric_limits<T>::is_iec559>::call(v1[i], v2[i]);
 				return b;
 			}
 		};