compatibility with winXP. .bmp loader now handles 32-bit images and more modern headers.

This commit is contained in:
tmj-fstate
2017-01-30 23:21:00 +01:00
parent 3c0edb3ec3
commit 61440c4969
7 changed files with 51 additions and 35 deletions

View File

@@ -70,7 +70,11 @@ double GetFPS()
void ResetTimers()
{
// double CurrentTime=
#if _WIN32_WINNT >= _WIN32_WINNT_VISTA
::GetTickCount64();
#else
::GetTickCount();
#endif
DeltaTime = 0.1;
DeltaRenderTime = 0;
fSoundTimer = 0;
@@ -102,7 +106,11 @@ void UpdateTimers(bool pause)
oldCount = count;
// Keep track of the time lapse and frame count
#if _WIN32_WINNT >= _WIN32_WINNT_VISTA
double fTime = ::GetTickCount64() * 0.001f; // Get current time in seconds
#else
double fTime = ::GetTickCount() * 0.001f; // Get current time in seconds
#endif
++dwFrames; // licznik ramek
// update the frame rate once per second
if (fTime - fLastTime > 1.0f)