AGXDynamics  2.31.1.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
agxOSG::ParticleTrajectoriesDrawable Class Reference

#include <ParticleTrajectoriesDrawable.h>

+ Inheritance diagram for agxOSG::ParticleTrajectoriesDrawable:

Public Member Functions

 ParticleTrajectoriesDrawable (agx::ParticleSystem *particleSystem)
 
virtual const char * className () const
 
virtual osg::Object * clone (const osg::CopyOp &) const
 
virtual osg::Object * cloneType () const
 
virtual osg::BoundingBox computeBound () const
 Compute the bounding box around Drawables's geometry. More...
 
void createParticleTrajectoryFromId (agx::Index particleId)
 
virtual void drawImplementation (osg::RenderInfo &renderInfo) const
 The actual draw method for the particle system. More...
 
bool getEnable () const
 
agx::UInt getNumTrajectoryPositions () const
 Get the number of positions used in the trajectories. More...
 
agx::ParticleSystem * getParticleSystem ()
 
agx::Real getSampling () const
 
virtual bool isSameKindAs (const osg::Object *obj) const
 
virtual const char * libraryName () const
 
bool particleIsRendered (agx::Physics::ParticlePtr &ptr)
 
void popLatestPositions ()
 Pops latest positions in all trajectories. Useful when stepping backwards in a journal. More...
 
void removeParticleTrajectoryFromId (agx::Index particleId)
 Remove the current stored trajectory from the drawable for a particle with given id. More...
 
void resample ()
 
void resetTrajectories ()
 Reset trajectories. More...
 
void setEnable (bool enable)
 
void setNumTrajectoryPositions (agx::UInt num)
 Set the number of positions used in the trajectories. More...
 
void setSampling (agx::Real sampling, bool doResample=true)
 
void updateParticleTrajectories ()
 Update the trajectory structures. More...
 

Protected Member Functions

virtual ~ParticleTrajectoriesDrawable ()
 
void handleCreationEvent (agx::Index index)
 
void handleDestructionEvent (agx::Index index)
 
void popOldPositionsInDeadTrajectories ()
 
void sample (agx::Index index)
 
void updateKernelBuffers ()
 

Protected Attributes

TrajectoryTable m_activeParticleTrajectories
 
agxData::BufferRef m_colorBuffer
 
agxData::BufferRef m_countBuffer
 
agx::Vector
< ParticleTrajectoryData > 
m_destroyedParticlesTrajectories
 
bool m_enable
 
agxData::BufferRef m_firstsBuffer
 
agx::UInt m_maxPosCounts
 
ParticleStorageListener m_particleStorageListener
 
agx::ParticleSystemObserver m_particleSystem
 
agx::TaskGroupRef m_renderTask
 
agx::Real m_sampling
 
agxData::BufferRef m_verticesBuffer
 

Detailed Description

Definition at line 34 of file ParticleTrajectoriesDrawable.h.

Constructor & Destructor Documentation

agxOSG::ParticleTrajectoriesDrawable::ParticleTrajectoriesDrawable ( agx::ParticleSystem *  particleSystem)
virtual agxOSG::ParticleTrajectoriesDrawable::~ParticleTrajectoriesDrawable ( )
protectedvirtual

Member Function Documentation

virtual const char* agxOSG::ParticleTrajectoriesDrawable::className ( ) const
inlinevirtual

Definition at line 74 of file ParticleTrajectoriesDrawable.h.

virtual osg::Object* agxOSG::ParticleTrajectoriesDrawable::clone ( const osg::CopyOp &  ) const
inlinevirtual

Definition at line 71 of file ParticleTrajectoriesDrawable.h.

virtual osg::Object* agxOSG::ParticleTrajectoriesDrawable::cloneType ( ) const
inlinevirtual

Definition at line 70 of file ParticleTrajectoriesDrawable.h.

virtual osg::BoundingBox agxOSG::ParticleTrajectoriesDrawable::computeBound ( ) const
virtual

Compute the bounding box around Drawables's geometry.

void agxOSG::ParticleTrajectoriesDrawable::createParticleTrajectoryFromId ( agx::Index  particleId)
virtual void agxOSG::ParticleTrajectoriesDrawable::drawImplementation ( osg::RenderInfo &  renderInfo) const
virtual

The actual draw method for the particle system.

bool agxOSG::ParticleTrajectoriesDrawable::getEnable ( ) const

Definition at line 159 of file ParticleTrajectoriesDrawable.h.

References m_enable.

agx::UInt agxOSG::ParticleTrajectoriesDrawable::getNumTrajectoryPositions ( ) const

Get the number of positions used in the trajectories.

Definition at line 163 of file ParticleTrajectoriesDrawable.h.

References m_maxPosCounts.

agx::ParticleSystem * agxOSG::ParticleTrajectoriesDrawable::getParticleSystem ( )

