Hi everyone,
I need some help understanding the concept of "duration" used in OpenMW. A lot of the core gameloop functions take duration as a parameter, or read from a duration member variable.
This is to help with the timing of things regardless of frame rate, right?
How might I go about wrapping my head around the concept. How is duration calculated, is it somehow related to frame rate?
What might be a good function to read through that would clarify how duration is used?
Thanks,
Matt
Resources and hints for understanding "duration"?
Re: Resources and hints for understanding "duration"?
The time between the start of running the main loop for the previous frame and the start of running the main loop for the current frame. Quite simple, actually.
The main loop is a good place to start reading code (OMW::Engine::go, while loop marked with // Start the main rendering loop).
The main loop is a good place to start reading code (OMW::Engine::go, while loop marked with // Start the main rendering loop).
Re: Resources and hints for understanding "duration"?
Thanks for the reply, I've been able to get a pretty general grasp on it and have started using it!