RE: [Algorithms] Game loop timings
Brought to you by:
vexxed72
From: Chuck W. <ch...@wi...> - 2005-03-31 06:37:53
|
Fixed-increment timing code is problematic on the PC now matter how clever you are about it. Since the performance characteristics of the system will vary widely from system-to-system, and even on the same system from driver-to-driver or due to component upgrades, you are inherently dealing with variable timing. Fixed-increment timing code also breaks when you are doing debug vs. release builds, profiling, or have to cope with variability introduced by multi-threading or background processes that the user wants/needs to have active while playing your game. Now, you can certainly set up your AI/physics to run a lower rate than your rendering rate. You can probably get close to constant increments if your resolution is low-enough via multi-media timers, but you will have to be stable enough to deal with the occasional glitch. -Chuck Walbourn SDE, Windows Gaming & Graphics |