Browse Source

Disable frame limiter Sleep() on Emscripten builds. Closes #915.

Lasse Öörni 10 years ago
parent
commit
7b9692cbfb
1 changed files with 2 additions and 0 deletions
  1. 2 0
      Source/Urho3D/Engine/Engine.cpp

+ 2 - 0
Source/Urho3D/Engine/Engine.cpp

@@ -680,6 +680,7 @@ void Engine::ApplyFrameLimit()
 
 
     long long elapsed = 0;
     long long elapsed = 0;
 
 
+#ifndef EMSCRIPTEN
     // Perform waiting loop if maximum FPS set
     // Perform waiting loop if maximum FPS set
     if (maxFps)
     if (maxFps)
     {
     {
@@ -701,6 +702,7 @@ void Engine::ApplyFrameLimit()
             }
             }
         }
         }
     }
     }
+#endif
 
 
     elapsed = frameTimer_.GetUSec(true);
     elapsed = frameTimer_.GetUSec(true);
 #ifdef URHO3D_TESTING
 #ifdef URHO3D_TESTING