diff options
Diffstat (limited to 'src/citra')
-rw-r--r-- | src/citra/citra.cpp | 4 | ||||
-rw-r--r-- | src/citra/config.cpp | 8 | ||||
-rw-r--r-- | src/citra/default_ini.h | 7 | ||||
-rw-r--r-- | src/citra/emu_window/emu_window_glfw.cpp | 4 |
4 files changed, 19 insertions, 4 deletions
diff --git a/src/citra/citra.cpp b/src/citra/citra.cpp index 2c6ced920..1d7e7f270 100644 --- a/src/citra/citra.cpp +++ b/src/citra/citra.cpp @@ -4,7 +4,7 @@ #include <thread> -#include "common/common.h" +#include "common/logging/log.h" #include "common/logging/text_formatter.h" #include "common/logging/backend.h" #include "common/logging/filter.h" @@ -19,7 +19,7 @@ #include "citra/emu_window/emu_window_glfw.h" /// Application entry point -int __cdecl main(int argc, char **argv) { +int main(int argc, char **argv) { std::shared_ptr<Log::Logger> logger = Log::InitGlobalLogger(); Log::Filter log_filter(Log::Level::Debug); Log::SetFilter(&log_filter); diff --git a/src/citra/config.cpp b/src/citra/config.cpp index e9f3dfd5b..ab564559d 100644 --- a/src/citra/config.cpp +++ b/src/citra/config.cpp @@ -5,7 +5,10 @@ #include <GLFW/glfw3.h> #include "citra/default_ini.h" + #include "common/file_util.h" +#include "common/logging/log.h" + #include "core/settings.h" #include "core/core.h" @@ -66,6 +69,11 @@ void Config::ReadValues() { Settings::values.gpu_refresh_rate = glfw_config->GetInteger("Core", "gpu_refresh_rate", 30); Settings::values.frame_skip = glfw_config->GetInteger("Core", "frame_skip", 0); + // Renderer + Settings::values.bg_red = (float)glfw_config->GetReal("Renderer", "bg_red", 1.0); + Settings::values.bg_green = (float)glfw_config->GetReal("Renderer", "bg_green", 1.0); + Settings::values.bg_blue = (float)glfw_config->GetReal("Renderer", "bg_blue", 1.0); + // Data Storage Settings::values.use_virtual_sd = glfw_config->GetBoolean("Data Storage", "use_virtual_sd", true); diff --git a/src/citra/default_ini.h b/src/citra/default_ini.h index fc02a3ceb..1dd971926 100644 --- a/src/citra/default_ini.h +++ b/src/citra/default_ini.h @@ -41,6 +41,13 @@ gpu_refresh_rate = # 0 (default): No frameskip, 1: x2 frameskip, 2: x4 frameskip, 3: x8 frameskip, etc. frame_skip = +[Renderer] +# The clear color for the renderer. What shows up on the sides of the bottom screen. +# Must be in range of 0.0-1.0. Defaults to 1.0 for all. +bg_red = +bg_blue = +bg_green = + [Data Storage] # Whether to create a virtual SD card. # 1 (default): Yes, 0: No diff --git a/src/citra/emu_window/emu_window_glfw.cpp b/src/citra/emu_window/emu_window_glfw.cpp index 997e3bc7d..341b48d2a 100644 --- a/src/citra/emu_window/emu_window_glfw.cpp +++ b/src/citra/emu_window/emu_window_glfw.cpp @@ -4,7 +4,7 @@ #include <GLFW/glfw3.h> -#include "common/common.h" +#include "common/logging/log.h" #include "video_core/video_core.h" @@ -31,7 +31,7 @@ void EmuWindow_GLFW::OnMouseButtonEvent(GLFWwindow* win, int button, int action, } void EmuWindow_GLFW::OnCursorPosEvent(GLFWwindow* win, double x, double y) { - GetEmuWindow(win)->TouchMoved(static_cast<unsigned>(x), static_cast<unsigned>(y)); + GetEmuWindow(win)->TouchMoved(static_cast<unsigned>(std::max(x, 0.0)), static_cast<unsigned>(std::max(y, 0.0))); } /// Called by GLFW when a key event occurs |