diff --git a/src/SFML/Main/MainWin32.cpp b/src/SFML/Main/MainWin32.cpp index c9f287367..29e7133f8 100644 --- a/src/SFML/Main/MainWin32.cpp +++ b/src/SFML/Main/MainWin32.cpp @@ -41,6 +41,13 @@ #include +// Inform the Nvidia/AMD driver that this SFML application could +// benefit from using the more powerful discrete GPU +extern "C" +{ +__declspec(dllexport) DWORD NvOptimusEnablement = 0x00000001; +__declspec(dllexport) int AmdPowerXpressRequestHighPerformance = 1; +} extern int main(int argc, char* argv[]);