Pflow Particle "shape instance" of semi-complex animated mesh causing epic slowdowns.


#1

Yeah,…I know…thats what I get right?

But seriously,…maybe someone has some suggestions here to optimize this?

Pflow setup with 350 particles.
I am using shape instance to use 5 different animated character models (5000 polys each) to create a crowd. Hmmm…350 particles at 5000 faces is 1,750,000 faces,…but still…its an instance for feks sake!
The characters are animated via physique. I did help a bit by Point Caching the character animations.

So the Pflow setup is using shape instance (animated particle) to distribute these characters to create a 350 person crowd.

The problem is when moving the timeline at all, Pflow has to ‘recalculate’ the particles and this takes about 1/2 an hour.
Yes,…for alot of things I can turn off the animated shape parameter and such to work quicker…but in working to finesse the animation offsets…etc…etc…this gets unworkable.

Particle tools 3 dish cache and such seems to not help either!

Am I overlooking some obvious optimization technique?
Would this go faster using Crowd? (although I have never used, and have no need for complex motion blending and such…)

Thanks all.


#2

Hy Jim,

Animated Shape Instances in PFlow are a weak spot.
A workaround would be to attache the animated shapes to the Transform Matrix of a particle system using a script that Bobo wrote:

http://www.scriptspot.com/bobo/mxs5/pflow/pflow__MovingObjects.htm

hope that helps.

kind regards,
Anselm


#3

A workaround would be to attache the animated shapes to the Transform Matrix of a particle system using a script that Bobo wrote:

http://www.scriptspot.com/bobo/mxs5...vingObjects.htm

hope that helps.

Use a final step update script instead of a script operator, will be more accurate.


#4

This is a misnomer. Shape Instance does not do instancing in any shape or form (all puns intended). Shape Instance is equivalent to attaching (using Collapse Utility or Attach in EMesh) 350 meshes with 5000 faces each into a single mesh. And this once per integration step if “Animated Shape” is checked.
It takes a snapshot of the selected shape at the given time for the current particle and stores the resulting TriMesh value in the particle shape channel. Then it repeats this for each particle. To show the final mesh in the viewport or renderer, it collects all the TriMesh values from the shape channels and builds one huge mesh out of them (which is equivalent to attaching meshes together minus the Undo Stack overhead).

Try attaching 350 meshes into one EMesh and you will see that PFlow is rather fast in comparison. :wink:


#5

Am I overlooking some obvious optimization technique?
Did you turn On “Fast Shape Evaluation” option in your Shape Instance operator?

Particle tools 3 disk cache and such seems to not help either!

Could you please elaborate? What do you expect to have with Cache Disk operator?

Thanks,
Oleg B.


#6

Also if your offsetting the animation of the shape instances it will slow your scene down to a halt with what your describing.


#7

I second what psycho says - I did an animation a while back with swarms of coke bottles moving around like shoals of fish and render with vray - the render times were nasty with pflow computing each frame which was odd considering how quick a raytracer vray is - I baked the animation to nulls and parented the bottles to the nulls via scripting and we were back to normal speed wise. Admitedly fast shape evaluation didn’t exist then but you’re gonna get a massive speed increase using simpler shapers for the particles in your viewport.


#8

I did an animation (on may particle Reel if you want to see if its the same) with a shed load of bugs all boned & animated then driven using PFlow. It was slow but not bad rendering times. While doing this animation I looked for other options & started helping a guy called Ofer bake Boned animated PFlow mesh’s the result is below.

There’s loads of options even baking to point cache! For me I had too many bug but maybe it’ll work for you. Check it out either way its a great script for later.

[ul]
[li]Fixed a bug with baking to point cache.[/li][li]Added a curve control to use as an optional ease curve on all baked particles.[/li][/ul]
[ul]
[li]Added support for backing mesh animation. It supports 2 saving methods: vertex animation and point cache.[/li][li]Added option to turn off the Particle Flow system that has been baked when baking is done.[/li][li]Added option to save the baked file as a new max file after baking.[/li][li]Added option to shutdown the computer when baking is done.[/li][/ul]
http://www.oferz.com/MaxScripts/PFlowBaker/PFlowBaker-v0_6.ms

Hope it’s what you need.

Stevie


#9

This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.