Browse Source

Added test_isOrthogonal for zero matrix

tetrisplusplus 2 years ago
parent
commit
2af53d5981
1 changed files with 8 additions and 2 deletions
  1. 8 2
      test/gtx/gtx_matrix_query.cpp

+ 8 - 2
test/gtx/gtx_matrix_query.cpp

@@ -45,8 +45,14 @@ int test_isOrthogonal()
 {
 	int Error(0);
 
-	bool TestA = glm::isOrthogonal(glm::mat4(1), 0.00001f);
-	Error += TestA ? 0 : 1;
+	{
+		bool TestA = glm::isOrthogonal(glm::mat4(1), 0.00001f);
+		Error += TestA ? 0 : 1;
+	}
+	{
+		bool TestA = glm::isOrthogonal(glm::mat4(0), 0.00001f);
+		Error += TestA ? 1 : 0;
+	}
 
 	return Error;
 }