Papervision2.0 ParticleField: GreatWhite and Effects variants

Effects version ParticleField with Pixel3D
The ParticleField class is one of my favourite Papervision 2.0 classes. To use it first you set up an instance of the ParticleMaterial class. Then you set up an instance of the ParticleField class and pass the ParticleMaterial as an argument of the ParticleField constructor. Add it to your Scene3D and render. Voila, particles floating in space, as many as you want.

Now here is the problem, both Effects and GreatWhite libraries of the PV3D package offer this class but, the implementation for each version varies because the constructors are slightly different:

_pm = new ParticleMaterial(0x00f000, 1);

//Great White:
_pf = new ParticleField(_pm,
4000// number of particles,
800//Field width,
100//Field height,
800//Field depth);


//Effects
_pf = new ParticleField(_pm,
4000// number of particles,
null//alternative container
800//Field width,
100//Field height,
800//Field depth);

The Effects version gives you the option to place the ParticleField in a separate container and implement vatious bitmap filters and effects on it via an EffectsLayer or a BitmapEffects layer.

1 comments:

john.speed said...

Hi there, Do you know how to create a particle field with a twinkling star effect? I've been trying for weeks to get this right.

Would definitely appreciate if you could point me in the right direction.

john

My Instagram