aboutsummaryrefslogtreecommitdiff
path: root/src/yuzu/bootmanager.cpp
diff options
context:
space:
mode:
authorlat9nq <22451773+lat9nq@users.noreply.github.com>2023-05-01 20:29:13 -0400
committerlat9nq <22451773+lat9nq@users.noreply.github.com>2023-05-02 21:51:30 -0400
commit3573979d27c29c8d23e9fc98f1dcf46af07d95e2 (patch)
tree1fdb34cd7b74367102a1a91893bd5a3fa4d89fc1 /src/yuzu/bootmanager.cpp
parent17507c484909e91ac5429b2eb23f44ebcb990090 (diff)
bootmanager: Remove inaccurate switch
Those vulkan settings do not correspond 1:1 to the swap intervals that they set for OpenGL, so remove it. bootmanager: Add missing include I didn't add this log why did it break
Diffstat (limited to 'src/yuzu/bootmanager.cpp')
-rw-r--r--src/yuzu/bootmanager.cpp13
1 files changed, 2 insertions, 11 deletions
diff --git a/src/yuzu/bootmanager.cpp b/src/yuzu/bootmanager.cpp
index 98161cc27d..b064c9c644 100644
--- a/src/yuzu/bootmanager.cpp
+++ b/src/yuzu/bootmanager.cpp
@@ -153,17 +153,8 @@ public:
// disable vsync for any shared contexts
auto format = share_context->format();
- const int swap_interval = [&]() {
- switch (Settings::values.vsync_mode.GetValue()) {
- case Settings::VSyncMode::Immediate:
- return 0;
- case Settings::VSyncMode::FIFO:
- return 1;
- case Settings::VSyncMode::Mailbox:
- return 2;
- }
- return 0;
- }();
+ const int swap_interval =
+ Settings::values.vsync_mode.GetValue() == Settings::VSyncMode::Immediate ? 0 : 1;
format.setSwapInterval(main_surface ? swap_interval : 0);