mirror of
https://github.com/g-truc/glm.git
synced 2024-11-10 04:31:47 +00:00
Fixed tests
This commit is contained in:
parent
c42904c720
commit
a7fb32669c
@ -224,14 +224,14 @@ int test_compute_gtx()
|
||||
std::clock_t TimeEnd = clock();
|
||||
printf("test_compute_gtx: %ld\n", TimeEnd - TimeStart);
|
||||
|
||||
return Output.size() != 0;
|
||||
return 0;
|
||||
}
|
||||
|
||||
int main()
|
||||
{
|
||||
int Failed = GLM_COMPILER;
|
||||
int Error = 0;
|
||||
|
||||
std::vector<glm::mat4> Data(1024 * 1024 * 8);
|
||||
std::vector<glm::mat4> Data(64 * 64 * 1);
|
||||
for(std::size_t i = 0; i < Data.size(); ++i)
|
||||
Data[i] = glm::mat4(
|
||||
glm::vec4(glm::compRand4(-2.0f, 2.0f)),
|
||||
@ -277,13 +277,11 @@ int main()
|
||||
glm::simdVec4 B(5.0f, 6.0f, 7.0f, 8.0f);
|
||||
__m128 C = _mm_shuffle_ps(A.Data, B.Data, _MM_SHUFFLE(1, 0, 1, 0));
|
||||
|
||||
Failed += test_compute_glm();
|
||||
Failed += test_compute_gtx();
|
||||
Error += test_compute_glm();
|
||||
Error += test_compute_gtx();
|
||||
|
||||
float Det = glm::determinant(glm::simdMat4(1.0));
|
||||
glm::simdMat4 D = glm::matrixCompMult(glm::simdMat4(1.0), glm::simdMat4(1.0));
|
||||
|
||||
system("pause");
|
||||
|
||||
return Failed;
|
||||
return Error;
|
||||
}
|
||||
|
@ -16,7 +16,7 @@ int main()
|
||||
glm::simdVec4 A1(0.0f, 0.1f, 0.2f, 0.3f);
|
||||
glm::simdVec4 B1(0.4f, 0.5f, 0.6f, 0.7f);
|
||||
glm::simdVec4 C1 = A1 + B1;
|
||||
//glm::simdVec4 D1 = A1.swizzle<glm::X, glm::Z, glm::Y, glm::W>();
|
||||
glm::simdVec4 D1 = A1.swizzle<glm::X, glm::Z, glm::Y, glm::W>();
|
||||
glm::simdVec4 E1(glm::vec4(1.0f));
|
||||
glm::vec4 F1 = glm::vec4_cast(E1);
|
||||
//glm::vec4 G1(E1);
|
||||
|
Loading…
Reference in New Issue
Block a user