Browse Source

Removed ambiguity in fmat4x4 constructor

Jesse Talavera-Greenberg 10 years ago
parent
commit
e55eb1e08b
2 changed files with 4 additions and 4 deletions
  1. 2 2
      glm/gtx/simd_mat4.inl
  2. 2 2
      test/gtx/gtx_simd_mat4.cpp

+ 2 - 2
glm/gtx/simd_mat4.inl

@@ -62,8 +62,8 @@ GLM_FUNC_QUALIFIER fvec4SIMD const & fmat4x4SIMD::operator[]
 }
 
 #ifdef GLM_STATIC_CONST_MEMBERS
-	const fmat4x4SIMD fmat4x4SIMD::ZERO(0);
-	const fmat4x4SIMD fmat4x4SIMD::IDENTITY(1);
+	const fmat4x4SIMD fmat4x4SIMD::ZERO(static_cast<float>(0));
+	const fmat4x4SIMD fmat4x4SIMD::IDENTITY(static_cast<float>(1));
 #endif
 
 //////////////////////////////////////////////////////////////

+ 2 - 2
test/gtx/gtx_simd_mat4.cpp

@@ -256,8 +256,8 @@ int test_compute_gtx()
 int test_static_const() {
 	int Error(0);
 
-	Error += glm::simdMat4(1) == glm::simdMat4::IDENTITY ? 0 : 1;
-	Error += glm::simdMat4(0) == glm::simdMat4::ZERO ? 0 : 1;
+	Error += glm::mat4_cast(glm::simdMat4(static_cast<float>(1))) == glm::mat4_cast(glm::simdMat4::IDENTITY) ? 0 : 1;
+	Error += glm::mat4_cast(glm::simdMat4(static_cast<float>(0))) == glm::mat4_cast(glm::simdMat4::ZERO) ? 0 : 1;
 
 	return Error;
 }