Sprite engine - how many sprites can YOU handle?
Sprite engine - how many sprites can YOU handle?
I made a small sprite graphics engine and need to test it on you guys.
This is a graphics engine, it does not handle collision or anything like that, it is not meant to, a collision engine would be a seperate entity.
What it does do, however, is provide an easy way to create a complex sprite. One with several different animations. In this test it is a sprite with 4 animations, one for walking north, south, east. and west.
Tile maps are also supported which are made up of a modified sprite type.
It also supports instancing, so you can make copies of a sprite that have their own unique coordinates and such but share the same animation and graphics data.
I'm interested in knowing how it performs. It performs great on my machine but I have a rather fast computer:
pentium d 3.4 ghz
2 gb ram
ati radeon x1950 gfx card
Just follow the input prompts at the beginning of the program.
Use arrow keys to move around map.
Just post your specs, the settings you chose and the fps you got.
UPDATE 2/28:
- a bunch of small fixes and improvements
- needs a lot of cleanup now that things are close to being done
here's the link to the file:
http://www.mediafire.com/?cghitz03hfn - .zip - 174 kb
Thanks to all that test!
This is a graphics engine, it does not handle collision or anything like that, it is not meant to, a collision engine would be a seperate entity.
What it does do, however, is provide an easy way to create a complex sprite. One with several different animations. In this test it is a sprite with 4 animations, one for walking north, south, east. and west.
Tile maps are also supported which are made up of a modified sprite type.
It also supports instancing, so you can make copies of a sprite that have their own unique coordinates and such but share the same animation and graphics data.
I'm interested in knowing how it performs. It performs great on my machine but I have a rather fast computer:
pentium d 3.4 ghz
2 gb ram
ati radeon x1950 gfx card
Just follow the input prompts at the beginning of the program.
Use arrow keys to move around map.
Just post your specs, the settings you chose and the fps you got.
UPDATE 2/28:
- a bunch of small fixes and improvements
- needs a lot of cleanup now that things are close to being done
here's the link to the file:
http://www.mediafire.com/?cghitz03hfn - .zip - 174 kb
Thanks to all that test!
Last edited by DaveUnit on Feb 29, 2008 2:01, edited 7 times in total.
-
- Posts: 8631
- Joined: May 28, 2005 3:28
- Contact:
Hello Dave
with my older AMD XP 2200 (1.8 GHz.) and NVIDIA ti4200 AGP 8x card ~1200 sprites=30FPS
Joshy
(By the way you will never have thausends of sprites on one screen
and the MMX blitter is realy fast. the problem you have to solve
is collision detection and background blitting (Z-order) and most
time consumed soft screen scrolling)
with my older AMD XP 2200 (1.8 GHz.) and NVIDIA ti4200 AGP 8x card ~1200 sprites=30FPS
Joshy
(By the way you will never have thausends of sprites on one screen
and the MMX blitter is realy fast. the problem you have to solve
is collision detection and background blitting (Z-order) and most
time consumed soft screen scrolling)
Reply
Pentium 4 3.2
1gb RAM
Intel GMA950 Video Card (built in)
Even on the aging Pentium 4, I managed ~5400 sprites at 30fps.
1gb RAM
Intel GMA950 Video Card (built in)
Even on the aging Pentium 4, I managed ~5400 sprites at 30fps.
Keep us posted on your updates!the problem you have to solve is collision detection and background blitting (Z-order) and most time consumed soft screen scrolling
@DJ Peters: I know I will never need that many. I just wanted to see how fast it was on lower end computers. No sense in making a game that runs great on my machine but barely runs on a computer with lower specs than mine would be a waste of time.
I've also done some basic collision detection before (not pixel perfect, I guess I could but I think it will be unnecessary for and rpg). if I wanted to make a side scrolling platformer, sure I'd want pixel perfect. The collision precision (lol) will be determined by my needs later so I'm not worrying about it now.
I've done z order blitting before also, just sort the sprites by their y value so a sprite further back won't overlap one in front of it.
What do you mean by soft screen scrolling? The way I achieve scrolling is by having a camera coordinate and then only what the user sees is drawn and then you just move the camera around and voila, scrolling effect.
Thanks for the input so far guys!
I've also done some basic collision detection before (not pixel perfect, I guess I could but I think it will be unnecessary for and rpg). if I wanted to make a side scrolling platformer, sure I'd want pixel perfect. The collision precision (lol) will be determined by my needs later so I'm not worrying about it now.
I've done z order blitting before also, just sort the sprites by their y value so a sprite further back won't overlap one in front of it.
What do you mean by soft screen scrolling? The way I achieve scrolling is by having a camera coordinate and then only what the user sees is drawn and then you just move the camera around and voila, scrolling effect.
Thanks for the input so far guys!
@aleofjax: 700 should be okay. You might need to run at a lower res when maps are added, maybe 640x480 rather than 800x600. going into my code and changing GFX_WINDOWED to GFX_FULLSCREEN should yield an increase as well. also when maps are added not all of the tiles will be animated so there will be less updating to do every loop. Maybe I could even have it update only once every few loops for a small performance increase.
I'll try to make another test prog that asks how many sprites do you want to actually be animated, how many loops before each update, screen res, and fullscreen/windowed.
hopefully I can get it perform better on your machine aleofjax.
edit: MORE SETTINGS ADDED
@aleofjax: screw with the settings and try to get 1000 sprites on screen with at least 30 fps.
I'll try to make another test prog that asks how many sprites do you want to actually be animated, how many loops before each update, screen res, and fullscreen/windowed.
hopefully I can get it perform better on your machine aleofjax.
edit: MORE SETTINGS ADDED
@aleofjax: screw with the settings and try to get 1000 sprites on screen with at least 30 fps.
Re: Sprite engine - how many sprites can YOU handle?
two pentium3 @ 933MHz eachDaveUnit wrote:I made a small sprite graphics engine and need to test it on you guys.
This is a graphics engine, it does not handle collision or anything like that, it is not meant to.
What it does do, however, is provide an easy way to create a complex sprite. One with several different animations. In this test it is a sprite with 4 animations, one for walking north, south, east. and west.
It also supports instancing, so you can make copies of a sprite that have their own unique coordinates and such but share the same animation and graphics data.
I'm interested in knowing how it performs. It performs great on my machine (takes ~5000 sprites to bring it below 30 frames) but I have a rather fast computer:
pentium d 3.4 ghz
2 gb ram
ati radeon x1950 gfx card
Just follow the input prompts at the beginning of the prog.
Try to find a way to draw over 1000 sprites (animating however many you want) and maintain an fps >= 30
Just post your specs and the settings you chose and the fps you got.
SMALL UPDATE:
- did a quick(well slow, just threw in an insertion sort) depth sort with sprites
- now hitting the enter key gives all sprites a random animation, just to show that these are truly instanced.
- added more customizable settings
Anyway, here's the link to the file:
http://www.mediafire.com/?6m9dz44x7wn - .zip - 159.49 kb
768 Mb. rambus
NVIDIA geforce 2 gts @32mb agpX4
Win XP Pro sp1:
640X480
Full Screen
1000 sprites
1000 animated
1 loop
GOT: 35 fps
-
- Posts: 2338
- Joined: May 31, 2005 9:59
- Location: Croatia
- Contact: