mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Refactor profiler and related classes
This commit is contained in:
parent
5a07f5a652
commit
72eeb9fecb
7 changed files with 133 additions and 132 deletions
|
@ -1132,9 +1132,11 @@ void Game::run()
|
|||
FpsControl draw_times;
|
||||
f32 dtime; // in seconds
|
||||
|
||||
/* Clear the profiler */
|
||||
Profiler::GraphValues dummyvalues;
|
||||
g_profiler->graphGet(dummyvalues);
|
||||
// Clear the profiler
|
||||
{
|
||||
Profiler::GraphValues dummyvalues;
|
||||
g_profiler->graphPop(dummyvalues);
|
||||
}
|
||||
|
||||
draw_times.reset();
|
||||
|
||||
|
@ -4229,7 +4231,7 @@ void Game::updateClouds(float dtime)
|
|||
inline void Game::updateProfilerGraphs(ProfilerGraph *graph)
|
||||
{
|
||||
Profiler::GraphValues values;
|
||||
g_profiler->graphGet(values);
|
||||
g_profiler->graphPop(values);
|
||||
graph->put(values);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue