33 # pragma warning(push)
34 # pragma warning(disable: 4251) // warning C4251: class X needs to have dll-interface to be used by clients of class Y
39 class MaterialManager;
47 class GeometryContact;
82 void setDensity(
Real density);
88 Real getDensity()
const;
93 void setYoungsModulus(
Real value);
98 Real getYoungsModulus()
const;
104 void setPoissonsRatio(
Real value);
110 Real getPoissonsRatio()
const;
116 Real getDamping()
const;
138 bool setMinMaxElasticRestLength(
Real minElasticRestLength,
Real maxElasticRestLength);
146 Real getMinElasticRestLength()
const;
154 Real getMaxElasticRestLength()
const;
163 void setViscosity(
Real viscosity );
168 Real getViscosity()
const;
173 bool isDirty()
const;
217 void setRoughness(
Real roughness );
223 Real getRoughness()
const;
234 void setAdhesion(
Real adhesion,
Real adhesiveOverlap );
239 Real getAdhesion()
const;
244 Real getAdhesiveOverlap()
const;
251 void setViscosity(
Real viscosity );
256 Real getViscosity()
const;
262 bool getFrictionEnabled()
const;
269 void setFrictionEnabled(
bool flag );
272 bool isDirty()
const;
291 void setDirty(
bool flag )
const;
316 Real getYoungsModulusStretch()
const;
321 Real getDampingStretch()
const;
326 Real getYoungsModulusBend()
const;
331 Real getDampingBend()
const;
337 void setYoungsModulusStretch(
Real youngsStretch );
343 void setDampingStretch(
Real dampingStretch );
349 void setYoungsModulusBend(
Real youngsBend );
355 void setDampingBend(
Real dampingBend );
362 bool isDirty()
const;
363 void setDirty(
bool flag)
const;
451 m_entity.name() = name;
455 static Material* getDefaultMaterial();
462 bool isDirty() const;
470 bool loadLibraryMaterial(
agx::
String name );
483 bool isLibraryMaterial() const;
490 const Physics::MaterialPtr&
getEntity() const;
508 void setDirty(
bool flag ) const;
534 BOTH_PRIMARY_AND_SECONDARY
566 void setRestitution(
Real restitution );
575 void setTangentialRestitution(
Real restitution, FrictionDirection direction = BOTH_PRIMARY_AND_SECONDARY );
583 void setFrictionCoefficient(
Real friction, FrictionDirection direction = BOTH_PRIMARY_AND_SECONDARY );
591 void setSurfaceViscosity(
Real viscosity, FrictionDirection direction = BOTH_PRIMARY_AND_SECONDARY );
602 void setAdhesion(
Real adhesion,
Real adhesiveOverlap );
607 Real getAdhesion()
const;
612 Real getAdhesiveOverlap()
const;
617 Real getRestitution()
const;
622 Real getTangentialRestitution( FrictionDirection direction = PRIMARY_DIRECTION )
const;
627 Real getFrictionCoefficient( FrictionDirection direction = PRIMARY_DIRECTION )
const;
632 Real getSurfaceViscosity( FrictionDirection direction = PRIMARY_DIRECTION )
const;
637 bool getSurfaceFrictionEnabled()
const;
642 void setEnableSurfaceFriction(
bool flag );
645 void setYoungsModulus(
Real youngsModulus );
648 Real getYoungsModulus()
const ;
670 bool setMinMaxElasticRestLength(
Real minElasticRestLength,
Real maxElasticRestLength);
678 Real getMinElasticRestLength()
const;
686 Real getMaxElasticRestLength()
const;
692 Real getDamping()
const ;
707 const Material* getMaterial1()
const;
712 const Material* getMaterial2()
const;
717 bool isExplicit()
const;
723 void setContactReductionMode( ContactReductionMode mode );
729 ContactReductionMode getContactReductionMode( )
const;
738 void setContactReductionBinResolution(
agx::UInt8 binResolution );
743 agx::UInt8 getContactReductionBinResolution()
const;
750 void setUseContactAreaApproach(
bool useContactAreaApproach );
757 bool getUseContactAreaApproach()
const;
765 void setRollingResistanceCoefficient(
agx::Real rollingCoefficient);
773 void setTwistingResistanceCoefficient(
agx::Real twistingCoefficient);
778 agx::Real getRollingResistanceCoefficient()
const;
783 agx::Real getTwistingResistanceCoefficient()
const;
791 void setRollingResistanceCompliance(
agx::Real compliance);
799 void setTwistingResistanceCompliance(
agx::Real compliance);
804 agx::Real getRollingResistanceCompliance()
const;
809 agx::Real getTwistingResistanceCompliance()
const;
816 void setImpactCompliance(
agx::Real impactCompliance);
831 void setWireFrictionCoefficient(
Real friction, FrictionDirection direction = BOTH_PRIMARY_AND_SECONDARY );
836 Real getWireFrictionCoefficient( FrictionDirection direction = PRIMARY_DIRECTION )
const;
857 void transfer(
agxData::EntityStorage* storage );
862 Physics::ContactMaterialPtr&
getEntity();
864 const Physics::ContactMaterialPtr&
getEntity() const;
871 enum class RestitutionCoefficient
882 virtual ~ContactMaterial();
886 ContactMaterial( const ContactMaterial& m );
888 ContactMaterial& operator = ( const ContactMaterial& );
890 void setDefaultParameters();
895 void setIsExplicit(
bool is_explicit );
913 return m_entity.frictionEnabled();
918 return m_entity.roughness();
923 return m_entity.adhesion();
928 return m_entity.adhesiveOverlap();
933 return m_entity.viscosity();
939 return m_entity.dirty();
944 m_entity.dirty() = flag;
951 return m_entity.dirty();
956 m_entity.dirty() = flag;
962 return m_entity.youngsModulusStretch();
967 return m_entity.dampingStretch();
972 return m_entity.youngsModulusBend();
977 return m_entity.dampingBend();
983 m_entity.youngsModulusStretch() = youngsStretch;
989 m_entity.dampingStretch() = dampingStretch;
995 m_entity.youngsModulusBend() = youngsBend;
1001 m_entity.dampingBend() = dampingBend;
1007 return m_entity.viscosity();
1012 return m_entity.poissonsRatio();
1017 return m_entity.damping();
1022 return m_entity.youngsModulus();
1027 return m_entity.density();
1032 return m_entity.dirty();
1038 m_entity.dirty() = flag;
1045 return m_surfaceMaterial;
1050 return m_surfaceMaterial;
1055 return m_bulkMaterial;
1060 return m_bulkMaterial;
1065 return m_wireMaterial;
1070 return m_wireMaterial;
1076 return m_surfaceMaterial->
isDirty() || m_bulkMaterial->isDirty() || m_wireMaterial->isDirty();
1081 m_surfaceMaterial->setDirty(flag);
1082 m_bulkMaterial->setDirty(flag);
1083 m_wireMaterial->setDirty(flag);
1090 return m_entity.name();
1101 return m_entity.friction()[ agx::clamp< int >( direction, 0, 1 ) ];
1106 return m_entity.viscosity()[ agx::clamp< int >( direction, 0, 1 ) ];
1111 return m_entity.adhesion();
1116 return m_entity.adhesiveOverlap();
1121 return m_entity.surfaceFrictionEnabled();
1126 return m_entity.youngsModulus();
1131 return m_entity.damping();
1136 return m_frictionModel;
1141 return m_entity.isExplicit();
1161 return m_entity.contactReductionBinResolution();
1221 return m_entity.rollingResistanceCoefficient();
1226 return m_entity.rollingResistanceCompliance();
1231 return m_entity.twistingResistanceCompliance();
1236 return m_entity.impactCompliance();
1241 return m_entity.useContactAreaApproach();
1246 return m_entity.wireFriction()[ agx::clamp< int >( direction, 0, 1 ) ];
1251 # pragma warning(pop)