AGXDynamics  2.35.0.2
ParticleEntity.h
Go to the documentation of this file.
1 /*
2 Copyright 2007-2022. Algoryx Simulation AB.
3 
4 All AGX source code, intellectual property, documentation, sample code,
5 tutorials, scene files and technical white papers, are copyrighted, proprietary
6 and confidential material of Algoryx Simulation AB. You may not download, read,
7 store, distribute, publish, copy or otherwise disseminate, use or expose this
8 material unless having a written signed agreement with Algoryx Simulation AB, or
9 having been advised so by Algoryx Simulation AB for a time limited evaluation,
10 or having purchased a valid commercial license from Algoryx Simulation AB.
11 
12 Algoryx Simulation AB disclaims all responsibilities for loss or damage caused
13 from using this software, unless otherwise stated in written agreements with
14 Algoryx Simulation AB.
15 */
16 
18 // AUTOMATICALLY GENERATED ENTITY, DO NOT EDIT! //
20 
21 #ifndef GENERATED_AGX_PHYSICS_PARTICLE_H_PLUGIN
22 #define GENERATED_AGX_PHYSICS_PARTICLE_H_PLUGIN
23 
24 #define AGX_ENTITY_WRAPPER 1
25 
26 
27 #ifdef _MSC_VER
28 # pragma warning(push)
29 // warning C4505: 'agxData::VectorAttributeT<T>::print' : unreferenced local function has been removed
30 # pragma warning( disable : 4505 )
31 // warning C4251: 'X' : class 'Y' needs to have dll-interface to be used by clients of class 'Z'
32 # pragma warning( disable : 4251 )
33 // warning C4355: 'this' : used in base member initializer list
34 # pragma warning( disable : 4355 )
35 // marked as __forceinline not inlined
36 # pragma warning( disable: 4714 )
37 #endif
38 
39 #include <agxData/EntityModel.h>
40 #include <agxData/EntityStorage.h>
41 #include <agxData/EntityRef.h>
42 #include <agxData/EntityPtr.h>
43 #include <agxData/EntityInstance.h>
44 #include <agx/Integer.h>
45 #include <agx/Real.h>
46 #include <agx/macros.h>
47 #include <agx/ParticleState.h>
48 #include <agx/Real.h>
51 #include <agx/Vec3.h>
52 #include <agx/Uuid.h>
53 #include <agx/Integer.h>
55 #include <agx/Vec4.h>
56 
57 namespace agx { namespace Physics { class MaterialPtr; }}
58 namespace agx { namespace Physics { class CollisionGroupSetPtr; }}
59 namespace agx { namespace Physics { class GraphNodePtr; }}
60 
61 namespace agx
62 {
63  namespace Physics
64  {
65 
66  class ParticleModel;
67  class ParticleData;
68  class ParticlePtr;
69  class ParticleInstance;
70  class ParticleSemantics;
71 
72 
74 
79  {
80  public:
81  typedef ParticlePtr PtrT;
82 
83  ParticleModel(const agx::String& name = "Particle");
84 
86  static ParticleModel* instance();
87 
89  static ParticlePtr createInstance();
90 
92  static agxData::EntityStorage* defaultStorage();
93 
95  virtual void shutdownCleanup() override;
96 
97 
98 
99  /* Attributes */
127 
128  protected:
129  virtual ~ParticleModel();
130  virtual agxData::EntityData* createData(agxData::EntityStorage* storage) override;
131  virtual void configure(agx::TiXmlElement* eEntity) override;
132  virtual void initAttributeAccessors() override;
133  virtual void construct(agxData::EntityPtr instance) override;
134  void construct(agx::Physics::ParticlePtr particle);
135  };
136 
137 
139  #ifndef AGX_PHYSICS_PARTICLE_DATA_SET_OVERRIDE
140  #define AGX_PHYSICS_PARTICLE_DATA_SET
141  class AGXPHYSICS_EXPORT ParticleData : public agxData::EntityData
142  {
143  public:
144  ParticleInstance operator[] (size_t index);
145 
146  public:
149  agx::Real defaultRadius;
150  agx::Real defaultMass;
151  agx::Physics::MaterialPtr defaultMaterial;
152  agx::Physics::CollisionGroupSetPtr defaultCollisionGroupSet;
153  agx::Real defaultInvMass;
156  agxData::Array< agx::Vec3 > oldVelocity;
163  agxData::Array< agx::Uuid > materialUuid;
169  agxData::Array< agx::UInt32 > geometryContactList;
170  agxData::Array< agx::UInt32 > solveBodyIndex;
173  agxData::Array< agx::Vec3 > geometryContactVector;
174  agxData::Array< agx::Real32 > enableRendering;
175 
176  public:
177  typedef agx::ParticleState stateType;
178  typedef agx::Real defaultRadiusType;
179  typedef agx::Real defaultMassType;
180  typedef agx::Physics::MaterialPtr defaultMaterialType;
181  typedef agx::Physics::CollisionGroupSetPtr defaultCollisionGroupSetType;
182  typedef agx::Real defaultInvMassType;
183  typedef agx::Vec3 positionType;
184  typedef agx::Vec3 velocityType;
185  typedef agx::Vec3 oldVelocityType;
186  typedef agx::Vec3 forceType;
187  typedef agx::Real lifeType;
188  typedef agx::Real radiusType;
189  typedef agx::Real massType;
190  typedef agx::Real invMassType;
191  typedef agx::Physics::MaterialPtr materialType;
192  typedef agx::Uuid materialUuidType;
193  typedef agx::Physics::CollisionGroupSetPtr collisionGroupSetType;
194  typedef agx::UInt8 tierType;
195  typedef agx::UInt32 cellIndexType;
196  typedef agx::UInt16 cellSlotType;
197  typedef agx::UInt32 oldCellType;
198  typedef agx::UInt32 geometryContactListType;
199  typedef agx::UInt32 solveBodyIndexType;
200  typedef agx::Physics::GraphNodePtr graphNodeType;
201  typedef agx::Vec4f colorType;
202  typedef agx::Vec3 geometryContactVectorType;
203  typedef agx::Real32 enableRenderingType;
204 
205  public:
206  ParticleData(agxData::EntityStorage* storage);
207  ParticleData();
208 
209  protected:
210  virtual ~ParticleData() {}
211  virtual void setNumElements(agx::Index numElements) override;
212  virtual void synchronizeSharedAttribute(agxData::Value* value) override;
213 
214  private:
215  ParticleData& operator= (const ParticleData&) { return *this; }
216 
217  };
218  #endif
220 
221 
223  class AGXPHYSICS_EXPORT ParticleSemantics : protected agxData::EntityPtr
224  {
225  public:
226 
227  // Automatic getters
228  agx::ParticleState const& getState() const;
229  agx::Vec3 const& getPosition() const;
230  agx::Vec3 const& getVelocity() const;
231  agx::Vec3 const& getOldVelocity() const;
232  agx::Vec3 const& getForce() const;
233  agx::Real const& getLife() const;
234  agx::Real const& getRadius() const;
235  agx::Real const& getMass() const;
236  agx::Real const& getInvMass() const;
237  agx::Physics::MaterialPtr const& getMaterial() const;
238  agx::Uuid const& getMaterialUuid() const;
239  agx::Physics::CollisionGroupSetPtr const& getCollisionGroupSet() const;
240  agx::UInt8 const& getTier() const;
241  agx::UInt32 const& getCellIndex() const;
242  agx::UInt16 const& getCellSlot() const;
243  agx::UInt32 const& getOldCell() const;
244  agx::UInt32 const& getGeometryContactList() const;
245  agx::UInt32 const& getSolveBodyIndex() const;
246  agx::Physics::GraphNodePtr const& getGraphNode() const;
247  agx::Vec4f const& getColor() const;
248  agx::Vec3 const& getGeometryContactVector() const;
249  agx::Real32 const& getEnableRendering() const;
250 
251  // Semantics defined by explicit kernels
252  void integrate(const agx::Real& clock_timeStep);
253  void integratePosition(const agx::Real& clock_timeStep);
254  void integrateVelocity(const agx::Real& clock_timeStep);
255  void setColor(const agx::Vec4f& color);
256  void setMass(const agx::Real& mass);
257  void setMaterial(const agx::Physics::MaterialPtr& material);
258  void setPosition(const agx::Vec3& position);
259  void setRadius(const agx::Real& radius);
260  void setVelocity(const agx::Vec3& velocity);
261 
262  // Automatic setters
263  void setState(agx::ParticleState const& value);
264  void setOldVelocity(agx::Vec3 const& value);
265  void setForce(agx::Vec3 const& value);
266  void setLife(agx::Real const& value);
267  void setInvMass(agx::Real const& value);
268  void setMaterialUuid(agx::Uuid const& value);
269  void setCollisionGroupSet(agx::Physics::CollisionGroupSetPtr const& value);
270  void setTier(agx::UInt8 const& value);
271  void setCellIndex(agx::UInt32 const& value);
272  void setCellSlot(agx::UInt16 const& value);
273  void setOldCell(agx::UInt32 const& value);
274  void setGeometryContactList(agx::UInt32 const& value);
275  void setSolveBodyIndex(agx::UInt32 const& value);
276  void setGraphNode(agx::Physics::GraphNodePtr const& value);
277  void setGeometryContactVector(agx::Vec3 const& value);
278  void setEnableRendering(agx::Real32 const& value);
279 
280 
281  protected:
282  friend class ParticlePtr;
283  friend class ParticleInstance;
284  ParticleSemantics();
285  };
287 
288 
289 
292  class CALLABLE ParticlePtr : public agxData::EntityPtr
293  {
294  public:
296  typedef ParticleData DataType;
297  typedef ParticleInstance InstanceType;
298 
299  public:
304  AGXPHYSICS_EXPORT ParticlePtr& operator= (const agxData::EntityPtr& ptr);
305  AGXPHYSICS_EXPORT ParticlePtr& operator= (const agxData::EntityInstance& instance);
306  AGXPHYSICS_EXPORT ParticleInstance instance();
307  AGXPHYSICS_EXPORT const ParticleInstance instance() const;
308 
309  AGXPHYSICS_EXPORT ParticleSemantics* operator->();
310  AGXPHYSICS_EXPORT const ParticleSemantics* operator->() const;
311 
312  ParticleData* getData();
313  const ParticleData* getData() const;
314 
315 
317  AGXPHYSICS_EXPORT agx::ParticleState& state();
319  AGXPHYSICS_EXPORT agx::ParticleState const& state() const;
320 
322  AGXPHYSICS_EXPORT agx::Real& defaultRadius();
324  AGXPHYSICS_EXPORT agx::Real const& defaultRadius() const;
325 
327  AGXPHYSICS_EXPORT agx::Real& defaultMass();
329  AGXPHYSICS_EXPORT agx::Real const& defaultMass() const;
330 
332  AGXPHYSICS_EXPORT agx::Physics::MaterialPtr& defaultMaterial();
334  AGXPHYSICS_EXPORT agx::Physics::MaterialPtr const& defaultMaterial() const;
335 
337  AGXPHYSICS_EXPORT agx::Physics::CollisionGroupSetPtr& defaultCollisionGroupSet();
339  AGXPHYSICS_EXPORT agx::Physics::CollisionGroupSetPtr const& defaultCollisionGroupSet() const;
340 
342  AGXPHYSICS_EXPORT agx::Real& defaultInvMass();
344  AGXPHYSICS_EXPORT agx::Real const& defaultInvMass() const;
345 
347  AGXPHYSICS_EXPORT agx::Vec3& position();
349  AGXPHYSICS_EXPORT agx::Vec3 const& position() const;
350 
352  AGXPHYSICS_EXPORT agx::Vec3& velocity();
354  AGXPHYSICS_EXPORT agx::Vec3 const& velocity() const;
355 
357  AGXPHYSICS_EXPORT agx::Vec3& oldVelocity();
359  AGXPHYSICS_EXPORT agx::Vec3 const& oldVelocity() const;
360 
362  AGXPHYSICS_EXPORT agx::Vec3& force();
364  AGXPHYSICS_EXPORT agx::Vec3 const& force() const;
365 
369  AGXPHYSICS_EXPORT agx::Real const& life() const;
370 
372  AGXPHYSICS_EXPORT agx::Real& radius();
374  AGXPHYSICS_EXPORT agx::Real const& radius() const;
375 
379  AGXPHYSICS_EXPORT agx::Real const& mass() const;
380 
382  AGXPHYSICS_EXPORT agx::Real& invMass();
384  AGXPHYSICS_EXPORT agx::Real const& invMass() const;
385 
389  AGXPHYSICS_EXPORT agx::Physics::MaterialPtr const& material() const;
390 
392  AGXPHYSICS_EXPORT agx::Uuid& materialUuid();
394  AGXPHYSICS_EXPORT agx::Uuid const& materialUuid() const;
395 
399  AGXPHYSICS_EXPORT agx::Physics::CollisionGroupSetPtr const& collisionGroupSet() const;
400 
404  AGXPHYSICS_EXPORT agx::UInt8 const& tier() const;
405 
407  AGXPHYSICS_EXPORT agx::UInt32& cellIndex();
409  AGXPHYSICS_EXPORT agx::UInt32 const& cellIndex() const;
410 
412  AGXPHYSICS_EXPORT agx::UInt16& cellSlot();
414  AGXPHYSICS_EXPORT agx::UInt16 const& cellSlot() const;
415 
417  AGXPHYSICS_EXPORT agx::UInt32& oldCell();
419  AGXPHYSICS_EXPORT agx::UInt32 const& oldCell() const;
420 
422  AGXPHYSICS_EXPORT agx::UInt32& geometryContactList();
424  AGXPHYSICS_EXPORT agx::UInt32 const& geometryContactList() const;
425 
427  AGXPHYSICS_EXPORT agx::UInt32& solveBodyIndex();
429  AGXPHYSICS_EXPORT agx::UInt32 const& solveBodyIndex() const;
430 
434  AGXPHYSICS_EXPORT agx::Physics::GraphNodePtr const& graphNode() const;
435 
437  AGXPHYSICS_EXPORT agx::Vec4f& color();
439  AGXPHYSICS_EXPORT agx::Vec4f const& color() const;
440 
442  AGXPHYSICS_EXPORT agx::Vec3& geometryContactVector();
444  AGXPHYSICS_EXPORT agx::Vec3 const& geometryContactVector() const;
445 
447  AGXPHYSICS_EXPORT agx::Real32& enableRendering();
449  AGXPHYSICS_EXPORT agx::Real32 const& enableRendering() const;
450 
452  // Only used by tolua!
453  #ifdef AGX_GENERATED_TOLUA_WRAPPER
454  inline agx::ParticleState const& getState() const { return (*this)->getState(); }
455  inline agx::Vec3 const& getPosition() const { return (*this)->getPosition(); }
456  inline agx::Vec3 const& getVelocity() const { return (*this)->getVelocity(); }
457  inline agx::Vec3 const& getOldVelocity() const { return (*this)->getOldVelocity(); }
458  inline agx::Vec3 const& getForce() const { return (*this)->getForce(); }
459  inline agx::Real const& getLife() const { return (*this)->getLife(); }
460  inline agx::Real const& getRadius() const { return (*this)->getRadius(); }
461  inline agx::Real const& getMass() const { return (*this)->getMass(); }
462  inline agx::Real const& getInvMass() const { return (*this)->getInvMass(); }
463  inline agx::Physics::MaterialPtr const& getMaterial() const { return (*this)->getMaterial(); }
464  inline agx::Uuid const& getMaterialUuid() const { return (*this)->getMaterialUuid(); }
465  inline agx::Physics::CollisionGroupSetPtr const& getCollisionGroupSet() const { return (*this)->getCollisionGroupSet(); }
466  inline agx::UInt8 const& getTier() const { return (*this)->getTier(); }
467  inline agx::UInt32 const& getCellIndex() const { return (*this)->getCellIndex(); }
468  inline agx::UInt16 const& getCellSlot() const { return (*this)->getCellSlot(); }
469  inline agx::UInt32 const& getOldCell() const { return (*this)->getOldCell(); }
470  inline agx::UInt32 const& getGeometryContactList() const { return (*this)->getGeometryContactList(); }
471  inline agx::UInt32 const& getSolveBodyIndex() const { return (*this)->getSolveBodyIndex(); }
472  inline agx::Physics::GraphNodePtr const& getGraphNode() const { return (*this)->getGraphNode(); }
473  inline agx::Vec4f const& getColor() const { return (*this)->getColor(); }
474  inline agx::Vec3 const& getGeometryContactVector() const { return (*this)->getGeometryContactVector(); }
475  inline agx::Real32 const& getEnableRendering() const { return (*this)->getEnableRendering(); }
476 
477  inline void integrate(const agx::Real& clock_timeStep) { (*this)->integrate(clock_timeStep); }
478  inline void integratePosition(const agx::Real& clock_timeStep) { (*this)->integratePosition(clock_timeStep); }
479  inline void integrateVelocity(const agx::Real& clock_timeStep) { (*this)->integrateVelocity(clock_timeStep); }
480  inline void setColor(const agx::Vec4f& color) { (*this)->setColor(color); }
481  inline void setMass(const agx::Real& mass) { (*this)->setMass(mass); }
482  inline void setMaterial(const agx::Physics::MaterialPtr& material) { (*this)->setMaterial(material); }
483  inline void setPosition(const agx::Vec3& position) { (*this)->setPosition(position); }
484  inline void setRadius(const agx::Real& radius) { (*this)->setRadius(radius); }
485  inline void setVelocity(const agx::Vec3& velocity) { (*this)->setVelocity(velocity); }
486 
487  inline void setState(agx::ParticleState const& value) { (*this)->setState(value); }
488  inline void setOldVelocity(agx::Vec3 const& value) { (*this)->setOldVelocity(value); }
489  inline void setForce(agx::Vec3 const& value) { (*this)->setForce(value); }
490  inline void setLife(agx::Real const& value) { (*this)->setLife(value); }
491  inline void setInvMass(agx::Real const& value) { (*this)->setInvMass(value); }
492  inline void setMaterialUuid(agx::Uuid const& value) { (*this)->setMaterialUuid(value); }
493  inline void setCollisionGroupSet(agx::Physics::CollisionGroupSetPtr const& value) { (*this)->setCollisionGroupSet(value); }
494  inline void setTier(agx::UInt8 const& value) { (*this)->setTier(value); }
495  inline void setCellIndex(agx::UInt32 const& value) { (*this)->setCellIndex(value); }
496  inline void setCellSlot(agx::UInt16 const& value) { (*this)->setCellSlot(value); }
497  inline void setOldCell(agx::UInt32 const& value) { (*this)->setOldCell(value); }
498  inline void setGeometryContactList(agx::UInt32 const& value) { (*this)->setGeometryContactList(value); }
499  inline void setSolveBodyIndex(agx::UInt32 const& value) { (*this)->setSolveBodyIndex(value); }
500  inline void setGraphNode(agx::Physics::GraphNodePtr const& value) { (*this)->setGraphNode(value); }
501  inline void setGeometryContactVector(agx::Vec3 const& value) { (*this)->setGeometryContactVector(value); }
502  inline void setEnableRendering(agx::Real32 const& value) { (*this)->setEnableRendering(value); }
503  #endif
505 
506  };
507 
508 
510  class AGXPHYSICS_EXPORT ParticleInstance : public agxData::EntityInstance
511  {
512  public:
513  ParticleInstance();
514  ParticleInstance(ParticleData* data, agx::Index index);
515  ParticleInstance(agxData::EntityStorage *storage, agx::Index index);
516  ParticleInstance(const agxData::EntityInstance& other);
517  ParticleInstance(const agxData::EntityPtr& ptr);
518 
519  ParticleData* getData();
520  const ParticleData* getData() const;
521 
522  public:
524  agx::ParticleState& state();
526  agx::ParticleState const& state() const;
527 
529  agx::Real& defaultRadius();
531  agx::Real const& defaultRadius() const;
532 
534  agx::Real& defaultMass();
536  agx::Real const& defaultMass() const;
537 
539  agx::Physics::MaterialPtr& defaultMaterial();
541  agx::Physics::MaterialPtr const& defaultMaterial() const;
542 
544  agx::Physics::CollisionGroupSetPtr& defaultCollisionGroupSet();
546  agx::Physics::CollisionGroupSetPtr const& defaultCollisionGroupSet() const;
547 
549  agx::Real& defaultInvMass();
551  agx::Real const& defaultInvMass() const;
552 
554  agx::Vec3& position();
556  agx::Vec3 const& position() const;
557 
559  agx::Vec3& velocity();
561  agx::Vec3 const& velocity() const;
562 
564  agx::Vec3& oldVelocity();
566  agx::Vec3 const& oldVelocity() const;
567 
569  agx::Vec3& force();
571  agx::Vec3 const& force() const;
572 
574  agx::Real& life();
576  agx::Real const& life() const;
577 
579  agx::Real& radius();
581  agx::Real const& radius() const;
582 
584  agx::Real& mass();
586  agx::Real const& mass() const;
587 
589  agx::Real& invMass();
591  agx::Real const& invMass() const;
592 
594  agx::Physics::MaterialPtr& material();
596  agx::Physics::MaterialPtr const& material() const;
597 
599  agx::Uuid& materialUuid();
601  agx::Uuid const& materialUuid() const;
602 
604  agx::Physics::CollisionGroupSetPtr& collisionGroupSet();
606  agx::Physics::CollisionGroupSetPtr const& collisionGroupSet() const;
607 
609  agx::UInt8& tier();
611  agx::UInt8 const& tier() const;
612 
614  agx::UInt32& cellIndex();
616  agx::UInt32 const& cellIndex() const;
617 
619  agx::UInt16& cellSlot();
621  agx::UInt16 const& cellSlot() const;
622 
624  agx::UInt32& oldCell();
626  agx::UInt32 const& oldCell() const;
627 
629  agx::UInt32& geometryContactList();
631  agx::UInt32 const& geometryContactList() const;
632 
634  agx::UInt32& solveBodyIndex();
636  agx::UInt32 const& solveBodyIndex() const;
637 
639  agx::Physics::GraphNodePtr& graphNode();
641  agx::Physics::GraphNodePtr const& graphNode() const;
642 
644  agx::Vec4f& color();
646  agx::Vec4f const& color() const;
647 
649  agx::Vec3& geometryContactVector();
651  agx::Vec3 const& geometryContactVector() const;
652 
654  agx::Real32& enableRendering();
656  agx::Real32 const& enableRendering() const;
657 
658  };
660 
661 
662 
665 
666 
667 
669  /* Implementation */
670  //-----------------------------------------------------------------------------------------------------
671  //-----------------------------------------------------------------------------------------------------
672  inline ParticleInstance agx::Physics::ParticleData::operator[] (size_t index) { return ParticleInstance(this, (agx::Index)index); }
673  //-----------------------------------------------------------------------------------------------------
675  AGX_FORCE_INLINE ParticlePtr::ParticlePtr(agxData::EntityStorage* storage, agx::Index id) : agxData::EntityPtr(storage, id) {}
676  AGX_FORCE_INLINE ParticlePtr::ParticlePtr(const agxData::EntityPtr& ptr) : agxData::EntityPtr(ptr)
677  {
679  "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
680  EntityPtr::getModel()->fullPath().c_str(), ParticleModel::instance()->fullPath().c_str());
681  }
682 
683  AGX_FORCE_INLINE ParticlePtr::ParticlePtr(const agxData::EntityInstance& instance) : agxData::EntityPtr(instance)
684  {
685  agxAssertN(!instance || instance.isInstanceOf(ParticleModel::instance()),
686  "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
687  EntityPtr::getModel()->fullPath().c_str(), ParticleModel::instance()->fullPath().c_str());
688  }
689 
690  AGX_FORCE_INLINE ParticlePtr& ParticlePtr::operator= (const agxData::EntityPtr& ptr)
691  {
693  agxAssertN(!ptr || ptr.isInstanceOf(ParticleModel::instance()),
694  "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
695  EntityPtr::getModel()->fullPath().c_str(), ParticleModel::instance()->fullPath().c_str());
696  return *this;
697  }
698 
699  AGX_FORCE_INLINE ParticlePtr& ParticlePtr::operator= (const agxData::EntityInstance& instance)
700  {
702  agxAssertN(!instance || instance.isInstanceOf(ParticleModel::instance()),
703  "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
704  EntityPtr::getModel()->fullPath().c_str(), ParticleModel::instance()->fullPath().c_str());
705  return *this;
706  }
707 
708  inline ParticleInstance ParticlePtr::instance() { return agxData::EntityPtr::instance(); }
709  inline const ParticleInstance ParticlePtr::instance() const { return agxData::EntityPtr::instance(); }
710  AGX_FORCE_INLINE ParticleSemantics* ParticlePtr::operator->() { return (ParticleSemantics* )this; }
711  AGX_FORCE_INLINE const ParticleSemantics* ParticlePtr::operator->() const { return (const ParticleSemantics* )this; }
712  AGX_FORCE_INLINE ParticleData* ParticlePtr::getData() { return static_cast<ParticleData* >(agxData::EntityPtr::getData()); }
713  AGX_FORCE_INLINE const ParticleData* ParticlePtr::getData() const { return static_cast<const ParticleData* >(agxData::EntityPtr::getData()); }
714 
715  AGX_FORCE_INLINE agx::ParticleState& ParticlePtr::state() { verifyIndex(); return getData()->state[calculateIndex()]; }
716  AGX_FORCE_INLINE agx::ParticleState const& ParticlePtr::state() const { verifyIndex(); return getData()->state[calculateIndex()]; }
717 
718  AGX_FORCE_INLINE agx::Real& ParticlePtr::defaultRadius() { verifyIndex(); return getData()->defaultRadius; }
719  AGX_FORCE_INLINE agx::Real const& ParticlePtr::defaultRadius() const { verifyIndex(); return getData()->defaultRadius; }
720 
721  AGX_FORCE_INLINE agx::Real& ParticlePtr::defaultMass() { verifyIndex(); return getData()->defaultMass; }
722  AGX_FORCE_INLINE agx::Real const& ParticlePtr::defaultMass() const { verifyIndex(); return getData()->defaultMass; }
723 
724  AGX_FORCE_INLINE agx::Physics::MaterialPtr& ParticlePtr::defaultMaterial() { verifyIndex(); return getData()->defaultMaterial; }
725  AGX_FORCE_INLINE agx::Physics::MaterialPtr const& ParticlePtr::defaultMaterial() const { verifyIndex(); return getData()->defaultMaterial; }
726 
727  AGX_FORCE_INLINE agx::Physics::CollisionGroupSetPtr& ParticlePtr::defaultCollisionGroupSet() { verifyIndex(); return getData()->defaultCollisionGroupSet; }
728  AGX_FORCE_INLINE agx::Physics::CollisionGroupSetPtr const& ParticlePtr::defaultCollisionGroupSet() const { verifyIndex(); return getData()->defaultCollisionGroupSet; }
729 
730  AGX_FORCE_INLINE agx::Real& ParticlePtr::defaultInvMass() { verifyIndex(); return getData()->defaultInvMass; }
731  AGX_FORCE_INLINE agx::Real const& ParticlePtr::defaultInvMass() const { verifyIndex(); return getData()->defaultInvMass; }
732 
733  AGX_FORCE_INLINE agx::Vec3& ParticlePtr::position() { verifyIndex(); return getData()->position[calculateIndex()]; }
734  AGX_FORCE_INLINE agx::Vec3 const& ParticlePtr::position() const { verifyIndex(); return getData()->position[calculateIndex()]; }
735 
736  AGX_FORCE_INLINE agx::Vec3& ParticlePtr::velocity() { verifyIndex(); return getData()->velocity[calculateIndex()]; }
737  AGX_FORCE_INLINE agx::Vec3 const& ParticlePtr::velocity() const { verifyIndex(); return getData()->velocity[calculateIndex()]; }
738 
739  AGX_FORCE_INLINE agx::Vec3& ParticlePtr::oldVelocity() { verifyIndex(); return getData()->oldVelocity[calculateIndex()]; }
740  AGX_FORCE_INLINE agx::Vec3 const& ParticlePtr::oldVelocity() const { verifyIndex(); return getData()->oldVelocity[calculateIndex()]; }
741 
742  AGX_FORCE_INLINE agx::Vec3& ParticlePtr::force() { verifyIndex(); return getData()->force[calculateIndex()]; }
743  AGX_FORCE_INLINE agx::Vec3 const& ParticlePtr::force() const { verifyIndex(); return getData()->force[calculateIndex()]; }
744 
745  AGX_FORCE_INLINE agx::Real& ParticlePtr::life() { verifyIndex(); return getData()->life[calculateIndex()]; }
746  AGX_FORCE_INLINE agx::Real const& ParticlePtr::life() const { verifyIndex(); return getData()->life[calculateIndex()]; }
747 
748  AGX_FORCE_INLINE agx::Real& ParticlePtr::radius() { verifyIndex(); return getData()->radius[calculateIndex()]; }
749  AGX_FORCE_INLINE agx::Real const& ParticlePtr::radius() const { verifyIndex(); return getData()->radius[calculateIndex()]; }
750 
751  AGX_FORCE_INLINE agx::Real& ParticlePtr::mass() { verifyIndex(); return getData()->mass[calculateIndex()]; }
752  AGX_FORCE_INLINE agx::Real const& ParticlePtr::mass() const { verifyIndex(); return getData()->mass[calculateIndex()]; }
753 
754  AGX_FORCE_INLINE agx::Real& ParticlePtr::invMass() { verifyIndex(); return getData()->invMass[calculateIndex()]; }
755  AGX_FORCE_INLINE agx::Real const& ParticlePtr::invMass() const { verifyIndex(); return getData()->invMass[calculateIndex()]; }
756 
757  AGX_FORCE_INLINE agx::Physics::MaterialPtr& ParticlePtr::material() { verifyIndex(); return getData()->material[calculateIndex()]; }
758  AGX_FORCE_INLINE agx::Physics::MaterialPtr const& ParticlePtr::material() const { verifyIndex(); return getData()->material[calculateIndex()]; }
759 
760  AGX_FORCE_INLINE agx::Uuid& ParticlePtr::materialUuid() { verifyIndex(); return getData()->materialUuid[calculateIndex()]; }
761  AGX_FORCE_INLINE agx::Uuid const& ParticlePtr::materialUuid() const { verifyIndex(); return getData()->materialUuid[calculateIndex()]; }
762 
763  AGX_FORCE_INLINE agx::Physics::CollisionGroupSetPtr& ParticlePtr::collisionGroupSet() { verifyIndex(); return getData()->collisionGroupSet[calculateIndex()]; }
764  AGX_FORCE_INLINE agx::Physics::CollisionGroupSetPtr const& ParticlePtr::collisionGroupSet() const { verifyIndex(); return getData()->collisionGroupSet[calculateIndex()]; }
765 
766  AGX_FORCE_INLINE agx::UInt8& ParticlePtr::tier() { verifyIndex(); return getData()->tier[calculateIndex()]; }
767  AGX_FORCE_INLINE agx::UInt8 const& ParticlePtr::tier() const { verifyIndex(); return getData()->tier[calculateIndex()]; }
768 
769  AGX_FORCE_INLINE agx::UInt32& ParticlePtr::cellIndex() { verifyIndex(); return getData()->cellIndex[calculateIndex()]; }
770  AGX_FORCE_INLINE agx::UInt32 const& ParticlePtr::cellIndex() const { verifyIndex(); return getData()->cellIndex[calculateIndex()]; }
771 
772  AGX_FORCE_INLINE agx::UInt16& ParticlePtr::cellSlot() { verifyIndex(); return getData()->cellSlot[calculateIndex()]; }
773  AGX_FORCE_INLINE agx::UInt16 const& ParticlePtr::cellSlot() const { verifyIndex(); return getData()->cellSlot[calculateIndex()]; }
774 
775  AGX_FORCE_INLINE agx::UInt32& ParticlePtr::oldCell() { verifyIndex(); return getData()->oldCell[calculateIndex()]; }
776  AGX_FORCE_INLINE agx::UInt32 const& ParticlePtr::oldCell() const { verifyIndex(); return getData()->oldCell[calculateIndex()]; }
777 
778  AGX_FORCE_INLINE agx::UInt32& ParticlePtr::geometryContactList() { verifyIndex(); return getData()->geometryContactList[calculateIndex()]; }
779  AGX_FORCE_INLINE agx::UInt32 const& ParticlePtr::geometryContactList() const { verifyIndex(); return getData()->geometryContactList[calculateIndex()]; }
780 
781  AGX_FORCE_INLINE agx::UInt32& ParticlePtr::solveBodyIndex() { verifyIndex(); return getData()->solveBodyIndex[calculateIndex()]; }
782  AGX_FORCE_INLINE agx::UInt32 const& ParticlePtr::solveBodyIndex() const { verifyIndex(); return getData()->solveBodyIndex[calculateIndex()]; }
783 
784  AGX_FORCE_INLINE agx::Physics::GraphNodePtr& ParticlePtr::graphNode() { verifyIndex(); return getData()->graphNode[calculateIndex()]; }
785  AGX_FORCE_INLINE agx::Physics::GraphNodePtr const& ParticlePtr::graphNode() const { verifyIndex(); return getData()->graphNode[calculateIndex()]; }
786 
787  AGX_FORCE_INLINE agx::Vec4f& ParticlePtr::color() { verifyIndex(); return getData()->color[calculateIndex()]; }
788  AGX_FORCE_INLINE agx::Vec4f const& ParticlePtr::color() const { verifyIndex(); return getData()->color[calculateIndex()]; }
789 
790  AGX_FORCE_INLINE agx::Vec3& ParticlePtr::geometryContactVector() { verifyIndex(); return getData()->geometryContactVector[calculateIndex()]; }
791  AGX_FORCE_INLINE agx::Vec3 const& ParticlePtr::geometryContactVector() const { verifyIndex(); return getData()->geometryContactVector[calculateIndex()]; }
792 
793  AGX_FORCE_INLINE agx::Real32& ParticlePtr::enableRendering() { verifyIndex(); return getData()->enableRendering[calculateIndex()]; }
794  AGX_FORCE_INLINE agx::Real32 const& ParticlePtr::enableRendering() const { verifyIndex(); return getData()->enableRendering[calculateIndex()]; }
795 
796  //-----------------------------------------------------------------------------------------------------
797  AGX_FORCE_INLINE ParticleInstance::ParticleInstance() {}
798  AGX_FORCE_INLINE ParticleInstance::ParticleInstance(ParticleData* data, agx::Index index) : agxData::EntityInstance(data, index) {}
799  AGX_FORCE_INLINE ParticleInstance::ParticleInstance(agxData::EntityStorage* storage, agx::Index index) : agxData::EntityInstance(storage, index) {}
800  AGX_FORCE_INLINE ParticleInstance::ParticleInstance(const agxData::EntityInstance& other) : agxData::EntityInstance(other)
801  {
803  "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
805  }
806 
807  AGX_FORCE_INLINE ParticleInstance::ParticleInstance(const agxData::EntityPtr& ptr) : agxData::EntityInstance(ptr)
808  {
810  "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
812  }
813 
814 
815  AGX_FORCE_INLINE ParticleData* ParticleInstance::getData() { return static_cast<ParticleData* >(agxData::EntityInstance::getData()); }
816  AGX_FORCE_INLINE const ParticleData* ParticleInstance::getData() const { return static_cast<const ParticleData* >(agxData::EntityInstance::getData()); }
817 
818  AGX_FORCE_INLINE agx::ParticleState& ParticleInstance::state() { verifyIndex(); return getData()->state[getIndex()]; }
819  AGX_FORCE_INLINE agx::ParticleState const& ParticleInstance::state() const { verifyIndex(); return getData()->state[getIndex()]; }
820 
821  AGX_FORCE_INLINE agx::Real& ParticleInstance::defaultRadius() { verifyIndex(); return getData()->defaultRadius; }
822  AGX_FORCE_INLINE agx::Real const& ParticleInstance::defaultRadius() const { verifyIndex(); return getData()->defaultRadius; }
823 
824  AGX_FORCE_INLINE agx::Real& ParticleInstance::defaultMass() { verifyIndex(); return getData()->defaultMass; }
825  AGX_FORCE_INLINE agx::Real const& ParticleInstance::defaultMass() const { verifyIndex(); return getData()->defaultMass; }
826 
827  AGX_FORCE_INLINE agx::Physics::MaterialPtr& ParticleInstance::defaultMaterial() { verifyIndex(); return getData()->defaultMaterial; }
828  AGX_FORCE_INLINE agx::Physics::MaterialPtr const& ParticleInstance::defaultMaterial() const { verifyIndex(); return getData()->defaultMaterial; }
829 
830  AGX_FORCE_INLINE agx::Physics::CollisionGroupSetPtr& ParticleInstance::defaultCollisionGroupSet() { verifyIndex(); return getData()->defaultCollisionGroupSet; }
831  AGX_FORCE_INLINE agx::Physics::CollisionGroupSetPtr const& ParticleInstance::defaultCollisionGroupSet() const { verifyIndex(); return getData()->defaultCollisionGroupSet; }
832 
833  AGX_FORCE_INLINE agx::Real& ParticleInstance::defaultInvMass() { verifyIndex(); return getData()->defaultInvMass; }
834  AGX_FORCE_INLINE agx::Real const& ParticleInstance::defaultInvMass() const { verifyIndex(); return getData()->defaultInvMass; }
835 
836  AGX_FORCE_INLINE agx::Vec3& ParticleInstance::position() { verifyIndex(); return getData()->position[getIndex()]; }
837  AGX_FORCE_INLINE agx::Vec3 const& ParticleInstance::position() const { verifyIndex(); return getData()->position[getIndex()]; }
838 
839  AGX_FORCE_INLINE agx::Vec3& ParticleInstance::velocity() { verifyIndex(); return getData()->velocity[getIndex()]; }
840  AGX_FORCE_INLINE agx::Vec3 const& ParticleInstance::velocity() const { verifyIndex(); return getData()->velocity[getIndex()]; }
841 
842  AGX_FORCE_INLINE agx::Vec3& ParticleInstance::oldVelocity() { verifyIndex(); return getData()->oldVelocity[getIndex()]; }
843  AGX_FORCE_INLINE agx::Vec3 const& ParticleInstance::oldVelocity() const { verifyIndex(); return getData()->oldVelocity[getIndex()]; }
844 
845  AGX_FORCE_INLINE agx::Vec3& ParticleInstance::force() { verifyIndex(); return getData()->force[getIndex()]; }
846  AGX_FORCE_INLINE agx::Vec3 const& ParticleInstance::force() const { verifyIndex(); return getData()->force[getIndex()]; }
847 
848  AGX_FORCE_INLINE agx::Real& ParticleInstance::life() { verifyIndex(); return getData()->life[getIndex()]; }
849  AGX_FORCE_INLINE agx::Real const& ParticleInstance::life() const { verifyIndex(); return getData()->life[getIndex()]; }
850 
851  AGX_FORCE_INLINE agx::Real& ParticleInstance::radius() { verifyIndex(); return getData()->radius[getIndex()]; }
852  AGX_FORCE_INLINE agx::Real const& ParticleInstance::radius() const { verifyIndex(); return getData()->radius[getIndex()]; }
853 
854  AGX_FORCE_INLINE agx::Real& ParticleInstance::mass() { verifyIndex(); return getData()->mass[getIndex()]; }
855  AGX_FORCE_INLINE agx::Real const& ParticleInstance::mass() const { verifyIndex(); return getData()->mass[getIndex()]; }
856 
857  AGX_FORCE_INLINE agx::Real& ParticleInstance::invMass() { verifyIndex(); return getData()->invMass[getIndex()]; }
858  AGX_FORCE_INLINE agx::Real const& ParticleInstance::invMass() const { verifyIndex(); return getData()->invMass[getIndex()]; }
859 
860  AGX_FORCE_INLINE agx::Physics::MaterialPtr& ParticleInstance::material() { verifyIndex(); return getData()->material[getIndex()]; }
861  AGX_FORCE_INLINE agx::Physics::MaterialPtr const& ParticleInstance::material() const { verifyIndex(); return getData()->material[getIndex()]; }
862 
863  AGX_FORCE_INLINE agx::Uuid& ParticleInstance::materialUuid() { verifyIndex(); return getData()->materialUuid[getIndex()]; }
864  AGX_FORCE_INLINE agx::Uuid const& ParticleInstance::materialUuid() const { verifyIndex(); return getData()->materialUuid[getIndex()]; }
865 
866  AGX_FORCE_INLINE agx::Physics::CollisionGroupSetPtr& ParticleInstance::collisionGroupSet() { verifyIndex(); return getData()->collisionGroupSet[getIndex()]; }
867  AGX_FORCE_INLINE agx::Physics::CollisionGroupSetPtr const& ParticleInstance::collisionGroupSet() const { verifyIndex(); return getData()->collisionGroupSet[getIndex()]; }
868 
869  AGX_FORCE_INLINE agx::UInt8& ParticleInstance::tier() { verifyIndex(); return getData()->tier[getIndex()]; }
870  AGX_FORCE_INLINE agx::UInt8 const& ParticleInstance::tier() const { verifyIndex(); return getData()->tier[getIndex()]; }
871 
872  AGX_FORCE_INLINE agx::UInt32& ParticleInstance::cellIndex() { verifyIndex(); return getData()->cellIndex[getIndex()]; }
873  AGX_FORCE_INLINE agx::UInt32 const& ParticleInstance::cellIndex() const { verifyIndex(); return getData()->cellIndex[getIndex()]; }
874 
875  AGX_FORCE_INLINE agx::UInt16& ParticleInstance::cellSlot() { verifyIndex(); return getData()->cellSlot[getIndex()]; }
876  AGX_FORCE_INLINE agx::UInt16 const& ParticleInstance::cellSlot() const { verifyIndex(); return getData()->cellSlot[getIndex()]; }
877 
878  AGX_FORCE_INLINE agx::UInt32& ParticleInstance::oldCell() { verifyIndex(); return getData()->oldCell[getIndex()]; }
879  AGX_FORCE_INLINE agx::UInt32 const& ParticleInstance::oldCell() const { verifyIndex(); return getData()->oldCell[getIndex()]; }
880 
881  AGX_FORCE_INLINE agx::UInt32& ParticleInstance::geometryContactList() { verifyIndex(); return getData()->geometryContactList[getIndex()]; }
882  AGX_FORCE_INLINE agx::UInt32 const& ParticleInstance::geometryContactList() const { verifyIndex(); return getData()->geometryContactList[getIndex()]; }
883 
884  AGX_FORCE_INLINE agx::UInt32& ParticleInstance::solveBodyIndex() { verifyIndex(); return getData()->solveBodyIndex[getIndex()]; }
885  AGX_FORCE_INLINE agx::UInt32 const& ParticleInstance::solveBodyIndex() const { verifyIndex(); return getData()->solveBodyIndex[getIndex()]; }
886 
887  AGX_FORCE_INLINE agx::Physics::GraphNodePtr& ParticleInstance::graphNode() { verifyIndex(); return getData()->graphNode[getIndex()]; }
888  AGX_FORCE_INLINE agx::Physics::GraphNodePtr const& ParticleInstance::graphNode() const { verifyIndex(); return getData()->graphNode[getIndex()]; }
889 
890  AGX_FORCE_INLINE agx::Vec4f& ParticleInstance::color() { verifyIndex(); return getData()->color[getIndex()]; }
891  AGX_FORCE_INLINE agx::Vec4f const& ParticleInstance::color() const { verifyIndex(); return getData()->color[getIndex()]; }
892 
893  AGX_FORCE_INLINE agx::Vec3& ParticleInstance::geometryContactVector() { verifyIndex(); return getData()->geometryContactVector[getIndex()]; }
894  AGX_FORCE_INLINE agx::Vec3 const& ParticleInstance::geometryContactVector() const { verifyIndex(); return getData()->geometryContactVector[getIndex()]; }
895 
896  AGX_FORCE_INLINE agx::Real32& ParticleInstance::enableRendering() { verifyIndex(); return getData()->enableRendering[getIndex()]; }
897  AGX_FORCE_INLINE agx::Real32 const& ParticleInstance::enableRendering() const { verifyIndex(); return getData()->enableRendering[getIndex()]; }
898 
899  //-----------------------------------------------------------------------------------------------------
900  AGX_FORCE_INLINE ParticleSemantics::ParticleSemantics() {}
901  //-----------------------------------------------------------------------------------------------------
903  }
904 }
905 
906 AGX_TYPE_BINDING(agx::Physics::ParticlePtr, "Physics.ParticlePtr")
907 AGX_TYPE_BINDING(agx::Physics::ParticleInstance, "Physics.ParticleInstance")
908 
909 #ifdef _MSC_VER
910 # pragma warning(pop)
911 #endif
912 
913 #undef AGX_ENTITY_WRAPPER
914 #undef AGX_ENTITY_NAMESPACE
915 #endif
916 
agx::Physics::ParticleModel::graphNodeAttribute
static agxData::ScalarAttributeT< agx::Physics::GraphNodePtr > * graphNodeAttribute
Definition: ParticleEntity.h:123
agx::Physics::ParticleModel::invMassAttribute
static agxData::ScalarAttributeT< agx::Real > * invMassAttribute
Definition: ParticleEntity.h:113
agx::Physics::ParticleModel::massAttribute
static agxData::ScalarAttributeT< agx::Real > * massAttribute
Definition: ParticleEntity.h:112
agx::Physics::ParticleModel::defaultMassAttribute
static agxData::SharedAttributeT< agx::Real > * defaultMassAttribute
Definition: ParticleEntity.h:102
agxData::Value
Abstract representation of a value.
Definition: Value.h:42
agx::Physics::ParticleModel::PtrT
ParticlePtr PtrT
Definition: ParticleEntity.h:81
agx::Physics::ParticleModel::forceAttribute
static agxData::ScalarAttributeT< agx::Vec3 > * forceAttribute
Definition: ParticleEntity.h:109
agx::Real
double Real
Definition: Real.h:42
agxData::ScalarAttributeT< agx::ParticleState >
agx::Physics::ParticleModel::velocityAttribute
static agxData::ScalarAttributeT< agx::Vec3 > * velocityAttribute
Definition: ParticleEntity.h:107
agxData::EntityModel
An abstract description of a data entity stored using SOA (structure of arrays) pattern in a EntitySt...
Definition: EntityModel.h:63
agx::Physics::ParticleModel::materialUuidAttribute
static agxData::ScalarAttributeT< agx::Uuid > * materialUuidAttribute
Definition: ParticleEntity.h:115
ParticleState.h
CALLABLE
#define CALLABLE
Definition: macros.h:72
agx::Physics::ParticleModel::colorAttribute
static agxData::ScalarAttributeT< agx::Vec4f > * colorAttribute
Definition: ParticleEntity.h:124
DOXYGEN_END_INTERNAL_BLOCK
#define DOXYGEN_END_INTERNAL_BLOCK()
Definition: macros.h:97
agxData::EntityPtr::getData
agxData::EntityData * getData()
Definition: EntityStorage.h:594
agx::Physics::ParticleModel::defaultInvMassAttribute
static agxData::SharedAttributeT< agx::Real > * defaultInvMassAttribute
Definition: ParticleEntity.h:105
agx::Physics::ParticleModel
Abstract description of the data attributes for the Physics.Particle entity.
Definition: ParticleEntity.h:78
DOXYGEN_START_INTERNAL_BLOCK
#define DOXYGEN_START_INTERNAL_BLOCK()
Definition: macros.h:96
agx::Physics::ParticleModel::stateAttribute
static agxData::ScalarAttributeT< agx::ParticleState > * stateAttribute
Definition: ParticleEntity.h:100
macros.h
agx::Real32
float Real32
Definition: Real.h:44
MaterialEntity.h
agxData::EntityPtr::isInstanceOf
bool isInstanceOf(agxData::EntityModel *model) const
Definition: EntityStorage.h:784
agx::Physics::MaterialPtr
Pointer to a entity instance of type Physics.Material.
Definition: MaterialEntity.h:190
agx::Model::fullPath
agx::String fullPath() const
agx::Vec4T
A class holding 4 dimensional vectors and providing basic arithmetic.
Definition: Vec4Template.h:34
agxData::EntityStorage
Data storage for a collection of entity instances of a specified EntityModel.
Definition: EntityStorage.h:72
EntityModel.h
agx::VectorPOD
Vector containing 'raw' data.
Definition: Vector.h:245
agxData::EntityPtr::instance
agxData::EntityInstance instance()
Definition: EntityPtr.h:269
agx::Physics::ParticlePtr::ParticlePtr
AGXPHYSICS_EXPORT ParticlePtr()
CollisionGroupSetEntity.h
agxData::EntityInstance::isInstanceOf
bool isInstanceOf(agxData::EntityModel *model) const
Definition: EntityStorage.h:829
agx
The agx namespace contains the dynamics/math part of the AGX Dynamics API.
Definition: AddedMassInteraction.h:22
AGXPHYSICS_EXPORT
#define AGXPHYSICS_EXPORT
agx::Physics::ParticleModel::enableRenderingAttribute
static agxData::ScalarAttributeT< agx::Real32 > * enableRenderingAttribute
Definition: ParticleEntity.h:126
agxData
Contains classes for low level data storage for AGX.
Definition: Container.h:23
Vec4.h
agx::Physics::ParticleModel::oldVelocityAttribute
static agxData::ScalarAttributeT< agx::Vec3 > * oldVelocityAttribute
Definition: ParticleEntity.h:108
agxData::Array
Type-specific Array used for fast access into the data held by a Buffer.
Definition: agxData.h:30
agx::Physics::ParticleModel::lifeAttribute
static agxData::ScalarAttributeT< agx::Real > * lifeAttribute
Definition: ParticleEntity.h:110
agx::Physics::ParticleModel::radiusAttribute
static agxData::ScalarAttributeT< agx::Real > * radiusAttribute
Definition: ParticleEntity.h:111
EntityStorage.h
EntityRef.h
agx::Physics::ParticlePtr
Pointer to a entity instance of type Physics.Particle.
Definition: ParticleEntity.h:292
agx::UInt16
uint16_t UInt16
Definition: Integer.h:39
agx::Physics::ParticleModel::positionAttribute
static agxData::ScalarAttributeT< agx::Vec3 > * positionAttribute
Definition: ParticleEntity.h:106
EntityPtr.h
Vec3.h
agx::UInt8
uint8_t UInt8
Definition: Integer.h:38
EntityInstance.h
Integer.h
agxData::EntityPtr::operator=
EntityPtr & operator=(const EntityPtr &other)=default
agx::Index
UInt32 Index
Definition: Integer.h:52
agx::Physics::GraphNodePtr
Pointer to a entity instance of type Physics.GraphNode.
Definition: GraphNodeEntity.h:193
agx::Physics::ParticleModel::defaultCollisionGroupSetAttribute
static agxData::SharedAttributeT< agx::Physics::CollisionGroupSetPtr > * defaultCollisionGroupSetAttribute
Definition: ParticleEntity.h:104
agx::Physics::ParticleModel::defaultMaterialAttribute
static agxData::SharedAttributeT< agx::Physics::MaterialPtr > * defaultMaterialAttribute
Definition: ParticleEntity.h:103
agx::Physics::ParticleModel::oldCellAttribute
static agxData::ScalarAttributeT< agx::UInt32 > * oldCellAttribute
Definition: ParticleEntity.h:120
agx::Physics::ParticleModel::collisionGroupSetAttribute
static agxData::ScalarAttributeT< agx::Physics::CollisionGroupSetPtr > * collisionGroupSetAttribute
Definition: ParticleEntity.h:116
agx::Physics::ParticleModel::cellIndexAttribute
static agxData::ScalarAttributeT< agx::UInt32 > * cellIndexAttribute
Definition: ParticleEntity.h:118
agx::Physics::ParticlePtr::ModelType
ParticleModel ModelType
Definition: ParticleEntity.h:295
agxData::EntityInstance
Entity instance provides access to a single instance in an EntityStorage.
Definition: EntityInstance.h:43
agx::Physics::ParticleModel::solveBodyIndexAttribute
static agxData::ScalarAttributeT< agx::UInt32 > * solveBodyIndexAttribute
Definition: ParticleEntity.h:122
agxData::EntityInstance::getData
agxData::EntityData * getData()
Definition: EntityInstance.h:149
Uuid.h
agx::Physics::ParticleModel::tierAttribute
static agxData::ScalarAttributeT< agx::UInt8 > * tierAttribute
Definition: ParticleEntity.h:117
AGX_DECLARE_POINTER_TYPES
#define AGX_DECLARE_POINTER_TYPES(type)
Definition: Referenced.h:248
agx::Physics::ParticleModel::instance
static ParticleModel * instance()
agxData::SharedAttributeT< agx::Real >
agx::Physics::ParticlePtr::InstanceType
ParticleInstance InstanceType
Definition: ParticleEntity.h:297
agx::AgXString< std::string >
agxAssertN
#define agxAssertN(expr, format,...)
Definition: debug.h:145
agx::Physics::ParticleModel::defaultRadiusAttribute
static agxData::SharedAttributeT< agx::Real > * defaultRadiusAttribute
Definition: ParticleEntity.h:101
AGX_TYPE_BINDING
#define AGX_TYPE_BINDING(_Type, _Name)
Definition: Type.h:179
agx::Physics::ParticleModel::cellSlotAttribute
static agxData::ScalarAttributeT< agx::UInt16 > * cellSlotAttribute
Definition: ParticleEntity.h:119
agx::Physics::ParticlePtr::DataType
ParticleData DataType
Definition: ParticleEntity.h:296
agx::Vec3T< Real >
agx::Uuid
A UUID, or Universally unique identifier, is intended to uniquely identify information in a distribut...
Definition: Uuid.h:41
agx::Physics::ParticleModel::materialAttribute
static agxData::ScalarAttributeT< agx::Physics::MaterialPtr > * materialAttribute
Definition: ParticleEntity.h:114
agx::Physics::ParticleModel::geometryContactListAttribute
static agxData::ScalarAttributeT< agx::UInt32 > * geometryContactListAttribute
Definition: ParticleEntity.h:121
Real.h
agx::Physics::ParticleModel::geometryContactVectorAttribute
static agxData::ScalarAttributeT< agx::Vec3 > * geometryContactVectorAttribute
Definition: ParticleEntity.h:125
agx::UInt32
uint32_t UInt32
Definition: Integer.h:40
agxData::EntityPtr
Accessor to a entity instance stored in a EntityStorage, to allow SOA (structure of arrays) data to b...
Definition: EntityPtr.h:51
agx::Physics::CollisionGroupSetPtr
Pointer to a entity instance of type Physics.CollisionGroupSet.
Definition: CollisionGroupSetEntity.h:175
AGX_FORCE_INLINE
#define AGX_FORCE_INLINE
Definition: macros.h:58
GraphNodeEntity.h
agx::getModel
AGXCORE_EXPORT Model * getModel(const Path &path, const Path &_namespace=Path())
Definition: Object.h:364