21#ifndef GENERATED_AGX_PHYSICS_HIERARCHICALGRID_GRIDTIER2D_H_PLUGIN
22#define GENERATED_AGX_PHYSICS_HIERARCHICALGRID_GRIDTIER2D_H_PLUGIN
24#define AGX_ENTITY_WRAPPER 1
30# pragma warning( disable : 4505 )
32# pragma warning( disable : 4251 )
34# pragma warning( disable : 4355 )
36# pragma warning( disable: 4714 )
55 namespace HierarchicalGrid
58 class GridTier2DModel;
61 class GridTier2DInstance;
62 class GridTier2DSemantics;
100 virtual void configure(agx::TiXmlElement* eEntity)
override;
108 #ifndef AGX_PHYSICS_HIERARCHICALGRID_GRIDTIER2D_DATA_SET_OVERRIDE
109 #define AGX_PHYSICS_HIERARCHICALGRID_GRIDTIER2D_DATA_SET
113 GridTier2DInstance operator[] (
size_t index);
133 virtual ~GridTier2DData() {}
134 virtual void setNumElements(
agx::Index numElements)
override;
137 GridTier2DData& operator= (
const GridTier2DData&) {
return *
this; }
152 agx::Real const& getBoundingRadius()
const;
160 void setBoundingRadius(
agx::Real const& value);
165 friend class GridTier2DPtr;
166 friend class GridTier2DInstance;
167 GridTier2DSemantics();
226 GridTier2DInstance();
227 GridTier2DInstance(GridTier2DData* data,
agx::Index index);
232 GridTier2DData* getData();
233 const GridTier2DData* getData()
const;
270 inline GridTier2DInstance
agx::Physics::HierarchicalGrid::GridTier2DData::operator[] (
size_t index) {
return GridTier2DInstance(
this, (
agx::Index)index); }
277 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
284 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
292 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
293 EntityPtr::getModel()->fullPath().c_str(), GridTier2DModel::instance()->fullPath().c_str());
301 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
302 EntityPtr::getModel()->fullPath().c_str(), GridTier2DModel::instance()->fullPath().c_str());
308 AGX_FORCE_INLINE GridTier2DSemantics* GridTier2DPtr::operator->() {
return (GridTier2DSemantics* )
this; }
309 AGX_FORCE_INLINE const GridTier2DSemantics* GridTier2DPtr::operator->()
const {
return (
const GridTier2DSemantics* )
this; }
314 AGX_FORCE_INLINE agx::Real const& GridTier2DPtr::size()
const { verifyIndex();
return getData()->size[calculateIndex()]; }
317 AGX_FORCE_INLINE agx::Real const& GridTier2DPtr::invSize()
const { verifyIndex();
return getData()->invSize[calculateIndex()]; }
319 AGX_FORCE_INLINE agx::Real& GridTier2DPtr::boundingRadius() { verifyIndex();
return getData()->boundingRadius[calculateIndex()]; }
320 AGX_FORCE_INLINE agx::Real const& GridTier2DPtr::boundingRadius()
const { verifyIndex();
return getData()->boundingRadius[calculateIndex()]; }
332 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
339 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
348 AGX_FORCE_INLINE agx::Real const& GridTier2DInstance::size()
const { verifyIndex();
return getData()->size[getIndex()]; }
351 AGX_FORCE_INLINE agx::Real const& GridTier2DInstance::invSize()
const { verifyIndex();
return getData()->invSize[getIndex()]; }
353 AGX_FORCE_INLINE agx::Real& GridTier2DInstance::boundingRadius() { verifyIndex();
return getData()->boundingRadius[getIndex()]; }
354 AGX_FORCE_INLINE agx::Real const& GridTier2DInstance::boundingRadius()
const { verifyIndex();
return getData()->boundingRadius[getIndex()]; }
368AGX_TYPE_BINDING(
agx::Physics::HierarchicalGrid::GridTier2DInstance, "Physics.HierarchicalGrid.GridTier2DInstance")
374#undef AGX_ENTITY_WRAPPER
375#undef AGX_ENTITY_NAMESPACE
#define AGX_DECLARE_POINTER_TYPES(type)
#define AGX_TYPE_BINDING(_Type, _Name)
#define AGXPHYSICS_EXPORT
Type-specific Array used for fast access into the data held by a Buffer.
Entity instance provides access to a single instance in an EntityStorage.
bool isInstanceOf(agxData::EntityModel *model) const
agxData::EntityData * getData()
An abstract description of a data entity stored using SOA (structure of arrays) pattern in a EntitySt...
Accessor to a entity instance stored in a EntityStorage, to allow SOA (structure of arrays) data to b...
EntityPtr & operator=(const EntityPtr &other)=default
bool isInstanceOf(agxData::EntityModel *model) const
agxData::EntityData * getData()
agxData::EntityInstance instance()
Data storage for a collection of entity instances of a specified EntityModel.
agx::String fullPath() const
Abstract description of the data attributes for the Physics.HierarchicalGrid.GridTier2D entity.
virtual agxData::EntityData * createData(agxData::EntityStorage *storage) override
virtual void configure(agx::TiXmlElement *eEntity) override
GridTier2DModel(const agx::String &name="GridTier2D")
static GridTier2DModel * instance()
static GridTier2DPtr createInstance()
Create and return a pointer to a new instance in the default storage for this entity model.
void construct(agx::Physics::HierarchicalGrid::GridTier2DPtr gridTier2D)
static agxData::ScalarAttributeT< agx::Real > * boundingRadiusAttribute
static agxData::ScalarAttributeT< agx::Real > * invSizeAttribute
static agxData::ScalarAttributeT< agx::Real > * sizeAttribute
static agxData::PointerAttributeT< agx::GridCell2DTable * > * cellTableAttribute
static agxData::EntityStorage * defaultStorage()
virtual void shutdownCleanup() override
This is part of internal cleanup and should not be called by users.
virtual ~GridTier2DModel()
virtual void construct(agxData::EntityPtr instance) override
virtual void initAttributeAccessors() override
Pointer to a entity instance of type Physics.HierarchicalGrid.GridTier2D.
const GridTier2DData * getData() const
AGXPHYSICS_EXPORT agx::Real const & invSize() const
GridTier2DData * getData()
AGXPHYSICS_EXPORT agx::Real & boundingRadius()
AGXPHYSICS_EXPORT agx::GridCell2DTable *const & cellTable() const
AGXPHYSICS_EXPORT GridTier2DPtr(const agxData::EntityInstance &instance)
AGXPHYSICS_EXPORT agx::Real const & size() const
AGXPHYSICS_EXPORT agx::Real & invSize()
AGXPHYSICS_EXPORT const GridTier2DSemantics * operator->() const
AGXPHYSICS_EXPORT GridTier2DPtr(agxData::EntityStorage *storage, agx::Index id)
AGXPHYSICS_EXPORT agx::Real & size()
GridTier2DInstance InstanceType
AGXPHYSICS_EXPORT agx::GridCell2DTable *& cellTable()
AGXPHYSICS_EXPORT GridTier2DInstance instance()
AGXPHYSICS_EXPORT GridTier2DPtr(const agxData::EntityPtr &ptr)
AGXPHYSICS_EXPORT const GridTier2DInstance instance() const
GridTier2DModel ModelType
AGXPHYSICS_EXPORT agx::Real const & boundingRadius() const
AGXPHYSICS_EXPORT GridTier2DSemantics * operator->()
AGXPHYSICS_EXPORT GridTier2DPtr()
Vector containing 'raw' data.
#define agxAssertN(expr, format,...)
#define DOXYGEN_END_INTERNAL_BLOCK()
#define DOXYGEN_START_INTERNAL_BLOCK()
Contains classes for low level data storage for AGX.
The agx namespace contains the dynamics/math part of the AGX Dynamics API.