MTek-GDL
0.100.4-muffintrap
Loading...
Searching...
No Matches
include
mgdl
mgdl-vector.h
Go to the documentation of this file.
1
#pragma once
2
10
#if defined(MGDL_USE_CCVECTOR)
11
12
#if defined(MGDL_PLATFORM_WII)
13
// On the Wii can use CCVector or gu
14
// Wii gcc does not complain about ccVector's tricks
15
#include <mgdl/ccVector/ccVector.h>
16
#else
17
// ccVector is written in C and uses anonymous structs
18
// to implement vector swizzling. Anonymous structs
19
// are not "allowed" in ISO C++ but they work
20
#pragma GCC diagnostic push
21
22
#if defined(MGDL_PLATFORM_WINDOWS)
23
// Only MSYS UCRT64 GCC complains about -Wpedantic
24
#pragma GCC diagnostic ignored "-Wpedantic"
25
#else
26
// Linux GCC complains about anon types and gnu extension
27
#pragma GCC diagnostic ignored "-Wnested-anon-types"
28
#pragma GCC diagnostic ignored "-Wgnu-anonymous-struct"
29
#endif
30
31
#include <mgdl/ccVector/ccVector.h>
32
33
#pragma GCC diagnostic pop
34
#endif
35
typedef
mat4x4 MTX4x4;
36
typedef
mat3x3 MTX3x3;
37
typedef
vec3 V3f;
38
39
#elif defined(MGDL_USE_CGLM)
40
41
#include <cglm/cglm.h>
42
43
#elif defined(MGDL_PLATFORM_WII)
44
45
#include <ogc/gu.h>
46
47
typedef
Mtx44 MTX4x4;
48
typedef
Mtx33 MTX3x3;
49
typedef
guVector V3f;
50
51
typedef
struct
_vecf2 {
52
f32 x, y;
53
} vec2;
54
55
#else
56
57
#error "No vector library specified"
58
59
#endif
Generated by
1.9.8