21 #ifndef GENERATED_AGX_PHYSICS_HIERARCHICALGRID_GRIDTIER_H_PLUGIN
22 #define GENERATED_AGX_PHYSICS_HIERARCHICALGRID_GRIDTIER_H_PLUGIN
24 #define AGX_ENTITY_WRAPPER 1
28 # pragma warning(push)
30 # pragma warning( disable : 4505 )
32 # pragma warning( disable : 4251 )
34 # pragma warning( disable : 4355 )
36 # pragma warning( disable: 4714 )
55 namespace HierarchicalGrid
61 class GridTierInstance;
62 class GridTierSemantics;
87 virtual void shutdownCleanup()
override;
101 virtual void configure(agx::TiXmlElement* eEntity)
override;
102 virtual void initAttributeAccessors()
override;
109 #ifndef AGX_PHYSICS_HIERARCHICALGRID_GRIDTIER_DATA_SET_OVERRIDE
110 #define AGX_PHYSICS_HIERARCHICALGRID_GRIDTIER_DATA_SET
114 GridTierInstance operator[] (
size_t index);
136 virtual ~GridTierData() {}
137 virtual void setNumElements(
agx::Index numElements)
override;
140 GridTierData& operator= (
const GridTierData&) {
return *
this; }
170 friend class GridTierPtr;
171 friend class GridTierInstance;
200 GridTierData* getData();
201 const GridTierData* getData()
const;
231 #ifdef AGX_GENERATED_TOLUA_WRAPPER
232 inline agx::Real const& getSize()
const {
return (*this)->getSize(); }
233 inline agx::Real const& getInvSize()
const {
return (*this)->getInvSize(); }
234 inline agx::Real32 const& getBoundingRadius()
const {
return (*this)->getBoundingRadius(); }
235 inline agx::GridCellTable*
const& getCellTable()
const {
return (*this)->getCellTable(); }
239 inline void setSize(
agx::Real const& value) { (*this)->setSize(value); }
240 inline void setInvSize(
agx::Real const& value) { (*this)->setInvSize(value); }
241 inline void setBoundingRadius(
agx::Real32 const& value) { (*this)->setBoundingRadius(value); }
242 inline void setCellTable(
agx::GridCellTable*
const& value) { (*this)->setCellTable(value); }
255 GridTierInstance(GridTierData* data,
agx::Index index);
260 GridTierData* getData();
261 const GridTierData* getData()
const;
303 inline GridTierInstance agx::Physics::HierarchicalGrid::GridTierData::operator[] (
size_t index) {
return GridTierInstance(
this, (
agx::Index)index); }
310 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
317 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
325 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
334 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
341 AGX_FORCE_INLINE GridTierSemantics* GridTierPtr::operator->() {
return (GridTierSemantics* )
this; }
342 AGX_FORCE_INLINE const GridTierSemantics* GridTierPtr::operator->()
const {
return (
const GridTierSemantics* )
this; }
350 AGX_FORCE_INLINE agx::Real const& GridTierPtr::invSize()
const { verifyIndex();
return getData()->invSize[calculateIndex()]; }
353 AGX_FORCE_INLINE agx::Real32 const& GridTierPtr::boundingRadius()
const { verifyIndex();
return getData()->boundingRadius[calculateIndex()]; }
363 AGX_FORCE_INLINE GridTierInstance::GridTierInstance(GridTierData* data,
agx::Index index) : agxData::EntityInstance(data, index) {}
368 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
375 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
387 AGX_FORCE_INLINE agx::Real const& GridTierInstance::invSize()
const { verifyIndex();
return getData()->invSize[getIndex()]; }
390 AGX_FORCE_INLINE agx::Real32 const& GridTierInstance::boundingRadius()
const { verifyIndex();
return getData()->boundingRadius[getIndex()]; }
407 AGX_TYPE_BINDING(agx::Physics::HierarchicalGrid::GridTierInstance, "Physics.HierarchicalGrid.GridTierInstance")
410 # pragma warning(pop)
413 #undef AGX_ENTITY_WRAPPER
414 #undef AGX_ENTITY_NAMESPACE
static agxData::ScalarAttributeT< agx::Real > * sizeAttribute
agxData::EntityData * getData()
agxData::EntityInstance instance()
Data storage for a collection of entity instances of a specified EntityModel.
#define agxAssertN(expr, format,...)
agxData::EntityData * getData()
#define AGX_TYPE_BINDING(_Type, _Name)
AGXCORE_EXPORT Model * getModel(const Path &path, const Path &_namespace=Path())
bool isInstanceOf(agxData::EntityModel *model) const
#define AGXPHYSICS_EXPORT
Entity instance provides access to a single instance in an EntityStorage.
Accessor to a entity instance stored in a EntityStorage, to allow SOA (structure of arrays) data to b...
#define AGX_DECLARE_POINTER_TYPES(type)
agx::String fullPath() const
Type-specific Array used for fast access into the data held by a Buffer.
static agxData::PointerAttributeT< agx::GridCellTable * > * cellTableAttribute
GridTierInstance InstanceType
static GridTierModel * instance()
Vector containing 'raw' data.
EntityPtr & operator=(const EntityPtr &other)=default
static agxData::PointerAttributeT< agx::ContactZoneTable * > * zoneTableAttribute
static agxData::ScalarAttributeT< agx::Real > * invSizeAttribute
An abstract description of a data entity stored using SOA (structure of arrays) pattern in a EntitySt...
Abstract description of the data attributes for the Physics.HierarchicalGrid.GridTier entity...
bool isInstanceOf(agxData::EntityModel *model) const
static agxData::ScalarAttributeT< agx::Real32 > * boundingRadiusAttribute
Pointer to a entity instance of type Physics.HierarchicalGrid.GridTier.
Inheritance with partial specialization due to bug with ref_ptr containers.
#define DOXYGEN_END_INTERNAL_BLOCK()
AGXPHYSICS_EXPORT GridTierPtr()
#define DOXYGEN_START_INTERNAL_BLOCK()