mirror of
https://github.com/skyline-emu/skyline.git
synced 2025-01-30 19:57:55 +03:00
Avoid locking presentation mutex in GetTransformHint
This caused slowdown in Pokemon as it was being called every frame
This commit is contained in:
parent
460e6c9c84
commit
9d50b6d0f7
@ -401,7 +401,11 @@ namespace skyline::gpu {
|
|||||||
}
|
}
|
||||||
|
|
||||||
NativeWindowTransform PresentationEngine::GetTransformHint() {
|
NativeWindowTransform PresentationEngine::GetTransformHint() {
|
||||||
std::unique_lock lock{mutex};
|
if (!vkSurface.has_value()) {
|
||||||
|
std::unique_lock lock{mutex};
|
||||||
|
surfaceCondition.wait(lock, [this]() { return vkSurface.has_value(); });
|
||||||
|
}
|
||||||
|
|
||||||
return GetAndroidTransform(vkSurfaceCapabilities.currentTransform);
|
return GetAndroidTransform(vkSurfaceCapabilities.currentTransform);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user