|
|
|
@ -31,41 +31,34 @@ enum comp |
|
|
|
|
// return _mm_shuffle_ps(Src, Src, mask<(int(W) << 6) | (int(Z) << 4) | (int(Y) << 2) | (int(X) << 0)>::value);
|
|
|
|
|
//}
|
|
|
|
|
|
|
|
|
|
bool test_hvec4() |
|
|
|
|
int test_hvec4() |
|
|
|
|
{ |
|
|
|
|
glm::hvec4 const A = glm::hvec4(0, 1, 2, 3); |
|
|
|
|
//glm::hvec4 B = glm::swizzle<glm::X, glm::Y, glm::Z, glm::W>(A);
|
|
|
|
|
|
|
|
|
|
//glm::vec4 B = glm::detail::tvec##(glm::vec4::_size)<float>();
|
|
|
|
|
|
|
|
|
|
return true; |
|
|
|
|
return 0; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
static bool test_operators() |
|
|
|
|
static int test_operators() |
|
|
|
|
{ |
|
|
|
|
glm::vec4 A(1.0f); |
|
|
|
|
glm::vec4 B(1.0f); |
|
|
|
|
bool R = A != B; |
|
|
|
|
bool S = A == B; |
|
|
|
|
|
|
|
|
|
return true; |
|
|
|
|
return (S && !R) ? 0 : 1; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
int main() |
|
|
|
|
{ |
|
|
|
|
test_hvec4(); |
|
|
|
|
|
|
|
|
|
//__m128 DataA = swizzle<X, Y, Z, W>(glm::vec4(1.0f, 2.0f, 3.0f, 4.0f));
|
|
|
|
|
//__m128 DataB = swizzle<W, Z, Y, X>(glm::vec4(1.0f, 2.0f, 3.0f, 4.0f));
|
|
|
|
|
|
|
|
|
|
bool Result = true; |
|
|
|
|
|
|
|
|
|
Result = Result && test_operators(); |
|
|
|
|
Result = Result && test_hvec4(); |
|
|
|
|
|
|
|
|
|
assert(Result); |
|
|
|
|
return Result; |
|
|
|
|
|
|
|
|
|
return 0; |
|
|
|
|
int Error = 0; |
|
|
|
|
Error += test_operators(); |
|
|
|
|
Error += test_hvec4(); |
|
|
|
|
return Error; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|