SFML community forums
General => General discussions => Topic started by: on August 11, 2008, 08:33:08 am
-
Going through all the tutorials on the SFML website, every single one of them make the CPU spike to 100% when running. Why is this?
FYI: So does SDL!
-
intel pentium 1
150 mhz?
-
If you don't limit your CPU usage, it will try to execute as fast as possible.
Try sf::Window::SetFramerateLimit() or sf::Sleep().
-
int main()
{
while(1) { }
return 0;
}
this code will also make your CPU spike at 100% (if you have a single core)
-
SetFramerateLimit works perfectly, I think.
Thanks a bunch!
-
Add the [Solved] tag to your thread's name.