diff --git a/src/citra/citra.cpp b/src/citra/citra.cpp
index ca93d5b91..ce8d7dd25 100644
--- a/src/citra/citra.cpp
+++ b/src/citra/citra.cpp
@@ -18,6 +18,8 @@
#include "citra/config.h"
#include "citra/emu_window/emu_window_glfw.h"
+#include "video_core/video_core.h"
+
/// Application entry point
int main(int argc, char **argv) {
Log::Filter log_filter(Log::Level::Debug);
@@ -34,6 +36,8 @@ int main(int argc, char **argv) {
std::string boot_filename = argv[1];
EmuWindow_GLFW* emu_window = new EmuWindow_GLFW;
+ VideoCore::g_hw_renderer_enabled = Settings::values.use_hw_renderer;
+
System::Init(emu_window);
Loader::ResultStatus load_result = Loader::LoadFile(boot_filename);
diff --git a/src/citra_qt/main.cpp b/src/citra_qt/main.cpp
index 24506deab..2ea33ebc5 100644
--- a/src/citra_qt/main.cpp
+++ b/src/citra_qt/main.cpp
@@ -44,6 +44,8 @@
#include "core/arm/disassembler/load_symbol_map.h"
#include "citra_qt/config.h"
+#include "video_core/video_core.h"
+
#include "version.h"
GMainWindow::GMainWindow() : emu_thread(nullptr)
@@ -123,6 +125,9 @@ GMainWindow::GMainWindow() : emu_thread(nullptr)
restoreState(settings.value("state").toByteArray());
render_window->restoreGeometry(settings.value("geometryRenderWindow").toByteArray());
+ ui.action_Use_Hardware_Renderer->setChecked(Settings::values.use_hw_renderer);
+ SetHardwareRendererEnabled(ui.action_Use_Hardware_Renderer->isChecked());
+
ui.action_Single_Window_Mode->setChecked(settings.value("singleWindowMode", true).toBool());
ToggleWindowMode();
@@ -135,6 +140,7 @@ GMainWindow::GMainWindow() : emu_thread(nullptr)
connect(ui.action_Start, SIGNAL(triggered()), this, SLOT(OnStartGame()));
connect(ui.action_Pause, SIGNAL(triggered()), this, SLOT(OnPauseGame()));
connect(ui.action_Stop, SIGNAL(triggered()), this, SLOT(OnStopGame()));
+ connect(ui.action_Use_Hardware_Renderer, SIGNAL(triggered(bool)), this, SLOT(SetHardwareRendererEnabled(bool)));
connect(ui.action_Single_Window_Mode, SIGNAL(triggered(bool)), this, SLOT(ToggleWindowMode()));
connect(ui.action_Hotkeys, SIGNAL(triggered()), this, SLOT(OnOpenHotkeysDialog()));
@@ -300,6 +306,9 @@ void GMainWindow::OnOpenHotkeysDialog()
dialog.exec();
}
+void GMainWindow::SetHardwareRendererEnabled(bool enabled) {
+ VideoCore::g_hw_renderer_enabled = enabled;
+}
void GMainWindow::ToggleWindowMode() {
if (ui.action_Single_Window_Mode->isChecked()) {
diff --git a/src/citra_qt/main.h b/src/citra_qt/main.h
index 3e29534fb..242b08c39 100644
--- a/src/citra_qt/main.h
+++ b/src/citra_qt/main.h
@@ -69,6 +69,7 @@ private slots:
void OnOpenHotkeysDialog();
void OnConfigure();
void OnDisplayTitleBars(bool);
+ void SetHardwareRendererEnabled(bool);
void ToggleWindowMode();
private:
diff --git a/src/citra_qt/main.ui b/src/citra_qt/main.ui
index 689806465..0942c28c8 100644
--- a/src/citra_qt/main.ui
+++ b/src/citra_qt/main.ui
@@ -52,6 +52,7 @@
+