GLFW/Opengl on laptop with nVidia Optimus

anonymous wrote on Friday, January 18, 2013:

Hi all. I have got Alienware m14x. It has two video adapters, integrated Intel gma 4000 and dedicated Geforce gt 660M. They are working in Nvidia Optimus technology (when more power is needed geforce do the job). I have build some examples of opengl/glfw and noticed that they are using integrated graphic card. When windows has glfwOpenWindowHint(GLFW_OPENGL_PROFILE, GLFW_OPENGL_CORE_PROFILE); application does not start at all. Only when I force my system to run exactly this app with nvidia it works ok.
I played many games on my laptop and all of them choose right video card.
Is there any way to enumerate video adapters and choose which should be used?
Please help:)

elmindreda wrote on Tuesday, March 19, 2013:

The driver autodetects many games and solves it for them. Other applications have to resort to using the NVAPI. GLFW doesn’t yet support NVAPI, but it will at some point.