[osg-users] particle speed in OSG Particle Effects
Trajce Nikolov NICK
trajce.nikolov.nick at gmail.com
Sun Oct 25 10:51:41 PDT 2015
Hi Community,
I am trying to work with the sample particle effects, and to change their
speed. I thought it is enough to change the default particle template
velocity, but whatwever I do it seams it has no effect. Here is some
snippet of my approach. Anyone with hint? Thanks a bunch as always
osg::ref_ptr<osgParticle::ParticleEffect> effect;
effect = new osgParticle::SmokeEffect(osg::Vec3(0, 0, 0), scale, intensity);
osgParticle::Particle& particle =
const_cast<osgParticle::Particle&>(effect->getDefaultParticleTemplate());
particle.setVelocity(osg::Vec3(0, 0, particleSpeed));
Nick
--
trajce nikolov nick
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openscenegraph.org/pipermail/osg-users-openscenegraph.org/attachments/20151025/cfd1b54c/attachment-0001.htm>
More information about the osg-users
mailing list