View Full Version : FPS?
10-15-2000, 09:40 AM
Anyone know an good code for showing the FPS in OpenGL??
I've an old and bad code I wrote for DirectX but it only shows
the FPS divideable with five (5, 10, 15 and so on)
Please help me
/ Markus Svensson
If you're using very accurate timer functions, you can get reasonably good results by measuring the time taken to render each frame, then taking its reciprocal.
The way Quake 3 does it is by measuring the time taken to render each of the last 4 frames, then averaging them together. The reason for doing this is so that the numbers are smoothed out a bit over time.
any of the games on me site have got code or u might wanna have a look at the winswapinterval extension code this only works for windows though obviously http://members.xoom.com/myBollux
Powered by vBulletin® Version 4.2.3 Copyright © 2017 vBulletin Solutions, Inc. All rights reserved.