Sign in to follow this  

speed

This topic is 3124 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

i really enjoy learning open gl through this amazing tutorial and i get along with it really great. theres just one problem. the programs run much to fast. is there a general way to reduce speed? i think its not the best way just reducing rotation-values, right? thank you in advance, jerg

Share this post


Link to post
Share on other sites
You should update your rotation using Delta time. You need a function to return the time elapsed since the last frame, and use it something like:

Rotation += 0.1f * GetDeltaTime();


That will give you a constant rotation speed regardless of the FPS.

Share this post


Link to post
Share on other sites
thank you for your quick answer. this idea sounds great.
eeehm, my skills just aint good enough to implement it, though i tried doing it on my own, after i found some information about getdeltatime().

could someone please be so kind to modify lesson 9's source?

Share this post


Link to post
Share on other sites
I'm still working on completely new lessons and there everything will take account of the elapsed time. Thus I hope I'll finish the lessons in the next time and show how to do time based animations.

Share this post


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