| 1234567891011121314151617181920212223242526272829303132 |
- $#include "Timer.h"
- /// Low-resolution operating system timer.
- class Timer
- {
- public:
- /// Construct. Get the starting clock value.
- Timer();
-
- /// Return elapsed milliseconds and optionally reset.
- unsigned GetMSec(bool reset);
-
- /// Reset the timer.
- void Reset();
- };
- /// %Time and frame counter subsystem.
- class Time : public Object
- {
- public:
- /// Return frame number, starting from 1 once BeginFrame() is called for the first time.
- unsigned GetFrameNumber() const;
-
- /// Return current frame timestep as seconds.
- float GetTimeStep() const;
-
- /// Return current low-resolution timer period in milliseconds.
- unsigned GetTimerPeriod();
-
- /// Return elapsed time from program start as seconds.
- float GetElapsedTime();
- };
|