mirror of
https://github.com/HifiExperiments/overte.git
synced 2025-05-29 10:11:30 +02:00
Fix Interface eating memory when minimized
This commit is contained in:
parent
2dfd63f4e7
commit
1cca975b37
1 changed files with 7 additions and 3 deletions
|
@ -6017,7 +6017,9 @@ void Application::update(float deltaTime) {
|
||||||
{
|
{
|
||||||
PROFILE_RANGE_EX(app, "Overlays", 0xffff0000, (uint64_t)getActiveDisplayPlugin()->presentCount());
|
PROFILE_RANGE_EX(app, "Overlays", 0xffff0000, (uint64_t)getActiveDisplayPlugin()->presentCount());
|
||||||
PerformanceTimer perfTimer("overlays");
|
PerformanceTimer perfTimer("overlays");
|
||||||
_overlays.update(deltaTime);
|
if (qApp->shouldPaint()) {
|
||||||
|
_overlays.update(deltaTime);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Update _viewFrustum with latest camera and view frustum data...
|
// Update _viewFrustum with latest camera and view frustum data...
|
||||||
|
@ -6102,8 +6104,10 @@ void Application::update(float deltaTime) {
|
||||||
PROFILE_RANGE_EX(app, "PostUpdateLambdas", 0xffff0000, (uint64_t)0);
|
PROFILE_RANGE_EX(app, "PostUpdateLambdas", 0xffff0000, (uint64_t)0);
|
||||||
PerformanceTimer perfTimer("postUpdateLambdas");
|
PerformanceTimer perfTimer("postUpdateLambdas");
|
||||||
std::unique_lock<std::mutex> guard(_postUpdateLambdasLock);
|
std::unique_lock<std::mutex> guard(_postUpdateLambdasLock);
|
||||||
for (auto& iter : _postUpdateLambdas) {
|
if (qApp->shouldPaint()) {
|
||||||
iter.second();
|
for (auto& iter : _postUpdateLambdas) {
|
||||||
|
iter.second();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
_postUpdateLambdas.clear();
|
_postUpdateLambdas.clear();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue