Updated box2d from 2.2.1 to 2.3.0

--HG--
branch : box2d-2.3
This commit is contained in:
Alex Szpakowski
2013-11-09 04:30:36 -04:00
parent 5179ca5655
commit 5e3a0fbc6e
86 changed files with 1590 additions and 430 deletions
+3 -2
View File
@@ -22,6 +22,7 @@
float64 b2Timer::s_invFrequency = 0.0f;
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
b2Timer::b2Timer()
@@ -72,14 +73,14 @@ void b2Timer::Reset()
timeval t;
gettimeofday(&t, 0);
m_start_sec = t.tv_sec;
m_start_msec = t.tv_usec * 0.001f;
m_start_usec = t.tv_usec;
}
float32 b2Timer::GetMilliseconds() const
{
timeval t;
gettimeofday(&t, 0);
return (t.tv_sec - m_start_sec) * 1000 + t.tv_usec * 0.001f - m_start_msec;
return 1000.0f * (t.tv_sec - m_start_sec) + 0.001f * (t.tv_usec - m_start_usec);
}
#else