Definition at line 157 of file ParticleTrajectoriesDrawable.h.

References m_particleSystem.

agx::Real agxOSG::ParticleTrajectoriesDrawable::getSampling ( ) const

Definition at line 161 of file ParticleTrajectoriesDrawable.h.

References m_sampling.

void agxOSG::ParticleTrajectoriesDrawable::handleCreationEvent ( agx::Index  index)
protected
void agxOSG::ParticleTrajectoriesDrawable::handleDestructionEvent ( agx::Index  index)
protected
virtual bool agxOSG::ParticleTrajectoriesDrawable::isSameKindAs ( const osg::Object *  obj) const
inlinevirtual

Definition at line 72 of file ParticleTrajectoriesDrawable.h.

virtual const char* agxOSG::ParticleTrajectoriesDrawable::libraryName ( ) const
inlinevirtual

Definition at line 73 of file ParticleTrajectoriesDrawable.h.

bool agxOSG::ParticleTrajectoriesDrawable::particleIsRendered ( agx::Physics::ParticlePtr &  ptr)
void agxOSG::ParticleTrajectoriesDrawable::popLatestPositions ( )

Pops latest positions in all trajectories. Useful when stepping backwards in a journal.

void agxOSG::ParticleTrajectoriesDrawable::popOldPositionsInDeadTrajectories ( )
protected
void agxOSG::ParticleTrajectoriesDrawable::removeParticleTrajectoryFromId ( agx::Index  particleId)

Remove the current stored trajectory from the drawable for a particle with given id.

void agxOSG::ParticleTrajectoriesDrawable::resample ( )
void agxOSG::ParticleTrajectoriesDrawable::resetTrajectories ( )

Reset trajectories.

void agxOSG::ParticleTrajectoriesDrawable::sample ( agx::Index  index)
protected
void agxOSG::ParticleTrajectoriesDrawable::setEnable ( bool  enable)
void agxOSG::ParticleTrajectoriesDrawable::setNumTrajectoryPositions ( agx::UInt  num)

Set the number of positions used in the trajectories.

void agxOSG::ParticleTrajectoriesDrawable::setSampling ( agx::Real  sampling,
bool  doResample = true 
)
void agxOSG::ParticleTrajectoriesDrawable::updateKernelBuffers ( )
protected
void agxOSG::ParticleTrajectoriesDrawable::updateParticleTrajectories ( )

Update the trajectory structures.

Member Data Documentation

TrajectoryTable agxOSG::ParticleTrajectoriesDrawable::m_activeParticleTrajectories
protected

Definition at line 144 of file ParticleTrajectoriesDrawable.h.

agxData::BufferRef agxOSG::ParticleTrajectoriesDrawable::m_colorBuffer
protected

Definition at line 147 of file ParticleTrajectoriesDrawable.h.

agxData::BufferRef agxOSG::ParticleTrajectoriesDrawable::m_countBuffer
protected

Definition at line 148 of file ParticleTrajectoriesDrawable.h.

agx::Vector<ParticleTrajectoryData> agxOSG::ParticleTrajectoriesDrawable::m_destroyedParticlesTrajectories
protected

Definition at line 143 of file ParticleTrajectoriesDrawable.h.

bool agxOSG::ParticleTrajectoriesDrawable::m_enable
protected

Definition at line 151 of file ParticleTrajectoriesDrawable.h.

Referenced by getEnable().

agxData::BufferRef agxOSG::ParticleTrajectoriesDrawable::m_firstsBuffer
protected

Definition at line 149 of file ParticleTrajectoriesDrawable.h.

agx::UInt agxOSG::ParticleTrajectoriesDrawable::m_maxPosCounts
protected

Definition at line 150 of file ParticleTrajectoriesDrawable.h.

Referenced by getNumTrajectoryPositions().

ParticleStorageListener agxOSG::ParticleTrajectoriesDrawable::m_particleStorageListener
protected

Definition at line 154 of file ParticleTrajectoriesDrawable.h.

agx::ParticleSystemObserver agxOSG::ParticleTrajectoriesDrawable::m_particleSystem
mutableprotected

Definition at line 140 of file ParticleTrajectoriesDrawable.h.

Referenced by getParticleSystem().

agx::TaskGroupRef agxOSG::ParticleTrajectoriesDrawable::m_renderTask
protected

Definition at line 141 of file ParticleTrajectoriesDrawable.h.

agx::Real agxOSG::ParticleTrajectoriesDrawable::m_sampling
protected

Definition at line 152 of file ParticleTrajectoriesDrawable.h.

Referenced by getSampling().

agxData::BufferRef agxOSG::ParticleTrajectoriesDrawable::m_verticesBuffer
protected

Definition at line 146 of file ParticleTrajectoriesDrawable.h.


The documentation for this class was generated from the following file: