From dc3dd3263615d772b79077c420a5386042f17dbd Mon Sep 17 00:00:00 2001 From: kotn3l Date: Mon, 19 Aug 2024 17:21:33 +0200 Subject: [PATCH] Set windowed mode size based on config --- src/emulator.cpp | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/emulator.cpp b/src/emulator.cpp index 12e893491..83e09a767 100644 --- a/src/emulator.cpp +++ b/src/emulator.cpp @@ -34,9 +34,6 @@ Frontend::WindowSDL* g_window = nullptr; namespace Core { -static constexpr s32 WindowWidth = 1280; -static constexpr s32 WindowHeight = 720; - Emulator::Emulator() { // Read configuration file. const auto config_dir = Common::FS::GetUserPath(Common::FS::PathType::UserDir); @@ -114,8 +111,9 @@ void Emulator::Run(const std::filesystem::path& file) { window_title = fmt::format("shadPS4 v{} {} | {}", Common::VERSION, Common::g_scm_desc, game_title); } - window = - std::make_unique(WindowWidth, WindowHeight, controller, window_title); + window = std::make_unique( + Config::getScreenWidth(), Config::getScreenHeight(), + controller, window_title); g_window = window.get();