View Full Version : Number of Animation Frames per Second
Sean Doherty
09-11-2006, 08:23 PM
How many frames do people recommend for animations. For example, if you where doing an exploding nuke. How many frames of animation / frames per second would you recommend?
Thanks
luggage
09-12-2006, 04:12 AM
I take it on a case by case basis. It's a trade off between how good it will look, how much size on the disk, memory usage, how important to your game is it, how often will it be seen, etc.
Depending on how your artwork is done you could get the artist to render out a lot of frames then have your animation code play it back using various numbers of frames so you can see the best trade off.
60 is nice, but its a bit overkill usually. Often you can get away with less (30). The explosions in Quake3 for example only have 8 frames in total. They are using some sawtooth function for fading around, which yields a pretty smooth animation.
James C. Smith
09-12-2006, 07:30 AM
As with everything, "it depends" and every case is different. But ~90% of the time we end up using 15 FPS for rendered animations.
Danimal
09-12-2006, 08:16 AM
In traditional animation like the old disney movies they do 12 fps or 24 if there is a lot of action.
Pogacha
09-12-2006, 08:39 AM
I only want to add that animations could be antialiased too, so if the playback speed is fixed you can preproccess it with a motion blur effect at high rates to step down the number of frames to up to 12 per second with very good results.
Sean Doherty
09-12-2006, 01:51 PM
If I was doing a nuke explosion. How long should the total animation time of a nuke explosion and how many frames? What would you say is the min, average, and maximum?
Pogacha
09-12-2006, 02:17 PM
The length of an explosion may goes from 0.4 seg, average 0.8 seg and no more than 1.5 seg and then you should multiply this for the size of the explosion.
The frame rate should go from 12 fps, average 16 fps, and 45 fps at max.
Im kidding, there is no rule. These numbers depend on the game art you are doing.
Sean Doherty
09-12-2006, 02:30 PM
The length of an explosion may goes from 0.4 seg, average 0.8 seg and no more than 1.5 seg and then you should multiply this for the size of the explosion.
The frame rate should go from 12 fps, average 16 fps, and 45 fps at max.
Im kidding, there is no rule. These numbers depend on the game art you are doing.
Do you have a recommendation or are you just going to tell me that question is stupid because 100% if the time it will not be so! Honestly, I bothers me when people awnser questions by saying it depends. Just make an assumption and state you what you think. If you think it is imposible to say don't respond.
Sorry, I just find these types of anwsers difficult to deal. I understand there is no 100% correct awnser, but 50%-80% of the time I bet people use the same number of frames?
Pogacha
09-12-2006, 02:53 PM
My apollogies, I did't want to offend you.
Let's start again:
What I wanted to say was that you don't need a number, you need to understand how graphics works as a whole.
The number of frames per second for your explosions would depends on some factors:
1st- The animation should give the sensation of movement, so the frame rate should have more than 12 fps to cheat the eye. If you use some motion blur techniques you could reach good results at lower fps, if your animation is sharpper you are going to need more frames per second to get the same visual result. You can see these effect easily comparing the 25 fps of a tv versus the 60 of a computer monitor, the tv animations are more armonic since the tv screen has slower response to image changes.
2nd- This animation should keep the aspect of the game, if other things are animated with some criteria, you should keep in mind this criteria for this animation too to see how it fixes. The animation should fixes naturally in the game, it is not just a sequence of fixed images, there are a lot of issues involved (unfortunatelly I'm not an animator so I cannot tell you what are they)
3rd- The amount of hardware resources you have (memory, disk storage), some times you need to sacrifie quality for better performance or you have "space" limitations.
4rd- Sync with the game and the screen refresh rate.
The numbers I gave, are the numbers that come to my mind, you should try with several test to see how they work in your game.
I hope I did help this time.
Regards.
badjim
09-12-2006, 04:55 PM
. You can see these effect easily comparing the 25 fps of a tv versus the 60 of a computer monitor.
TVs use interlacing. They really run at 50/60 fps depending on where you live. Its just that every other frame is a little bit lower down the screen. But many video clips on the net are 30 fps.
Back to the topic: yes it really does depend on the subject matter. But I'd say the region was between 10-40.
The factor here is how big and fast moving the animation is. A small, slow one will look pretty smooth with just 10 fps. A large, fast animation like a nuke will want 20 fps to look acceptable. More frames will make that nuke look better.
At about 8 fps the eye will see motion instead of a series of images. At about 40 fps I find that first person shooters have a smoothness about them. Any fps above that doesn't improve much for me.
My suggestion is that you make a 60 fps animation and drop frames to see it at 60 fps, 30 fps, 20 fps, 15 fps, 12 fps and 10 fps one. In future you will get better at figuring it out.
Sean Doherty
09-12-2006, 06:45 PM
Thanks Pogacha, normally I wouldn't have said anything; it just seems to be a growing trend to explain why the question can't be anwsered. Thanks for the help.
luggage
09-13-2006, 02:23 AM
But the problem is, if I were to go "it should last 4 seconds at 60 frames per second so therefore it would have 240 frames". A few months later someone who's new looks back on this thread to find out the answer to something similar it could easily lead them down the wrong path. There is no hard and fast rule for this - use the fewest you can get away with.
RinkuHero
09-13-2006, 05:01 AM
I remember when Earthworm Jim was released (for the SNES and PC), I read in Nintendo Power magazine that it used some "secret technique" to make the frames per second seem higher than they actually were. I was intrigued and always wondered what that technique could be. Now that I think about it, it seems it was just this motion blur technique! Haha.
As for the question, this is probably obvious, but you don't want a weird fps for an animation that doesn't divide evenly into the screen's fps. For instance, a 12 fps animation shown in 30 fps would look choppy (some frames being shown for longer than some other frames), whereas if it were shown in 60 fps it'd look fine (each frame getting an equal amount of screen time), because 12 divides evenly into 60. In 30 you'd want 15 or 10 instead of 12.
LilGames
09-13-2006, 07:47 AM
I remember when Earthworm Jim was released (for the SNES and PC), I read in Nintendo Power magazine that it used some "secret technique" to make the frames per second seem higher than they actually were. I was intrigued and always wondered what that technique could be. Now that I think about it, it seems it was just this motion blur technique! Haha.
There's no support on the old 16bit systems for advanced blending like blurs. I think the technique you're thinking about was actually David Perry's method of pulling and "caching" animation frames off the cartridge ROM in real-time (something he pioneered with "Global Gladiators", and also was used in "Cool Spot" and all his other Genesis games thereafter).
Prior to that technique, all animation frames had to be stored in the system RAM, which was really limited. So what you ended up with was choppy animations for all enemy sprites (usually around 4 frames for a walk/run cycle) and the main player sprite would get no more than 8 frames for a walk/run cycle, because there just wasn't room in RAM for anything more.
OK sorry folks, back to your regular programming:
Pogacha
09-13-2006, 02:45 PM
There's no support on the old 16bit systems for advanced blending like blurs. I think the technique you're thinking about was actually David Perry's method of pulling and "caching" animation frames off the cartridge ROM in real-time (something he pioneered with "Global Gladiators", and also was used in "Cool Spot" and all his other Genesis games thereafter).
Prior to that technique, all animation frames had to be stored in the system RAM, which was really limited. So what you ended up with was choppy animations for all enemy sprites (usually around 4 frames for a walk/run cycle) and the main player sprite would get no more than 8 frames for a walk/run cycle, because there just wasn't room in RAM for anything more.
OK sorry folks, back to your regular programming:
Anyway the motion blur can be preprocessed. The basic idea is that you create 60 frames, then you blend the first ten into one and so to finish with only 6 frames. In your game you would use only these 6 frames.
Nexic
09-13-2006, 03:53 PM
A nuke that covers most of the screen should probably run at about 25-30 FPS. Though having said that all my animations run at about 15 FPS and some of them end up covering a lot of the screen and still look good. So my advice would be to try several different ones and choose what you think is the best looking/files size trade off.
Something you should definitely do with your nuke is do a white fade on the screen, works brilliant for big explosions.
badjim
09-13-2006, 04:35 PM
As for the question, this is probably obvious, but you don't want a weird fps for an animation that doesn't divide evenly into the screen's fps. For instance, a 12 fps animation shown in 30 fps would look choppy (some frames being shown for longer than some other frames), whereas if it were shown in 60 fps it'd look fine (each frame getting an equal amount of screen time), because 12 divides evenly into 60. In 30 you'd want 15 or 10 instead of 12.
There's a big problem with that idea. Different computers have different refresh rates and it's not a good idea to try forcing peoples refresh rate. Since common refresh rates include 72 and 85 the only way to make it evenly divide is to animate at 1 fps. Also, it just isn't all that important. Playing 3d games on a 60Hz monitor I find 40 fps looks a lot better than 30fps.
Sean Doherty
09-14-2006, 03:26 PM
At present, for my standard explosions, I only have six frames. I've been playing around with the animation speed and I don't think I have enough frames.
1) Is there anyway to use photoshop to generate additional frames using blur or something?
2) I was wondering if people generate different explosions for small, medium, and large images; or just scale?
3) How many seconds do you think an explosion should last. I was thinking somewhere between 1 to 2 seconds?
4) When saving to a PNG file in photoshop, should I use interlaced or non interlaced?
Thanks
badjim
09-14-2006, 04:15 PM
1) If there is a way to algorithmically increase the number of frames, we would all love to know how. We could save space by using 5 fps animations and doubling them up in our game engines. So my guess is you can't. What I do is superimpose two frames and draw an intermediate frame over it by hand. But I'm not a real artist so there may be a better way.
2) If you can do it without fuss then scale. Beware that large images can look bad if you shrink them a lot though.
You could do your explosions with particle effects.
3) Depends on whether the screen is likely to be filled with explosions. In a spammy shooter game you might want to cut that back or the screen could be a constant orange mess of explosions. A slow burning game won't such frequent explosions so you'll want to make them pretty.
4) Interlacing is only for web pages really. You don't need it and you'll get slightly smaller file sizes without it.
Nexic
09-14-2006, 04:38 PM
1) Grab frame 1 and 2, place frame two over the top of frame 1 and give it a transparency of about 50% for an intermediate frame. Rinse and repeat with 2 and 3, 3 and 4, 4 and 5 etc. Not perfect but I did it for a couple of my anims and looks fine. Tried it just now with frame 1 and 3 of a real animation and my resulting frame 2 looked pretty similar to the real frame 2. (depending on the image in question may need to try different blend modes such a 'screen')
2) I do a mix of both. Scale up so far then change to a new anim.
3) I'd say more like 0.5-1 unless it's really big
4) Non interlaced
If you're using acceleration you can sawtooth blend the explosion frames on top of each other. You can additionally rotate em for faking variation.
Interlaced PNGs are bigger. Progressive JPGs are smaller.
If you use an installer like NSIS you can also try uncompressed* PNGs. The lzma compression scheme is superior and the resulting installer will be smaller then.
You also shouldnt use photoshop to save the final PNGs. Use tools such as PNGOUT (http://advsys.net/ken/utils.htm) for better compression (also for your website for shorter loading times). Also check if you can use pngquant (http://www.libpng.org/pub/png/apps/pngquant.html), which gives you basically a 8bit image with rgba palette (infact its an rgb palette but there are up to <number of colors> transparency values in the tRNS chunk).
Quantizised PNGs often look just as good and they are alot smaller (nice for hud elements). You can also recompress em with pngout (use that /k1 switch for keeping the tRNS chunk).
* You can save uncompressed PNGs with pngcrush (http://pmt.sourceforge.net/pngcrush/) for example:
pngcrush -m 1 -l 0 -force in.png out.png
Powered by vBulletin™ Version 4.1.3 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.