🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

How do I get a cube to move very slowly? Like a earth rotation?

Started by
2 comments, last by ajm113 17 years, 2 months ago
I am using lesson 6 and I want my cube to move very slowly like a earth rotation. I play around with the xrot+=-0.1f; stuff but it's still too fast. Is there a way to slow it down more? Sorry to be asking questions but I am new to OpenGl and I want to have a bit more small details on this so I can under stand it better. Thanks.
Check out my open source code projects/libraries! My Homepage You may learn something.
Advertisement
The simple solution is to keep adding zeroes until you are satisfied =D The more correct solution would also involve decoupling the rotation increments from the rendering/framerate - at your stage you are probably not ready for this yet, so I wouldn't worry about it too much.
Enabling vsync will also help stabilize (and reduce) the frame rate, if it is not already enabled. This can be done through your video card settings.
Disclaimer: "I am in no way qualified to present advice on any topic concerning anything and can not be held responsible for any damages that my advice may incurr (due to neither my negligence nor yours)"
Thanks! I used this. It mite be alital fast but I think it looks cool.

xrot+=0.0f; // X Axis Rotation
yrot+=0.001f; // Y Axis Rotation
zrot+=-0.0002f; // Z Axis Rotation

Check out my open source code projects/libraries! My Homepage You may learn something.

This topic is closed to new replies.

Advertisement