mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-07-18 18:09:18 +02:00
change __linux__ to __unix__
This commit is contained in:
@@ -69,7 +69,7 @@ void UpdateTimers(bool pause)
|
||||
#ifdef _WIN32
|
||||
QueryPerformanceFrequency((LARGE_INTEGER *)&fr);
|
||||
QueryPerformanceCounter((LARGE_INTEGER *)&count);
|
||||
#elif __linux__
|
||||
#elif __unix__
|
||||
timespec ts;
|
||||
clock_gettime(CLOCK_MONOTONIC_RAW, &ts);
|
||||
count = (uint64_t)ts.tv_sec * 1000000000 + (uint64_t)ts.tv_nsec;
|
||||
@@ -91,7 +91,7 @@ void UpdateTimers(bool pause)
|
||||
|
||||
oldCount = count;
|
||||
// Keep track of the time lapse and frame count
|
||||
#if __linux__
|
||||
#if __unix__
|
||||
double fTime = (double)(count / 1000000000);
|
||||
#elif _WIN32_WINNT >= _WIN32_WINNT_VISTA
|
||||
double fTime = ::GetTickCount64() * 0.001f; // Get current time in seconds
|
||||
|
||||
Reference in New Issue
Block a user