Added float variants of osg::PI etc. in the form osg::PIf

Converted osg::PI usage to osg::PIf in ShapeDrawable.cpp to address Windows build errors
This commit is contained in:
Robert Osfield
2016-06-03 11:28:10 +01:00
parent 728c439e35
commit afe89e8d94
2 changed files with 29 additions and 23 deletions

View File

@@ -33,6 +33,12 @@ const double PI_4 = 0.78539816339744830962;
const double LN_2 = 0.69314718055994530942;
const double INVLN_2 = 1.0 / LN_2;
const float PIf = 3.14159265358979323846f;
const float PI_2f = 1.57079632679489661923f;
const float PI_4f = 0.78539816339744830962f;
const float LN_2f = 0.69314718055994530942f;
const float INVLN_2f = 1.0f / LN_2f;
template<typename T>
inline T absolute(T v) { return v<(T)0?-v:v; }