17 #ifndef AGX_PARTICLESYSTEM_H
18 #define AGX_PARTICLESYSTEM_H
75 virtual bool setUpdateTask(
Task* updateTask );
80 Task* getUpdateTask();
143 #if (!defined SWIG ) || ( defined SWIGCSHARP || defined SWIGJAVA)
241 size_t getNumParticles()
const;
246 Real getParticleRadius()
const;
251 Real getParticleMass()
const;
261 void setParticleRadius(
Real radius,
bool updateExistingParticles =
false );
271 virtual void setParticleMass(
Real mass,
bool updateExistingParticles =
false );
281 void setMaterial(
Material* material,
bool updateExistingParticles =
false );
295 const Material* getMaterial()
const;
300 void evaluateParticleDefaultMass();
340 size_t getNumParticleGeometryContacts();
345 size_t getNumParticleParticleContacts();
350 size_t getNumActiveParticleParticleContacts();
355 size_t getNumActiveParticleGeometryContacts();
364 agx::Real getTotalParticleParticleContactForces();
367 agx::Real getTotalParticleGeometryContactForces();
370 agx::Real calculateTotalParticleVolume()
const;
373 agx::Real calculateTotalParticleMass()
const;
411 void addCollisionGroup(
agx::UInt32 id,
bool updateExistingParticles =
true );
412 void addCollisionGroup(
const agx::Name&
id,
bool updateExistingParticles =
true );
418 void removeCollisionGroup(
agx::UInt32 id,
bool updateExistingParticles =
true );
419 void removeCollisionGroup(
const agx::Name&
id,
bool updateExistingParticles =
true );
455 bool hasCollisionGroup(
const agx::Name&
id )
const;
474 void addCustomBufferReal(
const agx::String& buffername );
497 void addCustomBufferInt(
const agx::String& buffername );
520 void addCustomBufferReal32(
const agx::String& buffername );
543 void addCustomBufferVec3(
const agx::String& buffername );
565 virtual void destroySingleParticle(
agx::Index particleId );
586 virtual void setSingleParticleVelocity(
agx::Index particleId,
const agx::Vec3& velocity );
617 void clearAllParticles();
623 void updateShouldRender();
628 void commitColorBuffer();
634 void commitAllBuffers();
648 void _setGravityTask(
Task* task );
650 void clearContactData();
685 void init(
bool createMaterial =
true );
687 void invalidLicenseCallback();
703 bool isJournalPlayback();
730 bool isJournalPlayback();