- Rename structs folder to struct

- Include files in `cglms.h`
- Fix style issues (tabs to spaces, open brace without newline)
This commit is contained in:
acoto87 committed 2019-05-21 16:45:34 -05:00
1 parent fd3b0634d2
commit ba2031d977
18 files changed
+17 -27

No files matched your search

+13 -5
View File
@@ -13,11 +13,19 @@ extern "C" {
#include "cglm.h" #include "cglm.h"
#include "types-struct.h" #include "types-struct.h"
#include "structs/vec3.h" #include "struct/vec3.h"
#include "structs/vec4.h" #include "struct/vec4.h"
#include "structs/mat3.h" #include "struct/mat3.h"
#include "structs/mat4.h" #include "struct/mat4.h"
#include "structs/sphere.h" #include "struct/affine.h"
#include "struct/frustum.h"
#include "struct/plane.h"
#include "struct/box.h"
#include "struct/color.h"
#include "struct/io.h"
#include "struct/project.h"
#include "struct/sphere.h"
#include "struct/curve.h"
#ifdef __cplusplus #ifdef __cplusplus
} }
File renamed without changes.
@@ -135,8 +135,6 @@ glms_aabb_frustum(vec3s box[2], vec4s planes[6]) {
CGLM_INLINE CGLM_INLINE
void void
glms_aabb_invalidate(vec3s box[2]) { glms_aabb_invalidate(vec3s box[2]) {
// FIX: Modify param
//
box[0] = glms_vec3_broadcast(FLT_MAX); box[0] = glms_vec3_broadcast(FLT_MAX);
box[1] = glms_vec3_broadcast(-FLT_MAX); box[1] = glms_vec3_broadcast(-FLT_MAX);
} }
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -745,7 +745,6 @@ glms_cross(vec3s a, vec3s b) {
* *
* @param[in] a vector1 * @param[in] a vector1
* @param[in] b vector2 * @param[in] b vector2
*
* @return dot product * @return dot product
*/ */
CGLM_INLINE CGLM_INLINE
File renamed without changes.
File renamed without changes.
-11
View File
@@ -53,11 +53,6 @@ typedef union mat3s {
float m10, m11, m12; float m10, m11, m12;
float m20, m21, m22; float m20, m21, m22;
}; };
struct {
vec3s col0;
vec3s col1;
vec3s col2;
};
#endif #endif
vec3s col[3]; vec3s col[3];
mat3 raw; mat3 raw;
@@ -71,12 +66,6 @@ typedef union CGLM_ALIGN_MAT mat4s {
float m20, m21, m22, m23; float m20, m21, m22, m23;
float m30, m31, m32, m33; float m30, m31, m32, m33;
}; };
struct {
vec4s col0;
vec4s col1;
vec4s col2;
vec4s col3;
};
#endif #endif
vec4s col[4]; vec4s col[4];
mat4 raw; mat4 raw;
+4 -8
View File
@@ -49,8 +49,7 @@ test_rand_vec3(vec3 dest) {
} }
vec3s vec3s
test_rand_vec3s() test_rand_vec3s() {
{
vec3s r; vec3s r;
test_rand_vec3(r.raw); test_rand_vec3(r.raw);
return r; return r;
@@ -67,8 +66,7 @@ test_rand_vec4(vec4 dest) {
} }
vec4s vec4s
test_rand_vec4s() test_rand_vec4s() {
{
vec4s r; vec4s r;
test_rand_vec4(r.raw); test_rand_vec4(r.raw);
return r; return r;
@@ -137,8 +135,7 @@ test_assert_vec3_eq(vec3 v1, vec3 v2) {
} }
void void
test_assert_vec3s_eq(vec3s v1, vec3s v2) test_assert_vec3s_eq(vec3s v1, vec3s v2) {
{
test_assert_vec3_eq(v1.raw, v2.raw); test_assert_vec3_eq(v1.raw, v2.raw);
} }
@@ -151,8 +148,7 @@ test_assert_vec4_eq(vec4 v1, vec4 v2) {
} }
void void
test_assert_vec4s_eq(vec4s v1, vec4s v2) test_assert_vec4s_eq(vec4s v1, vec4s v2) {
{
test_assert_vec4_eq(v1.raw, v2.raw); test_assert_vec4_eq(v1.raw, v2.raw);
} }