[OpenTK] Fix UpdateFrame loop condition

Multiple UpdateFrame events should be raised to match the desired
TargetUpdateFrequency, when TargetUpdateFrequency > 0. The loop would
incorrectly check for TargetRenderFrequency instead.

Affects issue #43
This commit is contained in:
Stefanos A. 2014-01-12 21:37:18 +01:00
parent c31f64f7e1
commit fca9f930e4

View file

@ -457,7 +457,7 @@ namespace OpenTK
break;
}
}
} while (TargetRenderFrequency > 0 && ++frameskip < max_frameskip);
} while (TargetUpdateFrequency > 0 && ++frameskip < max_frameskip);
timestamp = watch.Elapsed.TotalSeconds;
double render_elapsed = MathHelper.Clamp(timestamp - render_timestamp, 0.0, 1.0);