I’m on a laptop with NVIDIA Optimus, which means it has both Intel video and an NVIDIA GPU, and it captures the GPU results and sends it to the Intel Video for display.
In an attempt to reduce lag, I’d like to be able to pick which GPU RetroArch tries to use. It defaults to the NVIDIA GPU, but you can open the NVIDIA Control Panel to change the preferred graphics device to Intel graphics. However, the NVIDIA Control Panel is painfully slow to use, with wait times of around 30 seconds with every click.
In Direct3D, you can enumerate the GPUs and pick which one you want to use.
In OpenGL, you can’t really do that directly, but NVIDIA and AMD have made extensions to somewhat allow that. Googling the keywords wglEnumGpusNV, NV_gpu_affinity, and AMD_gpu_association might have the answer for how to implement it.