swordlegend / recastnavigation

Automatically exported from code.google.com/p/recastnavigation
zlib License
0 stars 0 forks source link

M_PI is not part of the C/C++ standard #128

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Hi Mikko,

I've just come across a platform that doesn't know what M_PI is. I'm compiling 
Recast on the Wii: M_PI is not part of the C++ standard, and hence is, rather 
irritatingly, not defined in <math.h>

Would it be a good idea to have your own RC_PI?

Thanks,
- Neil

Original issue reported on code.google.com by armstron...@gmail.com on 7 Oct 2010 at 3:12

GoogleCodeExporter commented 9 years ago
Fixed in R231. There is RC_PI for Recast only stuff, and DU_PI which is used n 
debug draw things. I'm not sure how to define PI properly for floating points 
values. I printf'd M_PI as float32 with very many digits and picked number of 
correct digits +1.

Original comment by memono...@gmail.com on 10 Oct 2010 at 10:19