From 7b971e06236c581087a851c8ecda11bb7be12839 Mon Sep 17 00:00:00 2001 From: Ray Date: Mon, 2 Jul 2018 18:53:46 +0200 Subject: Added Quaternion typedef --- src/raylib.h | 2 ++ src/raymath.h | 16 ++++++++-------- 2 files changed, 10 insertions(+), 8 deletions(-) (limited to 'src') diff --git a/src/raylib.h b/src/raylib.h index de78b8c3..96bf2443 100644 --- a/src/raylib.h +++ b/src/raylib.h @@ -332,6 +332,8 @@ typedef struct Vector4 { float w; } Vector4; +typedef Vector4 Quaternion; + // Matrix type (OpenGL style 4x4 - right handed, column major) typedef struct Matrix { float m0, m4, m8, m12; diff --git a/src/raymath.h b/src/raymath.h index a574dd0d..4e100bc3 100644 --- a/src/raymath.h +++ b/src/raymath.h @@ -114,6 +114,14 @@ float y; float z; } Vector3; + + // Quaternion type + typedef struct Quaternion { + float x; + float y; + float z; + float w; + } Quaternion; // Matrix type (OpenGL style 4x4 - right handed, column major) typedef struct Matrix { @@ -122,14 +130,6 @@ float m2, m6, m10, m14; float m3, m7, m11, m15; } Matrix; - - // Quaternion type - typedef struct Quaternion { - float x; - float y; - float z; - float w; - } Quaternion; #endif // NOTE: Helper types to be used instead of array return types for *ToFloat functions -- cgit v1.2.3