Jump to content
  • Advertisement
Sign in to follow this  
web383

OpenGL Running your OpenGL program on an Nvidia-Optimus enabled laptop

This topic is 2131 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Running my OpenGL 4.0 programs on my laptop (using nvidia-optimus technology), always defaults to the integrated Intel graphics chip, instead of the dedicated Nvidia GTX 660M that's included. This results in my program failing to initialize because the Intel chip only supports OpenGL 1.4.

Is there anyway to tell the system which graphics card to use without manually setting up a profile for the application? I'd rather not disable optimus altogether, so I can still gain the benefits of power savings while not running high-end applications. How do commercial games handle this?

Share this post


Link to post
Share on other sites
Advertisement
to answer your question with a maybe, no smile.png
this is not something that there is any standard for
anyone that has a double-card laptop needs to change this for themselves
usually with a dedicated keyboard button, or a program that comes with the computer

as for using profiles, i think that is for convinience mostly..
perhaps the most common games out there get a dedicated profile that comes with your drivers

the best source of information i could find:
http://us.download.nvidia.com/XFree86/Linux-x86_64/295.20/README/configlaptop.html Edited by Kaptein

Share this post


Link to post
Share on other sites
Usually, the drivers can tell what's a game or application that is supposed to use the discrete GPU based on the profiles/filenames available at the time the driver was delivered. The drivers weren't released with details of applications you develop, though, so you'll probably need to add your executable to the whitelist. There's a video that walks through the process here.

Note: I haven't tried this process for an app under development, so I'm not sure what happens when the file is being constantly deleted/recreated, but it could handle it well!

Share this post


Link to post
Share on other sites
Adding the application to the whitelist did the trick - even when executing the .exe through the Visual Studio debugger, and after deleting using clean. This solution wil work for me, though it's a shame there isn't a more automatic way of doing this. I guess if you're a big time developer/gamestudio you can just call nvidia and have them release a driver with your app on the whitelist.

Thanks for the help

Share this post


Link to post
Share on other sites
i have a dell XPS502L laptop with an I7 and a nvidia 540m ... i had the same problem with visual studio and opentk ... mysolution: running visual studio by rightclicking the link to open the context menu and choose "Mit Grafikprozessor ausführen" (sry german, "run by graphicsprocessor"?)

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!