- separating struct types into types-struct.h

- vec3s implementation
- fix style issues
This commit is contained in:
acoto87
2019-04-08 21:06:01 -05:00
parent 1de8aeb940
commit 1aa54dc110
10 changed files with 617 additions and 117 deletions

View File

@@ -0,0 +1,36 @@
/*
* Copyright (c), Recep Aslantas.
*
* MIT License (MIT), http://opensource.org/licenses/MIT
* Full license can be found in the LICENSE file
*/
#ifndef cglm_types_struct_h
#define cglm_types_struct_h
#include "types.h"
typedef union CGLM_ALIGN_IF(16) vec3s {
#ifndef CGLM_NO_ANONYMOUS_STRUCT
struct {
float x;
float y;
float z;
};
#endif
vec3 raw;
} vec3s;
typedef union CGLM_ALIGN_IF(16) vec4s {
#ifndef CGLM_NO_ANONYMOUS_STRUCT
struct {
float x;
float y;
float z;
float w;
};
#endif
vec4 raw;
} vec4s;
#endif /* cglm_types_struct_h */