diff options
author | Tavian Barnes <tavianator@gmail.com> | 2010-09-30 12:17:03 -0400 |
---|---|---|
committer | Tavian Barnes <tavianator@gmail.com> | 2010-09-30 12:27:11 -0400 |
commit | 93619cc41c1fc49ab0696993ee93e6ada5951a6d (patch) | |
tree | 87ea38fc307d851ef4220da55fe47b1087d4135a /libdimension | |
parent | 9666ad922524b617947590aed4c6fde5febab53a (diff) | |
download | dimension-93619cc41c1fc49ab0696993ee93e6ada5951a6d.tar.xz |
Don't assume M_PI will be defined.
Diffstat (limited to 'libdimension')
-rw-r--r-- | libdimension/dimension/geometry.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libdimension/dimension/geometry.h b/libdimension/dimension/geometry.h index 42a9985..c90c3c8 100644 --- a/libdimension/dimension/geometry.h +++ b/libdimension/dimension/geometry.h @@ -87,13 +87,13 @@ dmnsn_max(double a, double b) DMNSN_INLINE double dmnsn_radians(double degrees) { - return degrees*M_PI/180.0; + return degrees*atan(1.0)/45.0; } DMNSN_INLINE double dmnsn_degrees(double radians) { - return radians*180.0/M_PI; + return radians*45.0/atan(1.0); } /* Shorthand for vector/matrix construction */ |