mirror of
https://github.com/overte-org/overte.git
synced 2025-07-04 17:29:30 +02:00
Fix ignored return value warning
warning: ignoring return value of ‘std::lock_guard<_Mutex>::lock_guard(mutex_type&) [with _Mutex = std::mutex; mutex_type = std::mutex]’, declared with attribute ‘nodiscard’ [-Wunused-result] This may mean the lock wasn't actually being taken.
This commit is contained in:
parent
9cb35541d3
commit
84b16f44aa
1 changed files with 12 additions and 12 deletions
|
@ -64,7 +64,7 @@ void LODManager::setRenderTimes(float presentTime, float engineRunTime, float ba
|
||||||
}
|
}
|
||||||
|
|
||||||
void LODManager::autoAdjustLOD(float realTimeDelta) {
|
void LODManager::autoAdjustLOD(float realTimeDelta) {
|
||||||
std::lock_guard<std::mutex> { _automaticLODLock };
|
std::lock_guard<std::mutex> lock{ _automaticLODLock };
|
||||||
|
|
||||||
// The "render time" is the worse of:
|
// The "render time" is the worse of:
|
||||||
// - engineRunTime: Time spent in the render thread in the engine producing the gpu::Frame N
|
// - engineRunTime: Time spent in the render thread in the engine producing the gpu::Frame N
|
||||||
|
@ -300,7 +300,7 @@ void LODManager::resetLODAdjust() {
|
||||||
}
|
}
|
||||||
|
|
||||||
void LODManager::setAutomaticLODAdjust(bool value) {
|
void LODManager::setAutomaticLODAdjust(bool value) {
|
||||||
std::lock_guard<std::mutex> { _automaticLODLock };
|
std::lock_guard<std::mutex> lock{ _automaticLODLock };
|
||||||
_automaticLODAdjust = value;
|
_automaticLODAdjust = value;
|
||||||
saveSettings();
|
saveSettings();
|
||||||
emit autoLODChanged();
|
emit autoLODChanged();
|
||||||
|
|
Loading…
Reference in a new issue