211 void setNormalForceMagnitude(
agx::Real normalForceMagnitude );
216 agx::Real getNormalForceMagnitude()
const;
226 void setEnableScaleWithDepth(
agx::Bool enable );
231 agx::Bool getEnableScaleWithDepth()
const;
243 const size_t numPoints )
const override;
255 SCALE_WITH_DEPTH = 1 << 0
257 using Flags = agx::BitState<Flag, agx::UInt16>;
268 : T( solveType ), m_refFrame( refFrame ), m_primaryDirection( primaryDirection )
286 m_refFrame = refFrame;
292 return m_primaryDirection;
298 m_primaryDirection = primaryDirection;
311 ret_u = m_refFrame !=
nullptr ?
312 m_refFrame->transformVectorToWorld( m_primaryDirection ) :
314 ret_u -= ( normal * ret_u ) * normal;
320 ret_v = normal.
cross( ret_u );
virtual void calculateTangentPlane(const agxCollide::Geometry *geometry1, const agxCollide::Geometry *geometry2, const agx::Vec3 &point, const agx::Vec3 &normal, const agx::Real depth, agx::Vec3 &ret_u, agx::Vec3 &ret_v) const override
Calculates primary and secondary friction directions in world coordinates given contact point...
Iterative projected cone friction model with oriented friction box.
AGXCORE_EXPORT const Real RealEpsilon
const Vec3T cross(const Vec3T &rhs) const
Cross product method.
#define AGXPHYSICS_EXPORT
Oriented box friction model that uses the same normal force magnitude for all contact points associat...
const agx::Vec3 & getPrimaryDirection() const
The geometry representation used by the collision detection engine.
const agx::Frame * getReferenceFrame() const
virtual ~OrientedFrictionModelImpl()
Oriented friction box base implementation containing a frame of reference and the primary direction g...
static void createAttachmentBase(const agx::Vec3d &N, agx::Vec3d &U, agx::Vec3d &V)
Given vector N, create orthonormal base.
The agx namespace contains the dynamics/math part of the AGX Dynamics API.
Box friction model with oriented friction box.
void setReferenceFrame(const agx::Frame *refFrame)
Assign frame of reference.
Scale box friction model with oriented friction box.
Real normalize()
Normalize the vector so that it has length unity.
First Normal equation is calculated in the DIRECT solver, then in a second pass the normal and the fr...
The object defining a frame of reference and providing transformations operations.
#define AGXSTREAM_DECLARE_SERIALIZABLE(T)
Use this in a Serializable class to add the required methods Important: Use full namespace in the dec...
OrientedFrictionModelImpl(const agx::Frame *refFrame, const agx::Vec3 &primaryDirection, agx::FrictionModel::SolveType solveType)
Construct given frame of reference and primary friction direction.
void setPrimaryDirection(const agx::Vec3 &primaryDirection)
Assign primary friction direction given in reference frame.