mirror of
https://github.com/overte-org/overte.git
synced 2025-04-20 18:23:54 +02:00
changed 2000 into a constant defined inline
This commit is contained in:
parent
8c700d43f3
commit
d08b63b247
1 changed files with 2 additions and 1 deletions
|
@ -416,8 +416,9 @@ void printVoxelCode(unsigned char* voxelCode) {
|
|||
|
||||
#ifdef _WIN32
|
||||
void usleep(int waitTime) {
|
||||
const quint64 BUSY_LOOP_USECS = 2000;
|
||||
quint64 compTime = waitTime + usecTimestampNow();
|
||||
quint64 compTimeSleep = compTime - 2000;
|
||||
quint64 compTimeSleep = compTime - BUSY_LOOP_USECS;
|
||||
while (true) {
|
||||
if (usecTimestampNow() < compTimeSleep) {
|
||||
QThread::msleep(1);
|
||||
|
|
Loading…
Reference in a new issue