OGRE  1.10.12
Object-Oriented Graphics Rendering Engine
Ogre::Timer Class Reference

Timer class. More...

#include <OgreTimerImp.h>

+ Inheritance diagram for Ogre::Timer:

Public Member Functions

 Timer ()
 
 Timer ()
 
 Timer ()
 Timer constructor. More...
 
 ~Timer ()
 
 ~Timer ()
 
 ~Timer ()
 
unsigned long getMicroseconds ()
 Returns microseconds since initialisation or last reset. More...
 
unsigned long getMicroseconds ()
 Returns microseconds since initialisation or last reset. More...
 
unsigned long getMicroseconds ()
 Returns microseconds since initialisation or last reset. More...
 
unsigned long getMicrosecondsCPU ()
 Returns microseconds since initialisation or last reset, only CPU time measured. More...
 
unsigned long getMicrosecondsCPU ()
 Returns microseconds since initialisation or last reset, only CPU time measured. More...
 
unsigned long getMicrosecondsCPU ()
 Returns microseconds since initialisation or last reset, only CPU time measured. More...
 
unsigned long getMilliseconds ()
 Returns milliseconds since initialisation or last reset. More...
 
unsigned long getMilliseconds ()
 Returns milliseconds since initialisation or last reset. More...
 
unsigned long getMilliseconds ()
 Returns milliseconds since initialisation or last reset. More...
 
unsigned long getMillisecondsCPU ()
 Returns milliseconds since initialisation or last reset, only CPU time measured. More...
 
unsigned long getMillisecondsCPU ()
 Returns milliseconds since initialisation or last reset, only CPU time measured. More...
 
unsigned long getMillisecondsCPU ()
 Returns milliseconds since initialisation or last reset, only CPU time measured. More...
 
void reset ()
 Resets timer. More...
 
void reset ()
 Resets timer. More...
 
void reset ()
 Resets timer. More...
 
bool setOption (const String &strKey, const void *pValue)
 Method for setting a specific option of the Timer. More...
 
bool setOption (const String &strKey, const void *pValue)
 Method for setting a specific option of the Timer. More...
 
bool setOption (const String &strKey, const void *pValue)
 Method for setting a specific option of the Timer. More...
 

Detailed Description

Timer class.

Constructor & Destructor Documentation

◆ Timer() [1/3]

Ogre::Timer::Timer ( )

◆ ~Timer() [1/3]

Ogre::Timer::~Timer ( )

◆ Timer() [2/3]

Ogre::Timer::Timer ( )

◆ ~Timer() [2/3]

Ogre::Timer::~Timer ( )

◆ Timer() [3/3]

Ogre::Timer::Timer ( )

Timer constructor.

MUST be called on same thread that calls getMilliseconds()

◆ ~Timer() [3/3]

Ogre::Timer::~Timer ( )

Member Function Documentation

◆ setOption() [1/3]

bool Ogre::Timer::setOption ( const String strKey,
const void *  pValue 
)
inline

Method for setting a specific option of the Timer.

These options are usually specific for a certain implementation of the Timer class, and may (and probably will) not exist across different implementations. reset() must be called after all setOption() calls.

Parameters
strKeyThe name of the option to set
pValueA pointer to the value - the size should be calculated by the timer based on the key
Returns
On success, true is returned.
On failure, false is returned.

◆ reset() [1/3]

void Ogre::Timer::reset ( )

Resets timer.

◆ getMilliseconds() [1/3]

unsigned long Ogre::Timer::getMilliseconds ( )

Returns milliseconds since initialisation or last reset.

◆ getMicroseconds() [1/3]

unsigned long Ogre::Timer::getMicroseconds ( )

Returns microseconds since initialisation or last reset.

◆ getMillisecondsCPU() [1/3]

unsigned long Ogre::Timer::getMillisecondsCPU ( )

Returns milliseconds since initialisation or last reset, only CPU time measured.

◆ getMicrosecondsCPU() [1/3]

unsigned long Ogre::Timer::getMicrosecondsCPU ( )

Returns microseconds since initialisation or last reset, only CPU time measured.

◆ setOption() [2/3]

bool Ogre::Timer::setOption ( const String strKey,
const void *  pValue 
)
inline

Method for setting a specific option of the Timer.

These options are usually specific for a certain implementation of the Timer class, and may (and probably will) not exist across different implementations. reset() must be called after all setOption() calls.

Parameters
strKeyThe name of the option to set
pValueA pointer to the value - the size should be calculated by the timer based on the key
Returns
On success, true is returned.
On failure, false is returned.

◆ reset() [2/3]

void Ogre::Timer::reset ( )

Resets timer.

◆ getMilliseconds() [2/3]

unsigned long Ogre::Timer::getMilliseconds ( )

Returns milliseconds since initialisation or last reset.

◆ getMicroseconds() [2/3]

unsigned long Ogre::Timer::getMicroseconds ( )

Returns microseconds since initialisation or last reset.

◆ getMillisecondsCPU() [2/3]

unsigned long Ogre::Timer::getMillisecondsCPU ( )

Returns milliseconds since initialisation or last reset, only CPU time measured.

◆ getMicrosecondsCPU() [2/3]

unsigned long Ogre::Timer::getMicrosecondsCPU ( )

Returns microseconds since initialisation or last reset, only CPU time measured.

◆ setOption() [3/3]

bool Ogre::Timer::setOption ( const String strKey,
const void *  pValue 
)

Method for setting a specific option of the Timer.

These options are usually specific for a certain implementation of the Timer class, and may (and probably will) not exist across different implementations. reset() must be called after all setOption() calls.

Current options supported are:
  • "QueryAffinityMask" (DWORD): Set the thread affinity mask to be used to check the timer. If 'reset' has been called already this mask should overlap with the process mask that was in force at that point, and should be a power of two (a single core).
Parameters
strKeyThe name of the option to set
pValueA pointer to the value - the size should be calculated by the timer based on the key
Returns
On success, true is returned.
On failure, false is returned.

◆ reset() [3/3]

void Ogre::Timer::reset ( )

Resets timer.

◆ getMilliseconds() [3/3]

unsigned long Ogre::Timer::getMilliseconds ( )

Returns milliseconds since initialisation or last reset.

◆ getMicroseconds() [3/3]

unsigned long Ogre::Timer::getMicroseconds ( )

Returns microseconds since initialisation or last reset.

◆ getMillisecondsCPU() [3/3]

unsigned long Ogre::Timer::getMillisecondsCPU ( )

Returns milliseconds since initialisation or last reset, only CPU time measured.

◆ getMicrosecondsCPU() [3/3]

unsigned long Ogre::Timer::getMicrosecondsCPU ( )

Returns microseconds since initialisation or last reset, only CPU time measured.


The documentation for this class was generated from the following files: