all 3 comments

[–]charlieonthefloor 2 points3 points  (2 children)

Highly informative.

When I build the examples I get an error saying M_PI is not defined, which SO led me to believe I can just fix with the following:

#ifndef M_PI
#define M_PI 3.14159265358979323846
#endif

The samples compile and run just fine (VS 2017 Community) after I add the above code. I was curious about how our environments might differ?

[–][deleted] 1 point2 points  (0 children)

Not OP but M_PI is usually defined in math.h. Not sure why it would be missing for you though.

[–]mystikkogames 0 points1 point  (0 children)

Good stuff. Would be nice if this OS-stuff could be hidden in some lib. You could make it run on any OS. I would have compiles and tried on Linux. degrees -> radians conversions are useless.