openscenegraph
|
#include <Timer>
Public Member Functions | |
Timer () | |
~Timer () | |
Timer_t | tick () const |
void | setStartTick () |
void | setStartTick (Timer_t t) |
Timer_t | getStartTick () const |
double | time_s () const |
double | time_m () const |
double | time_u () const |
double | time_n () const |
double | delta_s (Timer_t t1, Timer_t t2) const |
double | delta_m (Timer_t t1, Timer_t t2) const |
double | delta_u (Timer_t t1, Timer_t t2) const |
double | delta_n (Timer_t t1, Timer_t t2) const |
double | getSecondsPerTick () const |
Static Public Member Functions | |
static Timer * | instance () |
Protected Attributes | |
Timer_t | _startTick |
double | _secsPerTick |
Timer class is used for measuring elapsed time or time between two points.
osg::Timer::Timer | ( | ) |
|
inline |
Get the time in milliseconds between timer ticks t1 and t2.
Referenced by osg::ElapsedTime::elapsedTime_m().
Get the time in nanoseconds between timer ticks t1 and t2.
Referenced by osg::ElapsedTime::elapsedTime_n().
Get the time in seconds between timer ticks t1 and t2.
Referenced by osg::ElapsedTime::elapsedTime(), osg::ElapsedTime::finish(), osg::State::getGpuTime(), osgGA::EventQueue::getTime(), and osg::GraphicsContext::getTimeSinceLastClear().
Get the time in microseconds between timer ticks t1 and t2.
Referenced by osg::ElapsedTime::elapsedTime_u().
|
inline |
Get the number of seconds per tick.
|
inline |
|
static |
|
inline |
Set the start.
|
inline |
Timer_t osg::Timer::tick | ( | ) | const |
Get the timers tick value.
Referenced by osg::ElapsedTime::elapsedTime(), osg::ElapsedTime::elapsedTime_m(), osg::ElapsedTime::elapsedTime_n(), osg::ElapsedTime::elapsedTime_u(), osg::ElapsedTime::finish(), osg::ElapsedTime::init(), and osg::ElapsedTime::reset().
|
inline |
Get elapsed time in milliseconds.
|
inline |
Get elapsed time in nanoseconds.
|
inline |
Get elapsed time in seconds.
|
inline |
Get elapsed time in microseconds.
|
protected |
|
protected |