From c24e08dff6db50ce674e11ec26cad22186ccecc8 Mon Sep 17 00:00:00 2001 From: "Alexander \"Ace\" Olofsson" Date: Sat, 14 Jun 2014 14:43:24 +0200 Subject: [PATCH] Use Ogre::Math::PI --- apps/openmw/mwworld/worldimp.cpp | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/apps/openmw/mwworld/worldimp.cpp b/apps/openmw/mwworld/worldimp.cpp index f8c537cce..6a18298f9 100644 --- a/apps/openmw/mwworld/worldimp.cpp +++ b/apps/openmw/mwworld/worldimp.cpp @@ -1,10 +1,5 @@ #include "worldimp.hpp" -#ifdef _WIN32 // For M_PI -#define _USE_MATH_DEFINES -#include -#endif - #ifdef _WIN32 #include #elif defined HAVE_UNORDERED_MAP @@ -67,9 +62,9 @@ namespace void wrap(float& rad) { if (rad>0) - rad = std::fmod(rad+M_PI, 2.0*M_PI)-M_PI; + rad = std::fmod(rad+Ogre::Math::PI, 2.0f*Ogre::Math::PI)-Ogre::Math::PI; else - rad = std::fmod(rad-M_PI, 2.0*M_PI)+M_PI; + rad = std::fmod(rad-Ogre::Math::PI, 2.0f*Ogre::Math::PI)+Ogre::Math::PI; } }