diff --git a/src/main.cpp b/src/main.cpp index 7e72e9a..b83eafe 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -42,6 +42,14 @@ #ifdef __WINDOWS__ #include "resource.h" + +// Try to force dedicated GPU +// https://stackoverflow.com/a/39047129 +extern "C" +{ + __declspec(dllexport) unsigned long NvOptimusEnablement = 0x00000001; + __declspec(dllexport) int AmdPowerXpressRequestHighPerformance = 1; +} #endif #include "icon.png.xxd"