Browse Source

Removed _USE_MATH_DEFINES.

Branimir Karadzic 11 years ago
parent
commit
7a829583ce
3 changed files with 4 additions and 4 deletions
  1. 1 1
      examples/common/bounds.cpp
  2. 2 2
      examples/common/camera.cpp
  3. 1 1
      examples/common/imgui/imgui.cpp

+ 1 - 1
examples/common/bounds.cpp

@@ -157,7 +157,7 @@ void calcObb(Obb& _obb, const void* _vertices, uint32_t _numVertices, uint32_t _
 	Obb best;
 	aabbToObb(best, aabb);
 
-	float angleStep = float(M_PI_2/_steps);
+	float angleStep = float(bx::piHalf/_steps);
 	float ax = 0.0f;
 	float mtx[16];
 

+ 2 - 2
examples/common/camera.cpp

@@ -141,9 +141,9 @@ struct Camera
 
 		float right[3] =
 		{
-			sinf(m_horizontalAngle - float(M_PI)/2.0f),
+			sinf(m_horizontalAngle - bx::piHalf),
 			0,
-			cosf(m_horizontalAngle - float(M_PI)/2.0f),
+			cosf(m_horizontalAngle - bx::piHalf),
 		};
 
 		if (m_keys & CAMERA_KEY_UP)

+ 1 - 1
examples/common/imgui/imgui.cpp

@@ -448,7 +448,7 @@ struct Imgui
 
 		for (int32_t ii = 0; ii < NUM_CIRCLE_VERTS; ++ii)
 		{
-			float a = (float)ii / (float)NUM_CIRCLE_VERTS * (float)(M_PI * 2.0);
+			float a = (float)ii / (float)NUM_CIRCLE_VERTS * (float)(bx::pi * 2.0);
 			m_circleVerts[ii * 2 + 0] = cosf(a);
 			m_circleVerts[ii * 2 + 1] = sinf(a);
 		}