McFunkypants  ,first of all I love the spirit :) Secondly I am not sure what
you suggest is quite flexible.Being FLINT particles contributor (molehill
branch) I am contemplating much on different ways to optimize
the pipeline.What you suggested is nice in theory .But think of it this
way:The particles are usually not only interpolated by position .You should
also include orientations.So are you gonna push into the same buffer the
rest of matrix components?I don't understand why.You have a vertex program
for this.You are absolutely right on the fact that the initiation of the
particles is slow when you need to submit a large quantity of buffer within
a short period of time but that problem btw also exists in other platforms
(like OpenGL) .I dug some articles on particle system optimization (c++
based) most of them take "particle buffer" approach but not at the sub
system level as you suggest but recycling particles.May be I didn't get you
so I will be happy to see your results.I am going in the meanwhile implement
a buffer which keeps a particle poll.This should improve the rendering.But I
am really curious if your concept would prove to be more efficient in
reality.
Michael

On Thu, Jun 9, 2011 at 7:34 PM, McFunkypants <goo...@orangeview.net> wrote:

> Particles aplenty!  We want em!  We all know that away3d can only
> render a few hundred objects when rendered individually due to the
> fact that there is a massive overhead in setting up matrix transforms
> for each and every particle in a system when calling drawtriangles for
> them all separately, one at a time.  Hence all the "merge" hacks etc.
>
> I have an idea that should allow mega complex particle systems if
> nearly infinite numbers of polies.  One possible solution would be to
> create a specialized vertex buffer for the entire particle system.
> For example, create a 10,000 poly "mesh" with vertex buffer data as
> follows: x1,y1,z1,x2,y2,z2 meaning the motion of the sprite is pre-
> calculated and stored in the vertex buffer itself.  Then send a delta
> value as a vertex buffer constant register that varies from 0..1 over
> time and each frame you render the mesh have your AGAL vertex program
> interpolate the x,y,z position of each vertex from the starting to the
> ending position.  So each vertex smoothly moves from the first to the
> second position.  This is similar to how md2 and md5 "bones"
> animations are being done.
>
> With this technique, all particle system animation would be handled on
> the GPU with virtually no rendering overhead for animation of gigantic
> particle systems.  Why?  The entire thing is rendered in ONE draw
> call.  Essentially you are "precalculating" the entire animation for
> your explosions, etc.  No worrying about each and every sprite in an
> explosion, you just draw the whole group at once and get the GPU to do
> all the heavy lifting.
>
> Let me know what you think of this idea.  I'm planning to dive in and
> implement it next week.  I'll be sure to share my results in 7-10
> days.  Words of encouragement or naysayers are warmly welcomed.  I
> want to know what you think.




-- 
Michael Ivanov ,Programmer
Neurotech Solutions Ltd.
Flex|Air |3D|Unity|
www.neurotechresearch.com
http://blog.alladvanced.net
Tel:054-4962254
mich...@neurotech.co.il
t...@neurotech.co.il

Reply via email to