#include <xrb_frameratecalculator.hpp>
Public Member Functions | |
FramerateCalculator (Float time_unit_conversion_ratio=1.0) | |
Constructs a framerate calculator with the given time unit conversion ratio. | |
~FramerateCalculator () | |
Destructor. Boring. | |
void | AddFrameTime (Float frame_time) |
Records the duration of a new frame. | |
Float | Framerate () const |
Calculates and returns the current framerate, multiplied by the time unit conversion ratio. |
The default queue size is 32, providing a more or less instantaneous framerate (unless frames are being rendered very slowly).
Definition at line 26 of file xrb_frameratecalculator.hpp.
Xrb::FramerateCalculator::FramerateCalculator | ( | Float | time_unit_conversion_ratio = 1.0 |
) |
Constructs a framerate calculator with the given time unit conversion ratio.
The time unit conversion ratio is simply multiplied into the calculated framerate before returning it, in Framerate.
Definition at line 16 of file xrb_frameratecalculator.cpp.