Fixed cases of unspecialized simd

This commit is contained in:
Christophe Riccio
2014-10-18 02:34:20 +02:00
parent 8a1bf4410b
commit 327c7917fb
2 changed files with 30 additions and 13 deletions

View File

@@ -7,6 +7,7 @@
// File : test/core/type_vec4.cpp
///////////////////////////////////////////////////////////////////////////////////////////////////
//#define GLM_FORCE_AVX2
#define GLM_SWIZZLE
#include <glm/vector_relational.hpp>
#include <glm/vec2.hpp>
@@ -42,7 +43,7 @@ int test_vec4_ctor()
{
int Error = 0;
#if(GLM_HAS_INITIALIZER_LISTS)
#if GLM_HAS_INITIALIZER_LISTS
{
glm::vec4 a{ 0, 1, 2, 3 };
std::vector<glm::vec4> v = {
@@ -60,7 +61,7 @@ int test_vec4_ctor()
}
#endif
#if(GLM_HAS_ANONYMOUS_UNION && defined(GLM_SWIZZLE))
#if GLM_HAS_ANONYMOUS_UNION && defined(GLM_SWIZZLE)
{
glm::vec4 A = glm::vec4(1.0f, 2.0f, 3.0f, 4.0f);
glm::vec4 B = A.xyzw;
@@ -89,7 +90,7 @@ int test_vec4_ctor()
Error += glm::all(glm::equal(A, L)) ? 0 : 1;
Error += glm::all(glm::equal(A, M)) ? 0 : 1;
}
#endif//(GLM_HAS_ANONYMOUS_UNION && defined(GLM_SWIZZLE))
#endif// GLM_HAS_ANONYMOUS_UNION && defined(GLM_SWIZZLE)
{
glm::vec4 A(1);
@@ -276,7 +277,7 @@ int test_vec4_swizzle_partial()
glm::vec4 A(1, 2, 3, 4);
# if(GLM_HAS_ANONYMOUS_UNION && defined(GLM_SWIZZLE_RELAX))
# if GLM_HAS_ANONYMOUS_UNION && defined(GLM_SWIZZLE_RELAX)
{
glm::vec4 B(A.xy, A.zw);
Error += A == B ? 0 : 1;