mat4 to quaternion

This commit is contained in:
Recep Aslantas
2018-04-07 19:46:46 +03:00
parent f5140ea005
commit 257c57d41f
10 changed files with 132 additions and 5 deletions

22
test/src/test_quat.c Normal file
View File

@@ -0,0 +1,22 @@
/*
* Copyright (c), Recep Aslantas.
*
* MIT License (MIT), http://opensource.org/licenses/MIT
* Full license can be found in the LICENSE file
*/
#include "test_common.h"
void
test_quat(void **state) {
mat4 rot;
versor inQuat, outQuat;
int i;
for (i = 0; i < 10000; i++) {
test_rand_quat(inQuat);
glmc_quat_mat4(inQuat, rot);
glm_mat4_quat(rot, outQuat);
test_assert_quat_eq(inQuat, outQuat);
}
}