Stop watch is a class for measuring time. More...
#include <kanzi/core/time/stop_watch.hpp>
Public Member Functions | |
chrono::nanoseconds | getDeltaTime () |
Returns the number of nanoseconds since the last call to getDeltaTime(), or the number of nanoseconds since the StopWatch was constructed if this is the first call to getDeltaTime(). More... | |
chrono::nanoseconds | peekDeltaTime () const |
Returns the number of nanoseconds since the last call to getDeltaTime(), or the number of nanoseconds since the StopWatch was constructed if getDeltaTime() has not been called. More... | |
StopWatch () | |
Constructor. More... | |
Protected Attributes | |
TimePoint | m_previousTime |
Time during last update. More... | |
Stop watch is a class for measuring time.
kanzi::StopWatch::StopWatch | ( | ) |
Constructor.
chrono::nanoseconds kanzi::StopWatch::getDeltaTime | ( | ) |
Returns the number of nanoseconds since the last call to getDeltaTime(), or the number of nanoseconds since the StopWatch was constructed if this is the first call to getDeltaTime().
chrono::nanoseconds kanzi::StopWatch::peekDeltaTime | ( | ) | const |
Returns the number of nanoseconds since the last call to getDeltaTime(), or the number of nanoseconds since the StopWatch was constructed if getDeltaTime() has not been called.
|
protected |
Time during last update.