21 #ifndef GENERATED_AGX_PHYSICS_BODYCONTACT_H_PLUGIN
22 #define GENERATED_AGX_PHYSICS_BODYCONTACT_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 class BodyContactModel;
56 class BodyContactData;
58 class BodyContactInstance;
59 class BodyContactSemantics;
84 virtual void shutdownCleanup()
override;
96 virtual void configure(agx::TiXmlElement* eEntity)
override;
97 virtual void initAttributeAccessors()
override;
104 #ifndef AGX_PHYSICS_BODYCONTACT_DATA_SET_OVERRIDE
105 #define AGX_PHYSICS_BODYCONTACT_DATA_SET
109 BodyContactInstance operator[] (
size_t index);
120 typedef agx::Int contactListOffsetType;
127 virtual ~BodyContactData() {}
128 virtual void setNumElements(
agx::Index numElements)
override;
131 BodyContactData& operator= (
const BodyContactData&) {
return *
this; }
146 agx::Int const& getContactListOffset()
const;
151 void setBody1(
agx::Int const& value);
152 void setBody2(
agx::Int const& value);
153 void setContactListOffset(
agx::Int const& value);
157 friend class BodyContactPtr;
158 friend class BodyContactInstance;
159 BodyContactSemantics();
187 BodyContactData* getData();
188 const BodyContactData* getData()
const;
208 #ifdef AGX_GENERATED_TOLUA_WRAPPER
209 inline agx::Int const& getBody1()
const {
return (*this)->getBody1(); }
210 inline agx::Int const& getBody2()
const {
return (*this)->getBody2(); }
211 inline agx::Int const& getContactListOffset()
const {
return (*this)->getContactListOffset(); }
214 inline void setBody1(
agx::Int const& value) { (*this)->setBody1(value); }
215 inline void setBody2(
agx::Int const& value) { (*this)->setBody2(value); }
216 inline void setContactListOffset(
agx::Int const& value) { (*this)->setContactListOffset(value); }
227 BodyContactInstance();
228 BodyContactInstance(BodyContactData* data,
agx::Index index);
233 BodyContactData* getData();
234 const BodyContactData* getData()
const;
250 agx::Int const& contactListOffset()
const;
266 inline BodyContactInstance agx::Physics::BodyContactData::operator[] (
size_t index) {
return BodyContactInstance(
this, (
agx::Index)index); }
273 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
280 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
288 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
297 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
304 AGX_FORCE_INLINE BodyContactSemantics* BodyContactPtr::operator->() {
return (BodyContactSemantics* )
this; }
305 AGX_FORCE_INLINE const BodyContactSemantics* BodyContactPtr::operator->()
const {
return (
const BodyContactSemantics* )
this; }
310 AGX_FORCE_INLINE agx::Int const& BodyContactPtr::body1()
const { verifyIndex();
return getData()->body1[calculateIndex()]; }
313 AGX_FORCE_INLINE agx::Int const& BodyContactPtr::body2()
const { verifyIndex();
return getData()->body2[calculateIndex()]; }
315 AGX_FORCE_INLINE agx::Int& BodyContactPtr::contactListOffset() { verifyIndex();
return getData()->contactListOffset[calculateIndex()]; }
316 AGX_FORCE_INLINE agx::Int const& BodyContactPtr::contactListOffset()
const { verifyIndex();
return getData()->contactListOffset[calculateIndex()]; }
320 AGX_FORCE_INLINE BodyContactInstance::BodyContactInstance(BodyContactData* data,
agx::Index index) : agxData::EntityInstance(data, index) {}
325 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
332 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
341 AGX_FORCE_INLINE agx::Int const& BodyContactInstance::body1()
const { verifyIndex();
return getData()->body1[getIndex()]; }
344 AGX_FORCE_INLINE agx::Int const& BodyContactInstance::body2()
const { verifyIndex();
return getData()->body2[getIndex()]; }
346 AGX_FORCE_INLINE agx::Int& BodyContactInstance::contactListOffset() { verifyIndex();
return getData()->contactListOffset[getIndex()]; }
347 AGX_FORCE_INLINE agx::Int const& BodyContactInstance::contactListOffset()
const { verifyIndex();
return getData()->contactListOffset[getIndex()]; }
357 AGX_TYPE_BINDING(agx::Physics::BodyContactInstance, "Physics.BodyContactInstance")
360 # pragma warning(pop)
363 #undef AGX_ENTITY_WRAPPER
364 #undef AGX_ENTITY_NAMESPACE
agxData::EntityData * getData()
agxData::EntityInstance instance()
Abstract description of the data attributes for the Physics.BodyContact entity.
Data storage for a collection of entity instances of a specified EntityModel.
AGXPHYSICS_EXPORT BodyContactPtr()
#define agxAssertN(expr, format,...)
agxData::EntityData * getData()
#define AGX_TYPE_BINDING(_Type, _Name)
AGXCORE_EXPORT Model * getModel(const Path &path, const Path &_namespace=Path())
BodyContactModel ModelType
bool isInstanceOf(agxData::EntityModel *model) const
static agxData::ScalarAttributeT< agx::Int > * body1Attribute
#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
BodyContactInstance InstanceType
Type-specific Array used for fast access into the data held by a Buffer.
static agxData::ScalarAttributeT< agx::Int > * contactListOffsetAttribute
static BodyContactModel * instance()
Vector containing 'raw' data.
EntityPtr & operator=(const EntityPtr &other)=default
An abstract description of a data entity stored using SOA (structure of arrays) pattern in a EntitySt...
bool isInstanceOf(agxData::EntityModel *model) const
static agxData::ScalarAttributeT< agx::Int > * body2Attribute
Pointer to a entity instance of type Physics.BodyContact.
#define DOXYGEN_END_INTERNAL_BLOCK()
#define DOXYGEN_START_INTERNAL_BLOCK()