- Timestamp:
- 09/20/10 13:50:24 (3 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
OpenSceneGraph/trunk/examples/osgparticleshader/osgparticleshader.cpp
r11765 r11779 167 167 // is still usable, with which we should define another geode to contain a particle system. 168 168 osg::ref_ptr<osgParticle::ParticleSystemUpdater> updater = new osgParticle::ParticleSystemUpdater; 169 updater->addDrawable( ps.get() );169 //updater->addDrawable( ps.get() ); 170 170 171 171 osg::ref_ptr<osg::Group> root = new osg::Group; 172 172 root->addChild( parent.get() ); 173 173 root->addChild( updater.get() ); 174 175 // FIXME 2010.9.19: the updater can't be a drawable; otehrwise the ParticleEffect will not work properly. why? 176 updater->addParticleSystem( ps.get() ); 177 178 osg::ref_ptr<osg::Geode> geode = new osg::Geode; 179 geode->addDrawable( ps.get() ); 180 root->addChild( geode.get() ); 174 181 175 182 /*** … … 191 198 // it is not the best solution so far, since there are still very few particles acting unexpectedly. 192 199 return viewer.run(); 200 201 // FIXME 2010.9.19: At present, getDeltaTime() is not used and the implementations in the updater and processors still 202 // use a (t - _t0) as the delta time, which is of course causing floating errors. ParticleEffect will not work if we 203 // replace the delta time with getDeltaTime()... Need to find a solution. 193 204 }
