Hummingbird Framework
|
A class for measuring Time intervals. More...
#include <Clock.h>
Public Member Functions | |
Clock () | |
Class constructor. More... | |
~Clock () | |
Class destructor. More... | |
Time | getElapsedTime () const |
Returns the Time elapsed since creation or last reset. More... | |
Time | reset () |
Restarts the Time counter. More... | |
A class for measuring Time intervals.
hb::Clock::Clock | ( | ) |
Class constructor.
Initializes a new instance of Clock wich starts measuring the time as it is created.
hb::Clock::~Clock | ( | ) |
Class destructor.
Destroys the instance of Clock.
Time hb::Clock::getElapsedTime | ( | ) | const |
Time hb::Clock::reset | ( | ) |
Restarts the Time counter.
This function also returns the time elapsed up to its reset. This is usefull for getting precise delta times without having time overhead for having to call two methods: