Jump to content
  • Advertisement
Sign in to follow this  
sbayeta

glut performance

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

Hi, I compiled two programs from two different tutorials, one using GLUT and one using win32 windowing, and I noticed that even though they render almost nothing, the GLUT one is very slow when I try to move the window around. The code for the tutorials can be found online: GLUT: http://www.lighthouse3d.com/opengl/glut/index.php?2 Win32: http://nehe.gamedev.net/data/lessons/vc/lesson01.zip Can anyone tell me what's going on? Thanks a lot.

Share this post


Link to post
Share on other sites
Advertisement
it has to do with how or rather when glut draws the frames.
Non glut draws the frames continiously, after each frame it draws another one with no delay.

Glut on the other hand let's windows decide if the window is drawable or have to wait until windows calls a paint refresh call.
IT's ok for the most part, but when you move windows it's not.

Share this post


Link to post
Share on other sites
Thanks a lot for that reply. Is it still advisable (since I read glut development was abandoned) to use glut to create moderate complexity apps?

Share this post


Link to post
Share on other sites
Also make sure you are passing the render function into the glutIdleFunc to make sure it is called during 'Idle' cycles.

As for using it, what are you aiming to make? "Moderate complexity apps" is too broad of a statement to judge at this point. Do you need speed or ease of programming? Do you have to use GLUT, or can you use another 3rd party library that offers OpenGL support?

Share this post


Link to post
Share on other sites
Quote:
Original post by sbayeta
Thanks a lot for that reply. Is it still advisable (since I read glut development was abandoned) to use glut to create moderate complexity apps?


Perhaps not moderate complexity apps, but simple complexity apps, if your spending more than a month on a app you could spend a few hours writing better window management code.

Share this post


Link to post
Share on other sites
I would suggest SDL. It is as easy and straight-forward as GLUT but has high enough performance for anything you want to do. Also no callbacks[smile]

Share this post


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

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!