Fix initial FPS display.
This commit is contained in:
parent
3b5eedeab5
commit
d8a4bb6d12
|
@ -38,13 +38,6 @@ bool gfx_get_fps(char *buf, size_t size, bool always_write)
|
|||
(MEASURE_FRAME_TIME_SAMPLES_COUNT - 1);
|
||||
g_extern.measure_data.frame_time_samples[write_index] = new_time - fps_time;
|
||||
fps_time = new_time;
|
||||
}
|
||||
else
|
||||
{
|
||||
time = fps_time = new_time;
|
||||
snprintf(buf, size, "%s", g_extern.title_buf);
|
||||
ret = true;
|
||||
}
|
||||
|
||||
if ((g_extern.frame_count % FPS_UPDATE_INTERVAL) == 0)
|
||||
{
|
||||
|
@ -66,6 +59,13 @@ bool gfx_get_fps(char *buf, size_t size, bool always_write)
|
|||
snprintf(buf, size, "%s || FPS: %6.1f || Frames: %d", g_extern.title_buf, last_fps, g_extern.frame_count);
|
||||
#endif
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
time = fps_time = new_time;
|
||||
snprintf(buf, size, "%s", g_extern.title_buf);
|
||||
ret = true;
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue