Skip to content

Commit

Permalink
basic euler impl
Browse files Browse the repository at this point in the history
  • Loading branch information
jwerle committed Feb 17, 2016
1 parent 76e4a91 commit 29b4ada
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 0 deletions.
2 changes: 2 additions & 0 deletions include/glisy/math.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@

#define GLISY_EPSILON 0.000001

#include <glisy/math/quat.h>
#include <glisy/math/euler.h>
#include <glisy/math/vector.h>
#include <glisy/math/matrix.h>

Expand Down
24 changes: 24 additions & 0 deletions include/glisy/math/euler.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
#ifndef GLISY_EULER_H
#define GLISY_EULER_H

#include "vec3.h"

/**
* euler type
*/

typedef vec3 euler;

/**
* euler initializer.
*/

#define euler(x, y, z) (euler) {x, y, z}
#define euler_create() euler(0, 0, 0)

/**
* Clones and returns euler.
*/

#define euler_clone(e) ((euler) {e.x, e.y, e.z})
#endif

0 comments on commit 29b4ada

Please sign in to comment.