Closed renegademaster88 closed 12 years ago
Ok so after much fiddling, i have realised that Particles only work in a 2D Context, where as ParticleSytems only work in a 3D Context. At the moment there is nothing to tell you they don' twork. Shouldn't they give an error message or default to a Sprite or rendering using another method? at least rename them CanvasParticle ....
Yeah, it's on out to-do list.
by that do you mean that Particles might work in a 3D context later? That would be very cool, and help allot with the Sparks code im working on!
The other way around. Particle
will be renamed to Sprite
for CanvasRenderer
.
The Current sprite implementation is so slow. just 50000 of them crippled while 1mil of particlesystem particles runs like a champ! anyway to make Sprite fast because that is only thing that similar to particles that work under webgl and raycastor works on them. Or , is there Particle implemenation that fast like those inside ParticleSystem coming? :)
Now i have tried using both of these, i wrote some particles using a Particle system myself and recently have been using Sparks.
Particle systems can assign vertex colours and images to each particle, but not change the size of an individual particle (since they all share the same material).
Where as Particles have their own material and can change size. However when i tried using ParticleBasicMaterial and assigned it a map and a colour, the colour didnt show through when setting
particle.target.material.color (from Sparks)
var material = new THREE.ParticleBasicMaterial( { size: 85, map: sprite, vertexColors: true } );
http://www.nickfallon.net/3D/Attractors_sprite.html
Here you see the colour code working but using a ParticleCanvasMaterial
var material = new THREE.ParticleCanvasMaterial( { program: SPARKS.CanvasShadersUtils.circles, blending:THREE.AdditiveBlending } );
http://www.nickfallon.net/3D/Attractors.html
Is there a way to get the best of both worlds, a texture map, that can change colour and size?