21#ifndef GENERATED_AGX_PHYSICS_GRANULARBODY_CONTACTCONSTRAINT_H_PLUGIN
22#define GENERATED_AGX_PHYSICS_GRANULARBODY_CONTACTCONSTRAINT_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 )
56 namespace GranularBody
59 class ContactConstraintModel;
60 class ContactConstraintData;
61 class ContactConstraintPtr;
62 class ContactConstraintInstance;
63 class ContactConstraintSemantics;
115 virtual void configure(agx::TiXmlElement* eEntity)
override;
123 #ifndef AGX_PHYSICS_GRANULARBODY_CONTACTCONSTRAINT_DATA_SET_OVERRIDE
124 #define AGX_PHYSICS_GRANULARBODY_CONTACTCONSTRAINT_DATA_SET
128 ContactConstraintInstance operator[] (
size_t index);
167 typedef agx::Real nonlinearMultiplierType;
168 typedef agx::Real rollingResistanceMuType;
169 typedef agx::Real twistLimitMultiplierType;
173 ContactConstraintData();
176 virtual ~ContactConstraintData() {}
177 virtual void setNumElements(
agx::Index numElements)
override;
180 ContactConstraintData& operator= (
const ContactConstraintData&) {
return *
this; }
204 agx::Real const& getRestingCompliance()
const;
205 agx::Real const& getCharContactTime()
const;
208 agx::Real const& getNonlinearMultiplier()
const;
209 agx::Real const& getRollingResistanceMu()
const;
210 agx::Real const& getTwistLimitMultiplier()
const;
225 void setIsImpacting(
agx::Bool const& value);
226 void setRestingCompliance(
agx::Real const& value);
227 void setCharContactTime(
agx::Real const& value);
228 void setCharMass(
agx::Real const& value);
230 void setNonlinearMultiplier(
agx::Real const& value);
231 void setRollingResistanceMu(
agx::Real const& value);
232 void setTwistLimitMultiplier(
agx::Real const& value);
236 friend class ContactConstraintPtr;
237 friend class ContactConstraintInstance;
238 ContactConstraintSemantics();
367 ContactConstraintInstance();
368 ContactConstraintInstance(ContactConstraintData* data,
agx::Index index);
373 ContactConstraintData* getData();
374 const ContactConstraintData* getData()
const;
435 agx::Real const& restingCompliance()
const;
440 agx::Real const& charContactTime()
const;
455 agx::Real const& nonlinearMultiplier()
const;
460 agx::Real const& rollingResistanceMu()
const;
465 agx::Real const& twistLimitMultiplier()
const;
481 inline ContactConstraintInstance
agx::Physics::GranularBody::ContactConstraintData::operator[] (
size_t index) {
return ContactConstraintInstance(
this, (
agx::Index)index); }
488 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
495 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
503 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
512 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
585 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
592 "Entity type mismatch. Storage contains entity data for type \'%s\', instance pointer is of type \'%s\'",
601 AGX_FORCE_INLINE agx::UInt32 const& ContactConstraintInstance::body1()
const { verifyIndex();
return getData()->body1[getIndex()]; }
604 AGX_FORCE_INLINE agx::UInt32 const& ContactConstraintInstance::body2()
const { verifyIndex();
return getData()->body2[getIndex()]; }
607 AGX_FORCE_INLINE agx::UInt32 const& ContactConstraintInstance::solveBody1()
const { verifyIndex();
return getData()->solveBody1[getIndex()]; }
610 AGX_FORCE_INLINE agx::UInt32 const& ContactConstraintInstance::solveBody2()
const { verifyIndex();
return getData()->solveBody2[getIndex()]; }
612 AGX_FORCE_INLINE agx::UInt32& ContactConstraintInstance::cachedContactId() { verifyIndex();
return getData()->cachedContactId[getIndex()]; }
613 AGX_FORCE_INLINE agx::UInt32 const& ContactConstraintInstance::cachedContactId()
const { verifyIndex();
return getData()->cachedContactId[getIndex()]; }
615 AGX_FORCE_INLINE agx::UInt32& ContactConstraintInstance::contactIndex() { verifyIndex();
return getData()->contactIndex[getIndex()]; }
616 AGX_FORCE_INLINE agx::UInt32 const& ContactConstraintInstance::contactIndex()
const { verifyIndex();
return getData()->contactIndex[getIndex()]; }
618 AGX_FORCE_INLINE agx::UInt32& ContactConstraintInstance::jacobianIndex() { verifyIndex();
return getData()->jacobianIndex[getIndex()]; }
619 AGX_FORCE_INLINE agx::UInt32 const& ContactConstraintInstance::jacobianIndex()
const { verifyIndex();
return getData()->jacobianIndex[getIndex()]; }
622 AGX_FORCE_INLINE agx::UInt32 const& ContactConstraintInstance::rowIndex()
const { verifyIndex();
return getData()->rowIndex[getIndex()]; }
624 AGX_FORCE_INLINE agx::UInt32& ContactConstraintInstance::materialIndex() { verifyIndex();
return getData()->materialIndex[getIndex()]; }
625 AGX_FORCE_INLINE agx::UInt32 const& ContactConstraintInstance::materialIndex()
const { verifyIndex();
return getData()->materialIndex[getIndex()]; }
627 AGX_FORCE_INLINE agx::UInt32& ContactConstraintInstance::iterationCount() { verifyIndex();
return getData()->iterationCount[getIndex()]; }
628 AGX_FORCE_INLINE agx::UInt32 const& ContactConstraintInstance::iterationCount()
const { verifyIndex();
return getData()->iterationCount[getIndex()]; }
630 AGX_FORCE_INLINE agx::Bool& ContactConstraintInstance::isImpacting() { verifyIndex();
return getData()->isImpacting[getIndex()]; }
631 AGX_FORCE_INLINE agx::Bool const& ContactConstraintInstance::isImpacting()
const { verifyIndex();
return getData()->isImpacting[getIndex()]; }
633 AGX_FORCE_INLINE agx::Real& ContactConstraintInstance::restingCompliance() { verifyIndex();
return getData()->restingCompliance[getIndex()]; }
634 AGX_FORCE_INLINE agx::Real const& ContactConstraintInstance::restingCompliance()
const { verifyIndex();
return getData()->restingCompliance[getIndex()]; }
636 AGX_FORCE_INLINE agx::Real& ContactConstraintInstance::charContactTime() { verifyIndex();
return getData()->charContactTime[getIndex()]; }
637 AGX_FORCE_INLINE agx::Real const& ContactConstraintInstance::charContactTime()
const { verifyIndex();
return getData()->charContactTime[getIndex()]; }
639 AGX_FORCE_INLINE agx::Real& ContactConstraintInstance::charMass() { verifyIndex();
return getData()->charMass[getIndex()]; }
640 AGX_FORCE_INLINE agx::Real const& ContactConstraintInstance::charMass()
const { verifyIndex();
return getData()->charMass[getIndex()]; }
645 AGX_FORCE_INLINE agx::Real& ContactConstraintInstance::nonlinearMultiplier() { verifyIndex();
return getData()->nonlinearMultiplier[getIndex()]; }
646 AGX_FORCE_INLINE agx::Real const& ContactConstraintInstance::nonlinearMultiplier()
const { verifyIndex();
return getData()->nonlinearMultiplier[getIndex()]; }
648 AGX_FORCE_INLINE agx::Real& ContactConstraintInstance::rollingResistanceMu() { verifyIndex();
return getData()->rollingResistanceMu[getIndex()]; }
649 AGX_FORCE_INLINE agx::Real const& ContactConstraintInstance::rollingResistanceMu()
const { verifyIndex();
return getData()->rollingResistanceMu[getIndex()]; }
651 AGX_FORCE_INLINE agx::Real& ContactConstraintInstance::twistLimitMultiplier() { verifyIndex();
return getData()->twistLimitMultiplier[getIndex()]; }
652 AGX_FORCE_INLINE agx::Real const& ContactConstraintInstance::twistLimitMultiplier()
const { verifyIndex();
return getData()->twistLimitMultiplier[getIndex()]; }
655 AGX_FORCE_INLINE ContactConstraintSemantics::ContactConstraintSemantics() {}
663AGX_TYPE_BINDING(
agx::Physics::GranularBody::ContactConstraintInstance, "Physics.GranularBody.ContactConstraintInstance")
669#undef AGX_ENTITY_WRAPPER
670#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...
agx::Index calculateIndex() const
Calculate the index using the indirect id.
EntityPtr & operator=(const EntityPtr &other)=default
bool isInstanceOf(agxData::EntityModel *model) const
agxData::EntityData * getData()
agxData::EntityInstance instance()
void verifyIndex() const
Check for broken ptr, by verifying that the id is active in the storage.
Data storage for a collection of entity instances of a specified EntityModel.
agx::String fullPath() const
AGXPHYSICS_EXPORT agx::UInt & body1()
AGXPHYSICS_EXPORT agx::UInt & body2()
AGXPHYSICS_EXPORT agx::Bool & isImpacting()
AGXPHYSICS_EXPORT agx::UInt32 & jacobianIndex()
AGXPHYSICS_EXPORT agx::UInt32 & rowIndex()
Abstract description of the data attributes for the Physics.GranularBody.ContactConstraint entity.
virtual void shutdownCleanup() override
This is part of internal cleanup and should not be called by users.
static agxData::ScalarAttributeT< agx::Real > * charContactTimeAttribute
static agxData::ScalarAttributeT< agx::Real > * charMassAttribute
virtual void construct(agxData::EntityPtr instance) override
static agxData::ScalarAttributeT< agx::UInt32 > * solveBody1Attribute
virtual void initAttributeAccessors() override
static agxData::ScalarAttributeT< agx::UInt32 > * body2Attribute
ContactConstraintPtr PtrT
virtual ~ContactConstraintModel()
static agxData::ScalarAttributeT< agx::UInt32 > * jacobianIndexAttribute
virtual agxData::EntityData * createData(agxData::EntityStorage *storage) override
static agxData::ScalarAttributeT< agx::UInt32 > * body1Attribute
ContactConstraintModel(const agx::String &name="ContactConstraint")
static agxData::ScalarAttributeT< agx::Real > * restingComplianceAttribute
static agxData::ScalarAttributeT< agx::Real > * rollingResistanceMuAttribute
static agxData::ScalarAttributeT< agx::Bool > * isImpactingAttribute
static agxData::ScalarAttributeT< agx::UInt32 > * solveBody2Attribute
static agxData::EntityStorage * defaultStorage()
static ContactConstraintPtr createInstance()
Create and return a pointer to a new instance in the default storage for this entity model.
static agxData::ScalarAttributeT< agx::UInt32 > * iterationCountAttribute
static agxData::ScalarAttributeT< agx::UInt32 > * cachedContactIdAttribute
static agxData::ScalarAttributeT< agx::UInt32 > * materialIndexAttribute
static ContactConstraintModel * instance()
static agxData::ScalarAttributeT< agx::Real > * nonlinearMultiplierAttribute
static agxData::ScalarAttributeT< agx::Real > * twistLimitMultiplierAttribute
static agxData::ScalarAttributeT< agx::JacobianMeta > * GMetaAttribute
virtual void configure(agx::TiXmlElement *eEntity) override
static agxData::ScalarAttributeT< agx::UInt32 > * contactIndexAttribute
void construct(agx::Physics::GranularBody::ContactConstraintPtr contactConstraint)
static agxData::ScalarAttributeT< agx::UInt32 > * rowIndexAttribute
Pointer to a entity instance of type Physics.GranularBody.ContactConstraint.
AGXPHYSICS_EXPORT ContactConstraintPtr()
AGXPHYSICS_EXPORT const ContactConstraintInstance instance() const
AGXPHYSICS_EXPORT ContactConstraintPtr(const agxData::EntityInstance &instance)
AGXPHYSICS_EXPORT agx::UInt32 const & jacobianIndex() const
AGXPHYSICS_EXPORT agx::Real const & charContactTime() const
AGXPHYSICS_EXPORT agx::Bool & isImpacting()
AGXPHYSICS_EXPORT agx::Real const & charMass() const
AGXPHYSICS_EXPORT agx::Bool const & isImpacting() const
AGXPHYSICS_EXPORT agx::UInt32 const & solveBody1() const
AGXPHYSICS_EXPORT agx::UInt32 & body1()
AGXPHYSICS_EXPORT agx::UInt32 & rowIndex()
AGXPHYSICS_EXPORT ContactConstraintInstance instance()
AGXPHYSICS_EXPORT agx::Real & nonlinearMultiplier()
AGXPHYSICS_EXPORT agx::UInt32 & materialIndex()
AGXPHYSICS_EXPORT agx::UInt32 & body2()
AGXPHYSICS_EXPORT agx::Real & charMass()
AGXPHYSICS_EXPORT agx::UInt32 & cachedContactId()
AGXPHYSICS_EXPORT agx::UInt32 & jacobianIndex()
AGXPHYSICS_EXPORT agx::UInt32 const & body2() const
AGXPHYSICS_EXPORT agx::Real const & restingCompliance() const
AGXPHYSICS_EXPORT agx::UInt32 const & cachedContactId() const
const ContactConstraintData * getData() const
AGXPHYSICS_EXPORT agx::Real & charContactTime()
AGXPHYSICS_EXPORT agx::UInt32 & iterationCount()
AGXPHYSICS_EXPORT agx::UInt32 const & solveBody2() const
AGXPHYSICS_EXPORT agx::UInt32 & solveBody2()
AGXPHYSICS_EXPORT agx::UInt32 const & materialIndex() const
AGXPHYSICS_EXPORT agx::JacobianMeta & GMeta()
AGXPHYSICS_EXPORT agx::Real const & nonlinearMultiplier() const
AGXPHYSICS_EXPORT agx::UInt32 const & iterationCount() const
AGXPHYSICS_EXPORT agx::Real const & rollingResistanceMu() const
ContactConstraintData DataType
AGXPHYSICS_EXPORT agx::Real & rollingResistanceMu()
AGXPHYSICS_EXPORT agx::Real const & twistLimitMultiplier() const
ContactConstraintData * getData()
ContactConstraintInstance InstanceType
AGXPHYSICS_EXPORT agx::UInt32 const & body1() const
AGXPHYSICS_EXPORT agx::UInt32 & contactIndex()
AGXPHYSICS_EXPORT ContactConstraintPtr(agxData::EntityStorage *storage, agx::Index id)
AGXPHYSICS_EXPORT agx::JacobianMeta const & GMeta() const
AGXPHYSICS_EXPORT ContactConstraintSemantics * operator->()
AGXPHYSICS_EXPORT agx::Real & twistLimitMultiplier()
ContactConstraintModel ModelType
AGXPHYSICS_EXPORT agx::Real & restingCompliance()
AGXPHYSICS_EXPORT agx::UInt32 const & rowIndex() const
AGXPHYSICS_EXPORT ContactConstraintPtr(const agxData::EntityPtr &ptr)
AGXPHYSICS_EXPORT agx::UInt32 & solveBody1()
AGXPHYSICS_EXPORT agx::UInt32 const & contactIndex() const
AGXPHYSICS_EXPORT const ContactConstraintSemantics * operator->() const
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.