Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Discussion / erm, how to find the average frames per sec...

Author
Message
dragon tail
21
Years of Service
User Offline
Joined: 23rd Jul 2003
Location: United Kingdom
Posted: 29th Feb 2004 20:08
alright, i know

gives you the FPS, but that is only one second. How do you find the value for the average FPS? I think i seen this in the snowball fighting game...

Current Rig:
P4 2.4GHz | 512MB DDR333 RAM | 80GB BarracudaIV | Geforce4 Ti4600 128MB | XP pro SP1
please help the newb
BearCDPOLD
21
Years of Service
User Offline
Joined: 16th Oct 2003
Location: AZ,USA
Posted: 29th Feb 2004 20:12
Create an array called Recorded_FPS(10) or something. Every X seconds check the fps, and put it in a new slot in this array. Then just use your basic math skills to find the mean.

Crazy Donut Productions
Current Project: KillZone
dragon tail
21
Years of Service
User Offline
Joined: 23rd Jul 2003
Location: United Kingdom
Posted: 29th Feb 2004 21:22
cheers for the info . I have the following:

but any ideas how to add up all the figures inside the array? sorry, i know its a newbish question , but i have consulted the help and tutorials in DBC to find nothing useful ... very grateful for any help

Current Rig:
P4 2.4GHz | 512MB DDR333 RAM | 80GB BarracudaIV | Geforce4 Ti4600 128MB | XP pro SP1
please help the newb
MaTt0344
21
Years of Service
User Offline
Joined: 6th Jan 2004
Location:
Posted: 29th Feb 2004 22:19
you could try something like:

sum=0
for x=1 to 100
sum=sum+fpsarray(x)
next x

to add up the numbers then divide sum by 100

I think that would work but im kinda new so if it doesn't work sorry.

Login to post a reply

Server time is: 2025-05-22 16:17:07
Your offset time is: 2025-05-22 16:17:07