class
RTimerA timer component. Allows marking timepoints at runtime. Allows frame counting.
Contents
Base classes
- class Rubeus::RMasterComponent
- A master component. Serves as parent class for all components.
Constructors, destructors, conversion operators
Public functions
- auto getRelativeTime(int sinceThisSlotIndex, int tillThisSlotIndex) -> long long int
- Gets relative time between two timepoints, referred to by their indices.
- void addTimePoint(int index)
- Adds a time point at specified index.
- void setFrameCounter()
- Sets the frame counter. Use just before game loop.
- void evaluateFrames()
- Evaluate frames. Use at the end of game loop.
Function documentation
Rubeus:: UtilityComponents:: RTimer:: RTimer(int numberOfTimePoints)
Constructor.
Parameters | |
---|---|
numberOfTimePoints | Number of time points required. |
long long int Rubeus:: UtilityComponents:: RTimer:: getRelativeTime(int sinceThisSlotIndex,
int tillThisSlotIndex)
Gets relative time between two timepoints, referred to by their indices.
Parameters | |
---|---|
sinceThisSlotIndex | Zero-based index of the timepoint at this slot number, to calculate time duration from. |
tillThisSlotIndex | Zero-based index of the timepoint at this slot number, to calculate time duration till. |
Returns | The relative time. |
void Rubeus:: UtilityComponents:: RTimer:: addTimePoint(int index)
Adds a time point at specified index.
Parameters | |
---|---|
index | Zero-based index of the timepoint. |