Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.


OpenGL Displaying FPS in opengl

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

How can I display the frames per second using opengl? Anyone got a quick code sample?

Share this post

Link to post
Share on other sites
Hey Josh,

You could try using Bitmap Font display lists, which means generating some display lists which draw characters based on a Windows bitmap font. It is simpler than it sounds, and its handy for slapping stuff like framerate, contents of parameters, etc on the screen
You could just use a subset that only has numbers in it if you wanted. Check out NeHe''s tutorials on how to do it (there''s a link to his site on the GD main page... I can''t remember the address off the top of my head).

The other (horrendous) alternative is to log frame counts to a text file and read it after running the program... VOMIT

squirrels are a remarkable source of protein...

Share this post

Link to post
Share on other sites

  • 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!