Sign in to follow this  
CarlJ

average fps

Recommended Posts

Hi, I'm wondering how i would work out the average, lowest and highest fps. I've already got the fps (say 100) so whats the algorithm to work those stuff out? Thanks

Share this post


Link to post
Share on other sites
simply said:

if (CurrentFPS > HighestFPS) HighestFPS = CurrentFPS;
if (CurrentFPS < LowestFPS) LowestFPS = CurrentFPS;

the average FPS is a bit different, depending on how you want to have the average... Average of all frame, last 10 frames, last 2 frames, etc.
for all frames is easy:
TotalFPS = TotalFPS + CurrentFPS;
TotalFrames = TotalFrames + 1;
AverageFPS = TotalFPS / TotalFrames;

as you can see it is fairly simple

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this