mirror of
https://github.com/shadowfacts/lwjgl2-arm64.git
synced 2026-04-07 07:24:20 +00:00
duh
This commit is contained in:
parent
2c39ddfd0b
commit
88ff0562a8
1 changed files with 1 additions and 1 deletions
|
|
@ -237,7 +237,7 @@ public final class Display {
|
|||
public static void sync(int fps) {
|
||||
float frameTime = 1.0f / (float) fps;
|
||||
timeNow = Sys.getTime();
|
||||
while (timeNow > timeThen && (float) (timeNow - timeThen) / (float) Sys.getTimerResolution() < frameRate) {
|
||||
while (timeNow > timeThen && (float) (timeNow - timeThen) / (float) Sys.getTimerResolution() < frameTime) {
|
||||
// This is a system-friendly way of allowing other stuff to use CPU if it wants to
|
||||
Thread.yield();
|
||||
timeNow = Sys.getTime();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue