From c776d5e003a956ddc0e11d36f99b8b242de941b7 Mon Sep 17 00:00:00 2001 From: Brecht Van Lommel Date: Fri, 28 Jun 2013 17:58:48 +0000 Subject: Fix #35904: on Windows force NVidia Optimus, which does automatic graphics switching between an integrated Intel and a dedicated NVidia card, to use the dedicated card for Blender. A more portable and general solution would be nice, but it's all I could find: http://developer.download.nvidia.com/devzone/devcenter/gamegraphics/files/OptimusRenderingPolicies.pdf --- intern/ghost/intern/GHOST_WindowWin32.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'intern') diff --git a/intern/ghost/intern/GHOST_WindowWin32.cpp b/intern/ghost/intern/GHOST_WindowWin32.cpp index 6d3b34b0785..b0d0b1a5b5d 100644 --- a/intern/ghost/intern/GHOST_WindowWin32.cpp +++ b/intern/ghost/intern/GHOST_WindowWin32.cpp @@ -106,6 +106,11 @@ static int is_crappy_intel_card(void) return is_crappy; } +/* force NVidia Optimus to used dedicated graphics */ +extern "C" { + __declspec(dllexport) DWORD NvOptimusEnablement = 0x00000001; +} + GHOST_WindowWin32::GHOST_WindowWin32( GHOST_SystemWin32 *system, const STR_String& title, -- cgit v1.2.3