aboutsummaryrefslogtreecommitdiff
path: root/redist/linmath.h
diff options
context:
space:
mode:
authorultramn <dchapm2@umbc.edu>2016-12-16 13:52:44 -0800
committerultramn <dchapm2@umbc.edu>2016-12-16 13:52:44 -0800
commitcc05bcaf95b80dc89cbe1f8486c0ed14dc4d956c (patch)
treedebf059c1f072e265254a5180e8fc06f74291ebf /redist/linmath.h
parent93ad6a810479a5cc09a809f2ea23d549c7cc9c2a (diff)
parent898a9a5f242a1691e1c34062208b48cb0682b5d9 (diff)
downloadlibsurvive-cc05bcaf95b80dc89cbe1f8486c0ed14dc4d956c.tar.gz
libsurvive-cc05bcaf95b80dc89cbe1f8486c0ed14dc4d956c.tar.bz2
Merge branch 'master' of https://github.com/cnlohr/libsurvive
Diffstat (limited to 'redist/linmath.h')
-rw-r--r--redist/linmath.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/redist/linmath.h b/redist/linmath.h
index 9b21347..5cc7b7d 100644
--- a/redist/linmath.h
+++ b/redist/linmath.h
@@ -6,6 +6,12 @@
//Yes, I know it's kind of arbitrary.
#define DEFAULT_EPSILON 0.001
+//For printf
+#define PFTHREE(x) x[0], x[1], x[2]
+#define PFFOUR(x) x[0], x[1], x[2], x[3]
+
+#define LINMATHPI 3.141592653589
+
//If you want, you can define FLT to be double for double precision.
#ifndef FLT
#define FLT float
@@ -30,8 +36,9 @@ int compare3d( const FLT * a, const FLT * b, FLT epsilon );
void copy3d( FLT * out, const FLT * in );
+FLT magnitude3d( FLT * a );
-
+FLT anglebetween3d( FLT * a, FLT * b );
//Quaternion things...