FAST particle engine, anyone?

Blitz3D Forums/Blitz3D Programming/FAST particle engine, anyone?

DH(Posted 2005) [#1]
Would anyone be interested in an extremely fast particle engine? I know everyone boasts this, however my comparison tests have proven this 3x faster than anything I can find out there.

How many could use this is what I am asking I guess?

Documentation:
http://www.kcstudios.net/enginetests/ParticleLibraryDocumentation.htm

Demo:
http://www.kcstudios.net/enginetests/ParticleTest.zip

The objective was to create an ultra fast particle engine for a world I am creating. Problem was that most particle engines start to bog when approaching 700-1000 particles. After creating the camera displacement tree demo from a while back it got me to thinking about particles and how they could be sped up.

Let me know what you guys think.

Thanks


BlitzSupport(Posted 2005) [#2]
Looks good, but smoke always seems to appear in front of fire here, regardless of z-position.


DH(Posted 2005) [#3]
What do you mean?


RiverRatt(Posted 2005) [#4]
I would. I think it looks great. And documentation is always a help.
He means the smoke is being drawn over the fire, but thats nothin that can't be fixed easy by the user, I think.


N(Posted 2005) [#5]
Problem was that most particle engines start to bog when approaching 700-1000 particles.


Mine can handle up to 8,000 particles without slowdown.


DH(Posted 2005) [#6]
Mine can handle up to 8,000 particles without slowdown.


Good to hear, is it free?

He means the smoke is being drawn over the fire


I was looking at a candle a week back, and also looking at a bit of trash burning we had going on thursday and in most cases the smoke isn't actually visible until a bit above the flame. Only in huge blazes is the smoke pouring out at the base of the flame.

Just my observations though. You are right though, it can be changed by the user to suite.


DH(Posted 2005) [#7]
Stupid forums..... and it's slowness...


Ross C(Posted 2005) [#8]
I suppose the more speed you can get from these things the better :o) But, the overdraw is probably what kills the frame rate when there are that many particles on screen. I don't really imagine a game needing that many particles.

In saying that though, if you can get 500 odd on screen, but quickier than other particle system, than it's def worth it :o) We should do a test between all particle system, see which on is fastest. Your method certain seems a good way to speed things up ;)


DH(Posted 2005) [#9]
In saying that though, if you can get 500 odd on screen, but quickier than other particle system, than it's def worth it :o) We should do a test between all particle system, see which on is fastest. Your method certain seems a good way to speed things up ;)


Same thoughts as I had. I began this on trying to find a quicker way to do sprites for the tree system that way I could spend more time in other areas (process-wise) rather then bog down the screen for a few trees (50 to be specific) and still have to render terrains, grass, buildings, animated objects,etc.

Thanks for the compliment though. I haven't had a chance to test Noel's yet to see if it lives up to what he boasts yet. Although if it does, then by all means his is fastest.


Rottbott(Posted 2005) [#10]
How does it compare to RottParticles? I can get many thousands of particles with RP without slowdown. Probably not 8,000 though.


Rook Zimbabwe(Posted 2005) [#11]
only 50 trees bog down your screen??? What LOD??? I use ROTTparticles for all I need. I think I have had about 3000- 4000 on the screen at once (based on number of emitters possible to kill at once and their emissions) with no real slowup.

Are you cleaning up after your particle party??? :) Clearworld() does wonders!!!


John Blackledge(Posted 2005) [#12]
I don't think there's any question that we're ALL interested in a very fast particle engine.

My own area of interest though is outdoors, which you seem to be doing a lot of work on, yourself.

Will your system have the capability for trees/foliage?
I can't tell from your website whether your trees are single plane.
Personally I'd like each tree to have a minimum of 3 planes, in case the user gets close.
Would that be possible within a particle system, so hundreds of trees could be achieved?


Ross C(Posted 2005) [#13]
The main speed gain in this comes from blitz automatically rotating the quads to face the camera, so less processing power required, as you don't need to access the vertices as much, as each quad is created facing the camera. You only need to move it to its desired position.


N(Posted 2005) [#14]
Yes, Darky, it is free.

http://www.blitzbasic.com/toolbox/toolbox.php?tool=113


DH(Posted 2005) [#15]
only 50 trees bog down your screen??? What LOD???


What? no! I can get 15,000 trees on the scene before the fps starts to drop. As for LOD, there is a BSP style tree for zones which control the LOD.

The trees are similar to speedtree.

Will your system have the capability for trees/foliage


That is what this work is for. I am trying to create the most realistic outdoor feel as possible, yet have to ability to do a forest as well (huge forest). The particles were merely an offshoot of the tree system using teh camera displacement.

Personally I'd like each tree to have a minimum of 3 planes, in case the user gets close.


How about the trunk, animated, along with 100 leaf bundles, each rotating to the wind (sort of a pendilum swing), X 15,000 more as far as the eye can see!

Like I said, I am trying to emulate speedtree.

I can't tell from your website whether your trees are single plane.


Wow, I forgot I had those outdoor tests on there. those trees are not even close to the end result of this system. They were merely place holders as i was trying to get an outdoor feel with lighting, flares, sunsets, etc.

Would that be possible within a particle system, so hundreds of trees could be achieved?

How about 15,000? The particle system was merely a spinoff of the tree system.

How does it compare to RottParticles? I can get many thousands of particles with RP without slowdown. Probably not 8,000 though.


With the demo above, at 800,600 full screen, placing candle objects like mad on a geforce4200 with a P4 2.4 I can get 11,373 at a steady 30 fps. The candle is a one flame type of particle and a smoke type of particle (2 emitters).


Matty(Posted 2005) [#16]
Comparing speeds of different particle systems is all fine and good but at least do so on equivalent machines. Simply stating that I can get x-thousand/hundred particles running on a system with 'no slowdown' is meaningless without knowing what hardware is being used.


John Blackledge(Posted 2005) [#17]
Cobblers to speed.
"How about 15,000? The particle system was merely a spinoff of the tree system."
That's what I need. Well, maybe not 15,000. But a few hundred.
When will your system be ready?


John Pickford(Posted 2005) [#18]
My Dad is bigger than your Dad.


Software Horizons(Posted 2005) [#19]
The problem I've always had with particles is the size rather than the number of them (at least with particle candy). When the particles are close to the camera and fill the screen I get a large slow down, though I think this is only when they have textures with alpha transparency. Does anyone have any ideas on how that can be avoided or have a system that isn't affected by this?


N(Posted 2005) [#20]
Horizons: It's unavoidable.


DH(Posted 2005) [#21]
The problem I've always had with particles is the size rather than the number of them (at least with particle candy). When the particles are close to the camera and fill the screen I get a large slow down, though I think this is only when they have textures with alpha transparency. Does anyone have any ideas on how that can be avoided or have a system that isn't affected by this?



Yeah, there isn't much you can do about that. I found the same.

I have found that the larger the partciles and the closer you are to them bogs things down. I haven't found a way around it since it has to do with the fill rate.


That's what I need. Well, maybe not 15,000. But a few hundred.
When will your system be ready?


Same here, a few hundred is all I wanted. But I want the most processing I can to go to other things rather then just to doing trees.

As for when the system will be ready, I am still unsure. I am not much of an artist when it comes down to it, so doing a variety of trunks and leaf bundles isn't my strong point and may take a bit to get to look correct. I will keep you posted though.

The tree system does need to be re-written currently. It was merely a rough draft for testing at the moment. It currently has a zone based lod system (setup a grid of zones, place a tree and it will up it into a zone, if its withing the lod distance it will show an lod of that tree, if it's closer it will show the actual tree and animate it, if it's further then the zone tollerances it will hide it all together).


John Blackledge(Posted 2005) [#22]
"I am not much of an artist when it comes down to it, so doing a variety of trunks and leaf bundles isn't my strong point and may take a bit to get to look correct."

- Don't worry too much about that, I have loads of tree and trunk textures just waitinmg to be used.
I just need an easy system, so _I_ don't have to write one myself!

Don't want to make you scream, but what's the chance of a tiny amount of animation on trees and grass, enough to make them 'sway in the wind'. Is that possible with this kind of system?


DH(Posted 2005) [#23]
Don't want to make you scream, but what's the chance of a tiny amount of animation on trees and grass, enough to make them 'sway in the wind'. Is that possible with this kind of system?


Completely possible, and also my intent (we seem to be aiming towords the same thing here).

The trunks at close range are merely models, and could be loaded via animmesh. All I (we) would have to do is change the leave positions stored in the tree structure to be the positions of the bones (or relative positions to that bone whever it may be in animation). The leaves can have a pendelum type of motion by rotating the leaf texture. For more variety, I can use multiple surfaces (randomizing between the surfaces for leaf assignment) and simply rotating the different textures at varrying speeds/degrees.

It's all possible, it's just going to be a bit of time. bare with me :-)


John Blackledge(Posted 2005) [#24]
What? All that, and they can sway in the breeze as well?

I think I should say that I'm prepared to pay for such a system (if that helps with the motivation).

As I said, don't worry about the textures, just give away a couple of trunks and a couple of leaf textures to get new users started, then let them find their own (not too difficult with a web-search, as I did).

A fast particle system that can also handle trees and grass?
This has to be one of the major hurdles in completing my engine.

Please let me know if there's anything I can do to help.
(...coding - unlikely to match yours; working at that level gives me a headache. Textures - just ask.)