With just getting a gl context and not much else, not drawing anything whatsoever my cpu usage jumps right to a whopping 50%, this sounds ridiculously high and I’m wondering just how much cpu should a gl context on windows take?
I’m on a laptop pc with ati fireGL v5250
OpenGL Version 18.104.22.16879
Hi, I don’t know, I can take any simple gl example(like one of the first lessons from NeHe) and it will hover around 50% cpu use no matter what(there’s no apps running in the bg btw)… I’m actually comforted by the fact that this could be limited to only this laptop config but still has anyone one else ran into this problem with their laptop/ati hardware?
sorry, yea I listened but I figured that if had vsync enabled that this problem shouldn’t persist and even with it on I still have this problem(which makes me wonder if it’s really enabled or not) and yes I stuck in a ‘Sleep(10)’ and down she went to 10-20%, obviously I’m not getting vsync right? maybe its a default setting in the driver. does this seem like a good solution to just keep the Sleep() in there? It doesn’t seem I can count on setting vsync even though i test for it and it is changeable.
Some drivers do busy loops internally for vsync (it is pretty stupid).
Best way to check if you really have vsync on, is to measure FPS : if it is linked to the display refresh then you have vsync. For a simple triangle scene, you may have hundreds+ FPS without vsync.
It sounds like you may not be getting an accelerated pixel format. Check to make sure your pixel format doesn’t have the PFD_GENERIC_FORMAT set and that your color depth is the same as your desktop color depth.
If you’ve updated drivers (or haven’t updated your drivers) recently, your drivers may not be installed correctly. Laptops are the worst in terms of gettings drivers to install correctly.
@Bucky, this is just the way it works. Even if you run an empty loop, there is no way the OS can tell it isn’t doing any meaningfull job. Basically, it tries to give as much as possible CPU time to your application, and since it (the application) doesn’t signal “I don’t need so much time”, it ends up eating all of it, resulting in a CPU usage of 100%. If you want to reduce the CPU usage, you will have to incorporate some means to tell the OS that you don’t need so much time. One possibility is to use the sleep() function.