[Peer Review]: "Milliseconds vs. FPS"

Post your questions, suggestions and experiences regarding game design, integration of external libraries here. For irrEdit, irrXML and irrKlang, see the
ambiera forums
Post Reply
Halifax
Posts: 1424
Joined: Sun Apr 29, 2007 10:40 pm
Location: $9D95

[Peer Review]: "Milliseconds vs. FPS"

Post by Halifax »

Well it appears to be in vogue. :lol: Specifically I'd like some input on an article I wrote: Milliseconds vs. FPS

The best method, so as to receive credit, would be to comment the post. But posting on here is fine as well, I'll try to credit you too. At any rate, I'd like any comments regarding more images, better explanations, etc. (Anything.)

We all know "My game went from 1000 FPS to 500 FPS, what's wrong?" comes up more than a little bit across all forums. :)
TheQuestion = 2B || !2B
Lil Margin
Posts: 212
Joined: Sun Jul 19, 2009 4:24 am
Location: Netherlands Antilles, Curacao

Post by Lil Margin »

I like it, its small and easy to understand :)
Plus i totally agree with you especially on the "100 fps to 150 " fps part.
BlindSide
Admin
Posts: 2821
Joined: Thu Dec 08, 2005 9:09 am
Location: NZ!

Post by BlindSide »

This is most definitely inspired by this post. 8)

Nice article. Oh and nice blog, is it new? You look quite "gangster" in the photo. :P
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
Mel
Competition winner
Posts: 2292
Joined: Wed May 07, 2008 11:40 am
Location: Granada, Spain

Post by Mel »

You got a point there. It is clear, 1 pixel = X time, n pixels = nX time, Simple. I like it :)
"There is nothing truly useless, it always serves as a bad example". Arthur A. Schmitt
cheshirekow
Posts: 105
Joined: Mon Jul 27, 2009 4:06 pm
Location: Cambridge, MA

Post by cheshirekow »

So in your post you say "1/2 FPS = 0.5 s, 1/10 FPS = 0.01 s". I think you mean "2 FPS = 0.5 s, 10 FPS = 0.01 s". The rest of your post is consistent with the actual relationship though.
DeM0nFiRe
Posts: 117
Joined: Thu Oct 16, 2008 11:59 pm

Post by DeM0nFiRe »

Did you perhaps write this article several months ago? I've definitely seen that graph before XD In fact, I have read these exact words before, but when I read them before it also included an explanation of optimizing rendering vs optimizing the game logic :o

Anyway, it's a good article, but I think it assumes that things are going to be an O(n) algorithm. Sometimes there really is a problem and you really might be doing something wrong because sometimes you might be trying to do something very pricey on too many things.
Halifax
Posts: 1424
Joined: Sun Apr 29, 2007 10:40 pm
Location: $9D95

Post by Halifax »

Lil Margin wrote:I like it, its small and easy to understand :)
Plus i totally agree with you especially on the "100 fps to 150 " fps part.
Thanks for the compliment Lil Margin.
BlindSide wrote:This is most definitely inspired by this post. 8)

Nice article. Oh and nice blog, is it new? You look quite "gangster" in the photo. :P
Yeah, it was inspired by that. :lol: That was basically the last straw though, I had to explain it before, so I figured you mine as well not waste your breat and help people more at the same time. And yeah, it's pretty new. And I got basically the same comment from wildrj about my picture. :lol: (It's the hat.)
Mel wrote:You got a point there. It is clear, 1 pixel = X time, n pixels = nX time, Simple. I like it :)
Thanks for the review and support Mel.
cheshirekow wrote:So in your post you say "1/2 FPS = 0.5 s, 1/10 FPS = 0.01 s". I think you mean "2 FPS = 0.5 s, 10 FPS = 0.01 s". The rest of your post is consistent with the actual relationship though.
You're most certainly correct. I actually explained that point on IRC with rooly, good find. I'll include both of you in the credits.
DeM0nFiRe wrote:Did you perhaps write this article several months ago? [... shortened]

Anyway, it's a good article, but I think it assumes that things are going to be an O(n) algorithm. [... shortened]
Nope I wrote it exactly a month ago independently. And that graph is custom-edited from Inkscape :P But yeah, you'd probably see some consistency considering the topic. At any rate, you're correct about my assumption with regard to O(n) algorithms. Any suggestions on how to include information about other types of operations?

By the way, just curious, aren't most graphics algorithms (used in games) O(n) or a variant such as O(k*n). Recently, the only O(n**2) operation I've seen is in the DX10 SDK. I'm just wondering if anyone knows of any other ones, so they could be used as examples.

Also, thanks for all the input so far guys. I really appreciate it.
TheQuestion = 2B || !2B
BlindSide
Admin
Posts: 2821
Joined: Thu Dec 08, 2005 9:09 am
Location: NZ!

Post by BlindSide »

10 FPS = 0.01s
10 FPS = 0.1s
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
DeM0nFiRe
Posts: 117
Joined: Thu Oct 16, 2008 11:59 pm

Post by DeM0nFiRe »

Ahh, perhaps I did not read it correctly, I did not know it was supposed to be only for graphics functions. I guess I assumed it was like whatever other article I read before that included game logic XD.


I guess what I was more referring to is that if you do want to include game logic, you might want to give a hint as to if the user is seeing a framerate drop that is more than a linear proportion, that they should look for that algorithm that is not O(n) and try to replace it with one that is. Again, your article does a good job of explaining what to expect with O(n) algorithms, but I think it would be cool if you added an explanation of what to do when that drop is not linear.
Halifax
Posts: 1424
Joined: Sun Apr 29, 2007 10:40 pm
Location: $9D95

Post by Halifax »

DeM0nFiRe wrote:Ahh, perhaps I did not read it correctly, [...shortened]
I guess what I was more referring to is that if you do want to include game logic, [...shortened]
Ah, okay, that makes sense. And yes, I include information with regards to other operations. Thanks for your help DeM0nFiRe.
BlindSide wrote:10 FPS = 0.1s
Maybe that was to me? I don't know, but that's going to be taken out all in all for the explanation that myself and rooly devised. Not to mention some new percentage difference graphs will be added to clarify.

EDIT: D*** my post count is 1337...mine as well not post for a while. :lol:
TheQuestion = 2B || !2B
Skomakarn
Posts: 18
Joined: Mon Aug 03, 2009 1:03 pm

Post by Skomakarn »

I have written some classes to help me with this kind of problem.
With help from the ITimer value, as it ticks on, I have made timer classes of my own.

The most important one in this case, is my TimeScroller, which increases or decreases a value over time. Maybe I want to move an object from position -10.0 to 4.5 in 8000 milliseconds. This class makes sure this always takes 8000 milliseconds, no matter what the FPS is.

I guess this is what your blog post is about?
Post Reply