Jump to content

  • Log In with Google      Sign In   
  • Create Account

Frame rate handling


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
2 replies to this topic

#1 halileohalilei   Members   -  Reputation: 170

Like
0Likes
Like

Posted 09 February 2013 - 12:41 PM

Hello everyone,

 

I'm trying to write a simple game engine using SDL, but I have problems understanding the basics of the FPS concept. I've already read some tutorials on this but I still seem to be lost. Can anyone explain really simply to me how frame rate handling works?

 

Thank you all in advance.



Sponsor:

#2 ultramailman   Prime Members   -  Reputation: 1585

Like
2Likes
Like

Posted 09 February 2013 - 01:00 PM

Let's say we want 60 fps. 60 fps means 60 frames per 1000 milliseconds. That's around 16 or 17 milliseconds of time to update and render. If updating and rendering takes less than 16 milliseconds, then wait the remaining time to keep fps near 60.

Thats the gist of it. For further reading, check out an article called "Fix your Timestep!". It's more advanced, but don't let it confuse you.

#3 irreversible   Crossbones+   -  Reputation: 1403

Like
0Likes
Like

Posted 09 February 2013 - 08:54 PM

Here's the "definitive" tutorial to go by: fixing your timestep.






Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS