MCPcopy Create free account
hub / github.com/OpenXcom/OpenXcom / update

Method update

src/Interface/FpsCounter.cpp:104–110  ·  view source on GitHub ↗

* Updates the amount of Frames per Second. */

Source from the content-addressed store, hash-verified

102 * Updates the amount of Frames per Second.
103 */
104void FpsCounter::update()
105{
106 int fps = (int)floor((double)_frames / _timer->getTime() * 1000);
107 _text->setValue(fps);
108 _frames = 0;
109 _redraw = true;
110}
111
112/**
113 * Draws the FPS counter.

Callers

nothing calls this directly

Calls 2

getTimeMethod · 0.45
setValueMethod · 0.45

Tested by

no test coverage detected