Bullet Collision Detection & Physics Library
Classes | Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
btSoftBody Class Reference

The btSoftBody is an class to simulate cloth and volumetric soft bodies. More...

#include <btSoftBody.h>

Inheritance diagram for btSoftBody:
Inheritance graph
[legend]
Collaboration diagram for btSoftBody:
Collaboration graph
[legend]

Classes

struct  AJoint
 
struct  Anchor
 
struct  Body
 
struct  CJoint
 
struct  Cluster
 
struct  Config
 
struct  DeformableFaceNodeContact
 
class  DeformableFaceRigidContact
 
class  DeformableNodeRigidAnchor
 
class  DeformableNodeRigidContact
 
class  DeformableRigidContact
 
struct  eAeroModel
 eAeroModel More...
 
struct  eFeature
 eFeature More...
 
struct  Element
 
struct  ePSolver
 ePSolver : positions solvers More...
 
struct  eSolverPresets
 eSolverPresets More...
 
struct  eVSolver
 eVSolver : velocities solvers More...
 
struct  Face
 
struct  fCollision
 fCollision More...
 
struct  Feature
 
struct  fMaterial
 fMaterial More...
 
struct  ImplicitFn
 
struct  Impulse
 
struct  Joint
 
struct  Link
 
struct  LJoint
 
struct  Material
 
struct  Node
 
struct  Note
 
struct  Pose
 
struct  RayFromToCaster
 RayFromToCaster takes a ray from, ray to (instead of direction!) More...
 
struct  RContact
 
struct  RenderFace
 
struct  RenderNode
 
struct  SContact
 
struct  sCti
 
struct  sMedium
 
struct  SolverState
 
struct  sRayCast
 
struct  Tetra
 
struct  TetraScratch
 

Public Types

typedef btAlignedObjectArray< eVSolver::_tVSolverArray
 
typedef btAlignedObjectArray< ePSolver::_tPSolverArray
 
typedef btAlignedObjectArray< btScalartScalarArray
 
typedef btAlignedObjectArray< btVector3tVector3Array
 
typedef void(* psolver_t) (btSoftBody *, btScalar, btScalar)
 
typedef void(* vsolver_t) (btSoftBody *, btScalar)
 
typedef btAlignedObjectArray< Cluster * > tClusterArray
 
typedef btAlignedObjectArray< NotetNoteArray
 
typedef btAlignedObjectArray< NodetNodeArray
 
typedef btAlignedObjectArray< RenderNodetRenderNodeArray
 
typedef btAlignedObjectArray< btDbvtNode * > tLeafArray
 
typedef btAlignedObjectArray< LinktLinkArray
 
typedef btAlignedObjectArray< FacetFaceArray
 
typedef btAlignedObjectArray< RenderFacetRenderFaceArray
 
typedef btAlignedObjectArray< TetratTetraArray
 
typedef btAlignedObjectArray< AnchortAnchorArray
 
typedef btAlignedObjectArray< RContacttRContactArray
 
typedef btAlignedObjectArray< SContacttSContactArray
 
typedef btAlignedObjectArray< Material * > tMaterialArray
 
typedef btAlignedObjectArray< Joint * > tJointArray
 
typedef btAlignedObjectArray< btSoftBody * > tSoftBodyArray
 
typedef btAlignedObjectArray< btAlignedObjectArray< btScalar > > tDenseMatrix
 
- Public Types inherited from btCollisionObject
enum  CollisionFlags {
  CF_DYNAMIC_OBJECT = 0 ,
  CF_STATIC_OBJECT = 1 ,
  CF_KINEMATIC_OBJECT = 2 ,
  CF_NO_CONTACT_RESPONSE = 4 ,
  CF_CUSTOM_MATERIAL_CALLBACK = 8 ,
  CF_CHARACTER_OBJECT = 16 ,
  CF_DISABLE_VISUALIZE_OBJECT = 32 ,
  CF_DISABLE_SPU_COLLISION_PROCESSING = 64 ,
  CF_HAS_CONTACT_STIFFNESS_DAMPING = 128 ,
  CF_HAS_CUSTOM_DEBUG_RENDERING_COLOR = 256 ,
  CF_HAS_FRICTION_ANCHOR = 512 ,
  CF_HAS_COLLISION_SOUND_TRIGGER = 1024
}
 
enum  CollisionObjectTypes {
  CO_COLLISION_OBJECT = 1 ,
  CO_RIGID_BODY = 2 ,
  CO_GHOST_OBJECT = 4 ,
  CO_SOFT_BODY = 8 ,
  CO_HF_FLUID = 16 ,
  CO_USER_TYPE = 32 ,
  CO_FEATHERSTONE_LINK = 64
}
 
enum  AnisotropicFrictionFlags {
  CF_ANISOTROPIC_FRICTION_DISABLED = 0 ,
  CF_ANISOTROPIC_FRICTION = 1 ,
  CF_ANISOTROPIC_ROLLING_FRICTION = 2
}
 

Public Member Functions

 btSoftBody (btSoftBodyWorldInfo *worldInfo, int node_count, const btVector3 *x, const btScalar *m)
 
 btSoftBody (btSoftBodyWorldInfo *worldInfo)
 
void initDefaults ()
 
virtual ~btSoftBody ()
 
btSoftBodyWorldInfogetWorldInfo ()
 
void setDampingCoefficient (btScalar damping_coeff)
 
virtual void setCollisionShape (btCollisionShape *collisionShape)
 
bool checkLink (int node0, int node1) const
 
bool checkLink (const Node *node0, const Node *node1) const
 
bool checkFace (int node0, int node1, int node2) const
 
MaterialappendMaterial ()
 
void appendNote (const char *text, const btVector3 &o, const btVector4 &c=btVector4(1, 0, 0, 0), Node *n0=0, Node *n1=0, Node *n2=0, Node *n3=0)
 
void appendNote (const char *text, const btVector3 &o, Node *feature)
 
void appendNote (const char *text, const btVector3 &o, Link *feature)
 
void appendNote (const char *text, const btVector3 &o, Face *feature)
 
void appendNode (const btVector3 &x, btScalar m)
 
void appendLink (int model=-1, Material *mat=0)
 
void appendLink (int node0, int node1, Material *mat=0, bool bcheckexist=false)
 
void appendLink (Node *node0, Node *node1, Material *mat=0, bool bcheckexist=false)
 
void appendFace (int model=-1, Material *mat=0)
 
void appendFace (int node0, int node1, int node2, Material *mat=0)
 
void appendTetra (int model, Material *mat)
 
void appendTetra (int node0, int node1, int node2, int node3, Material *mat=0)
 
void appendDeformableAnchor (int node, btRigidBody *body)
 
void appendDeformableAnchor (int node, btMultiBodyLinkCollider *link)
 
void appendAnchor (int node, btRigidBody *body, bool disableCollisionBetweenLinkedBodies=false, btScalar influence=1)
 
void appendAnchor (int node, btRigidBody *body, const btVector3 &localPivot, bool disableCollisionBetweenLinkedBodies=false, btScalar influence=1)
 
void removeAnchor (int node)
 
void appendLinearJoint (const LJoint::Specs &specs, Cluster *body0, Body body1)
 
void appendLinearJoint (const LJoint::Specs &specs, Body body=Body())
 
void appendLinearJoint (const LJoint::Specs &specs, btSoftBody *body)
 
void appendAngularJoint (const AJoint::Specs &specs, Cluster *body0, Body body1)
 
void appendAngularJoint (const AJoint::Specs &specs, Body body=Body())
 
void appendAngularJoint (const AJoint::Specs &specs, btSoftBody *body)
 
void addForce (const btVector3 &force)
 
void addForce (const btVector3 &force, int node)
 
void addAeroForceToNode (const btVector3 &windVelocity, int nodeIndex)
 
void addAeroForceToFace (const btVector3 &windVelocity, int faceIndex)
 
void addVelocity (const btVector3 &velocity)
 
void setVelocity (const btVector3 &velocity)
 
void addVelocity (const btVector3 &velocity, int node)
 
void setMass (int node, btScalar mass)
 
btScalar getMass (int node) const
 
btScalar getTotalMass () const
 
void setTotalMass (btScalar mass, bool fromfaces=false)
 
void setTotalDensity (btScalar density)
 
void setVolumeMass (btScalar mass)
 
void setVolumeDensity (btScalar density)
 
btVector3 getLinearVelocity ()
 
void setLinearVelocity (const btVector3 &linVel)
 
void setAngularVelocity (const btVector3 &angVel)
 
btTransform getRigidTransform ()
 
virtual void transformTo (const btTransform &trs)
 
virtual void transform (const btTransform &trs)
 
virtual void translate (const btVector3 &trs)
 
virtual void rotate (const btQuaternion &rot)
 
virtual void scale (const btVector3 &scl)
 
btScalar getRestLengthScale ()
 
void setRestLengthScale (btScalar restLength)
 
void setPose (bool bvolume, bool bframe)
 
void resetLinkRestLengths ()
 
btScalar getVolume () const
 
btVector3 getCenterOfMass () const
 
int clusterCount () const
 
btVector3 clusterCom (int cluster) const
 
int generateBendingConstraints (int distance, Material *mat=0)
 
void randomizeConstraints ()
 
void updateState (const btAlignedObjectArray< btVector3 > &qs, const btAlignedObjectArray< btVector3 > &vs)
 
void releaseCluster (int index)
 
void releaseClusters ()
 
int generateClusters (int k, int maxiterations=8192)
 generateClusters with k=0 will create a convex cluster for each tetrahedron or triangle otherwise an approximation will be used (better performance) More...
 
void refine (ImplicitFn *ifn, btScalar accurary, bool cut)
 
bool cutLink (int node0, int node1, btScalar position)
 
bool cutLink (const Node *node0, const Node *node1, btScalar position)
 
bool rayTest (const btVector3 &rayFrom, const btVector3 &rayTo, sRayCast &results)
 Ray casting using rayFrom and rayTo in worldspace, (not direction!) More...
 
bool rayFaceTest (const btVector3 &rayFrom, const btVector3 &rayTo, sRayCast &results)
 
int rayFaceTest (const btVector3 &rayFrom, const btVector3 &rayTo, btScalar &mint, int &index) const
 
void setSolver (eSolverPresets::_ preset)
 
void predictMotion (btScalar dt)
 
void solveConstraints ()
 
void staticSolve (int iterations)
 
void integrateMotion ()
 
void defaultCollisionHandler (const btCollisionObjectWrapper *pcoWrap)
 
void defaultCollisionHandler (btSoftBody *psb)
 
void setSelfCollision (bool useSelfCollision)
 
bool useSelfCollision ()
 
void updateDeactivation (btScalar timeStep)
 
void setZeroVelocity ()
 
bool wantsSleeping ()
 
virtual btMatrix3x3 getImpulseFactor (int n_node)
 
void setWindVelocity (const btVector3 &velocity)
 Set a wind velocity for interaction with the air. More...
 
const btVector3getWindVelocity ()
 Return the wind velocity for interaction with the air. More...
 
void setSoftBodySolver (btSoftBodySolver *softBodySolver)
 
btSoftBodySolvergetSoftBodySolver ()
 
btSoftBodySolvergetSoftBodySolver () const
 
virtual void getAabb (btVector3 &aabbMin, btVector3 &aabbMax) const
 
void pointersToIndices ()
 
void indicesToPointers (const int *map=0)
 
int rayTest (const btVector3 &rayFrom, const btVector3 &rayTo, btScalar &mint, eFeature::_ &feature, int &index, bool bcountonly) const
 
void initializeFaceTree ()
 
void rebuildNodeTree ()
 
btVector3 evaluateCom () const
 
bool checkDeformableContact (const btCollisionObjectWrapper *colObjWrap, const btVector3 &x, btScalar margin, btSoftBody::sCti &cti, bool predict=false) const
 
bool checkDeformableFaceContact (const btCollisionObjectWrapper *colObjWrap, Face &f, btVector3 &contact_point, btVector3 &bary, btScalar margin, btSoftBody::sCti &cti, bool predict=false) const
 
bool checkContact (const btCollisionObjectWrapper *colObjWrap, const btVector3 &x, btScalar margin, btSoftBody::sCti &cti) const
 
void updateNormals ()
 
void updateBounds ()
 
void updatePose ()
 
void updateConstants ()
 
void updateLinkConstants ()
 
void updateArea (bool averageArea=true)
 
void initializeClusters ()
 
void updateClusters ()
 
void cleanupClusters ()
 
void prepareClusters (int iterations)
 
void solveClusters (btScalar sor)
 
void applyClusters (bool drift)
 
void dampClusters ()
 
void setSpringStiffness (btScalar k)
 
void setGravityFactor (btScalar gravFactor)
 
void setCacheBarycenter (bool cacheBarycenter)
 
void initializeDmInverse ()
 
void updateDeformation ()
 
void advanceDeformation ()
 
void applyForces ()
 
void setMaxStress (btScalar maxStress)
 
void interpolateRenderMesh ()
 
void setCollisionQuadrature (int N)
 
void geometricCollisionHandler (btSoftBody *psb)
 
void updateNode (btDbvtNode *node, bool use_velocity, bool margin)
 
void updateNodeTree (bool use_velocity, bool margin)
 
template<class DBVTNODE >
void updateFace (DBVTNODE *node, bool use_velocity, bool margin)
 
void updateFaceTree (bool use_velocity, bool margin)
 
void applyRepulsionForce (btScalar timeStep, bool applySpringForce)
 
virtual int calculateSerializeBufferSize () const
 
virtual const char * serialize (void *dataBuffer, class btSerializer *serializer) const
 fills the dataBuffer and returns the struct name (and 0 on failure) More...
 
- Public Member Functions inherited from btCollisionObject
 BT_DECLARE_ALIGNED_ALLOCATOR ()
 
bool mergesSimulationIslands () const
 
const btVector3getAnisotropicFriction () const
 
void setAnisotropicFriction (const btVector3 &anisotropicFriction, int frictionMode=CF_ANISOTROPIC_FRICTION)
 
bool hasAnisotropicFriction (int frictionMode=CF_ANISOTROPIC_FRICTION) const
 
void setContactProcessingThreshold (btScalar contactProcessingThreshold)
 the constraint solver can discard solving contacts, if the distance is above this threshold. More...
 
btScalar getContactProcessingThreshold () const
 
bool isStaticObject () const
 
bool isKinematicObject () const
 
bool isStaticOrKinematicObject () const
 
bool hasContactResponse () const
 
 btCollisionObject ()
 
virtual ~btCollisionObject ()
 
virtual void setCollisionShape (btCollisionShape *collisionShape)
 
const btCollisionShapegetCollisionShape () const
 
btCollisionShapegetCollisionShape ()
 
void setIgnoreCollisionCheck (const btCollisionObject *co, bool ignoreCollisionCheck)
 
int getNumObjectsWithoutCollision () const
 
const btCollisionObjectgetObjectWithoutCollision (int index)
 
virtual bool checkCollideWithOverride (const btCollisionObject *co) const
 
void * internalGetExtensionPointer () const
 Avoid using this internal API call, the extension pointer is used by some Bullet extensions. More...
 
void internalSetExtensionPointer (void *pointer)
 Avoid using this internal API call, the extension pointer is used by some Bullet extensions If you need to store your own user pointer, use 'setUserPointer/getUserPointer' instead. More...
 
int getActivationState () const
 
void setActivationState (int newState) const
 
void setDeactivationTime (btScalar time)
 
btScalar getDeactivationTime () const
 
void forceActivationState (int newState) const
 
void activate (bool forceActivation=false) const
 
bool isActive () const
 
void setRestitution (btScalar rest)
 
btScalar getRestitution () const
 
void setFriction (btScalar frict)
 
btScalar getFriction () const
 
void setRollingFriction (btScalar frict)
 
btScalar getRollingFriction () const
 
void setSpinningFriction (btScalar frict)
 
btScalar getSpinningFriction () const
 
void setContactStiffnessAndDamping (btScalar stiffness, btScalar damping)
 
btScalar getContactStiffness () const
 
btScalar getContactDamping () const
 
int getInternalType () const
 reserved for Bullet internal usage More...
 
btTransformgetWorldTransform ()
 
const btTransformgetWorldTransform () const
 
void setWorldTransform (const btTransform &worldTrans)
 
btBroadphaseProxygetBroadphaseHandle ()
 
const btBroadphaseProxygetBroadphaseHandle () const
 
void setBroadphaseHandle (btBroadphaseProxy *handle)
 
const btTransformgetInterpolationWorldTransform () const
 
btTransformgetInterpolationWorldTransform ()
 
void setInterpolationWorldTransform (const btTransform &trans)
 
void setInterpolationLinearVelocity (const btVector3 &linvel)
 
void setInterpolationAngularVelocity (const btVector3 &angvel)
 
const btVector3getInterpolationLinearVelocity () const
 
const btVector3getInterpolationAngularVelocity () const
 
int getIslandTag () const
 
void setIslandTag (int tag)
 
int getCompanionId () const
 
void setCompanionId (int id)
 
int getWorldArrayIndex () const
 
void setWorldArrayIndex (int ix)
 
btScalar getHitFraction () const
 
void setHitFraction (btScalar hitFraction)
 
int getCollisionFlags () const
 
void setCollisionFlags (int flags)
 
btScalar getCcdSweptSphereRadius () const
 Swept sphere radius (0.0 by default), see btConvexConvexAlgorithm:: More...
 
void setCcdSweptSphereRadius (btScalar radius)
 Swept sphere radius (0.0 by default), see btConvexConvexAlgorithm:: More...
 
btScalar getCcdMotionThreshold () const
 
btScalar getCcdSquareMotionThreshold () const
 
void setCcdMotionThreshold (btScalar ccdMotionThreshold)
 Don't do continuous collision detection if the motion (in one step) is less then m_ccdMotionThreshold. More...
 
void * getUserPointer () const
 users can point to their objects, userPointer is not used by Bullet More...
 
int getUserIndex () const
 
int getUserIndex2 () const
 
int getUserIndex3 () const
 
void setUserPointer (void *userPointer)
 users can point to their objects, userPointer is not used by Bullet More...
 
void setUserIndex (int index)
 users can point to their objects, userPointer is not used by Bullet More...
 
void setUserIndex2 (int index)
 
void setUserIndex3 (int index)
 
int getUpdateRevisionInternal () const
 
void setCustomDebugColor (const btVector3 &colorRGB)
 
void removeCustomDebugColor ()
 
bool getCustomDebugColor (btVector3 &colorRGB) const
 
bool checkCollideWith (const btCollisionObject *co) const
 
virtual int calculateSerializeBufferSize () const
 
virtual const char * serialize (void *dataBuffer, class btSerializer *serializer) const
 fills the dataBuffer and returns the struct name (and 0 on failure) More...
 
virtual void serializeSingleObject (class btSerializer *serializer) const
 

Static Public Member Functions

static btVector3 clusterCom (const Cluster *cluster)
 
static btVector3 clusterVelocity (const Cluster *cluster, const btVector3 &rpos)
 
static void clusterVImpulse (Cluster *cluster, const btVector3 &rpos, const btVector3 &impulse)
 
static void clusterDImpulse (Cluster *cluster, const btVector3 &rpos, const btVector3 &impulse)
 
static void clusterImpulse (Cluster *cluster, const btVector3 &rpos, const Impulse &impulse)
 
static void clusterVAImpulse (Cluster *cluster, const btVector3 &impulse)
 
static void clusterDAImpulse (Cluster *cluster, const btVector3 &impulse)
 
static void clusterAImpulse (Cluster *cluster, const Impulse &impulse)
 
static void clusterDCImpulse (Cluster *cluster, const btVector3 &impulse)
 
static void solveCommonConstraints (btSoftBody **bodies, int count, int iterations)
 
static void solveClusters (const btAlignedObjectArray< btSoftBody * > &bodies)
 
static const btSoftBodyupcast (const btCollisionObject *colObj)
 
static btSoftBodyupcast (btCollisionObject *colObj)
 
static void PSolve_Anchors (btSoftBody *psb, btScalar kst, btScalar ti)
 
static void PSolve_RContacts (btSoftBody *psb, btScalar kst, btScalar ti)
 
static void PSolve_SContacts (btSoftBody *psb, btScalar, btScalar ti)
 
static void PSolve_Links (btSoftBody *psb, btScalar kst, btScalar ti)
 
static void VSolve_Links (btSoftBody *psb, btScalar kst)
 
static psolver_t getSolver (ePSolver::_ solver)
 
static vsolver_t getSolver (eVSolver::_ solver)
 
template<typename T >
static T BaryEval (const T &a, const T &b, const T &c, const btVector3 &coord)
 

Public Attributes

btAlignedObjectArray< const class btCollisionObject * > m_collisionDisabledObjects
 
btSoftBodySolverm_softBodySolver
 
Config m_cfg
 
SolverState m_sst
 
Pose m_pose
 
void * m_tag
 
btSoftBodyWorldInfom_worldInfo
 
tNoteArray m_notes
 
tNodeArray m_nodes
 
tRenderNodeArray m_renderNodes
 
tLinkArray m_links
 
tFaceArray m_faces
 
tRenderFaceArray m_renderFaces
 
tTetraArray m_tetras
 
btAlignedObjectArray< TetraScratchm_tetraScratches
 
btAlignedObjectArray< TetraScratchm_tetraScratchesTn
 
tAnchorArray m_anchors
 
btAlignedObjectArray< DeformableNodeRigidAnchorm_deformableAnchors
 
tRContactArray m_rcontacts
 
btAlignedObjectArray< DeformableNodeRigidContactm_nodeRigidContacts
 
btAlignedObjectArray< DeformableFaceNodeContactm_faceNodeContacts
 
btAlignedObjectArray< DeformableFaceRigidContactm_faceRigidContacts
 
btAlignedObjectArray< DeformableFaceNodeContactm_faceNodeContactsCCD
 
tSContactArray m_scontacts
 
tJointArray m_joints
 
tMaterialArray m_materials
 
btScalar m_timeacc
 
btVector3 m_bounds [2]
 
bool m_bUpdateRtCst
 
btDbvt m_ndbvt
 
btDbvt m_fdbvt
 
btDbvntNodem_fdbvnt
 
btDbvt m_cdbvt
 
tClusterArray m_clusters
 
btScalar m_dampingCoefficient
 
btScalar m_sleepingThreshold
 
btScalar m_maxSpeedSquared
 
btAlignedObjectArray< btVector3m_quads
 
btScalar m_repulsionStiffness
 
btScalar m_gravityFactor
 
bool m_cacheBarycenter
 
btAlignedObjectArray< btVector3m_X
 
btAlignedObjectArray< btVector4m_renderNodesInterpolationWeights
 
btAlignedObjectArray< btAlignedObjectArray< const btSoftBody::Node * > > m_renderNodesParents
 
btAlignedObjectArray< btScalarm_z
 
bool m_useSelfCollision
 
bool m_softSoftCollision
 
btAlignedObjectArray< bool > m_clusterConnectivity
 
btVector3 m_windVelocity
 
btScalar m_restLengthScale
 
bool m_reducedModel
 
btAlignedObjectArray< int > m_userIndexMapping
 

Additional Inherited Members

- Protected Attributes inherited from btCollisionObject
btTransform m_worldTransform
 
btTransform m_interpolationWorldTransform
 m_interpolationWorldTransform is used for CCD and interpolation it can be either previous or future (predicted) transform More...
 
btVector3 m_interpolationLinearVelocity
 
btVector3 m_interpolationAngularVelocity
 
btVector3 m_anisotropicFriction
 
int m_hasAnisotropicFriction
 
btScalar m_contactProcessingThreshold
 
btBroadphaseProxym_broadphaseHandle
 
btCollisionShapem_collisionShape
 
void * m_extensionPointer
 m_extensionPointer is used by some internal low-level Bullet extensions. More...
 
btCollisionShapem_rootCollisionShape
 m_rootCollisionShape is temporarily used to store the original collision shape The m_collisionShape might be temporarily replaced by a child collision shape during collision detection purposes If it is NULL, the m_collisionShape is not temporarily replaced. More...
 
int m_collisionFlags
 
int m_islandTag1
 
int m_companionId
 
int m_worldArrayIndex
 
int m_activationState1
 
btScalar m_deactivationTime
 
btScalar m_friction
 
btScalar m_restitution
 
btScalar m_rollingFriction
 
btScalar m_spinningFriction
 
btScalar m_contactDamping
 
btScalar m_contactStiffness
 
int m_internalType
 m_internalType is reserved to distinguish Bullet's btCollisionObject, btRigidBody, btSoftBody, btGhostObject etc. More...
 
void * m_userObjectPointer
 users can point to their objects, m_userPointer is not used by Bullet, see setUserPointer/getUserPointer More...
 
int m_userIndex2
 
int m_userIndex
 
int m_userIndex3
 
btScalar m_hitFraction
 time of impact calculation More...
 
btScalar m_ccdSweptSphereRadius
 Swept sphere radius (0.0 by default), see btConvexConvexAlgorithm:: More...
 
btScalar m_ccdMotionThreshold
 Don't do continuous collision detection if the motion (in one step) is less then m_ccdMotionThreshold. More...
 
int m_checkCollideWith
 If some object should have elaborate collision filtering by sub-classes. More...
 
btAlignedObjectArray< const btCollisionObject * > m_objectsWithoutCollisionCheck
 
int m_updateRevision
 internal update revision number. It will be increased when the object changes. This allows some subsystems to perform lazy evaluation. More...
 
btVector3 m_customDebugColorRGB
 

Detailed Description

The btSoftBody is an class to simulate cloth and volumetric soft bodies.

There is two-way interaction between btSoftBody and btRigidBody/btCollisionObject.

Definition at line 74 of file btSoftBody.h.

Member Typedef Documentation

◆ psolver_t

typedef void(* btSoftBody::psolver_t) (btSoftBody *, btScalar, btScalar)

Definition at line 785 of file btSoftBody.h.

◆ tAnchorArray

Definition at line 796 of file btSoftBody.h.

◆ tClusterArray

Definition at line 787 of file btSoftBody.h.

◆ tDenseMatrix

Definition at line 802 of file btSoftBody.h.

◆ tFaceArray

Definition at line 793 of file btSoftBody.h.

◆ tJointArray

Definition at line 800 of file btSoftBody.h.

◆ tLeafArray

Definition at line 791 of file btSoftBody.h.

◆ tLinkArray

Definition at line 792 of file btSoftBody.h.

◆ tMaterialArray

Definition at line 799 of file btSoftBody.h.

◆ tNodeArray

Definition at line 789 of file btSoftBody.h.

◆ tNoteArray

Definition at line 788 of file btSoftBody.h.

◆ tPSolverArray

Definition at line 152 of file btSoftBody.h.

◆ tRContactArray

Definition at line 797 of file btSoftBody.h.

◆ tRenderFaceArray

Definition at line 794 of file btSoftBody.h.

◆ tRenderNodeArray

Definition at line 790 of file btSoftBody.h.

◆ tScalarArray

Definition at line 220 of file btSoftBody.h.

◆ tSContactArray

Definition at line 798 of file btSoftBody.h.

◆ tSoftBodyArray

Definition at line 801 of file btSoftBody.h.

◆ tTetraArray

Definition at line 795 of file btSoftBody.h.

◆ tVector3Array

Definition at line 221 of file btSoftBody.h.

◆ tVSolverArray

Definition at line 151 of file btSoftBody.h.

◆ vsolver_t

typedef void(* btSoftBody::vsolver_t) (btSoftBody *, btScalar)

Definition at line 786 of file btSoftBody.h.

Constructor & Destructor Documentation

◆ btSoftBody() [1/2]

btSoftBody::btSoftBody ( btSoftBodyWorldInfo worldInfo,
int  node_count,
const btVector3 x,
const btScalar m 
)

Definition at line 130 of file btSoftBody.cpp.

◆ btSoftBody() [2/2]

btSoftBody::btSoftBody ( btSoftBodyWorldInfo worldInfo)

Definition at line 164 of file btSoftBody.cpp.

◆ ~btSoftBody()

btSoftBody::~btSoftBody ( )
virtual

Definition at line 240 of file btSoftBody.cpp.

Member Function Documentation

◆ addAeroForceToFace()

void btSoftBody::addAeroForceToFace ( const btVector3 windVelocity,
int  faceIndex 
)

Definition at line 797 of file btSoftBody.cpp.

◆ addAeroForceToNode()

void btSoftBody::addAeroForceToNode ( const btVector3 windVelocity,
int  nodeIndex 
)

Definition at line 708 of file btSoftBody.cpp.

◆ addForce() [1/2]

void btSoftBody::addForce ( const btVector3 force)

Definition at line 693 of file btSoftBody.cpp.

◆ addForce() [2/2]

void btSoftBody::addForce ( const btVector3 force,
int  node 
)

Definition at line 699 of file btSoftBody.cpp.

◆ addVelocity() [1/2]

void btSoftBody::addVelocity ( const btVector3 velocity)

Definition at line 893 of file btSoftBody.cpp.

◆ addVelocity() [2/2]

void btSoftBody::addVelocity ( const btVector3 velocity,
int  node 
)

Definition at line 913 of file btSoftBody.cpp.

◆ advanceDeformation()

void btSoftBody::advanceDeformation ( )

Definition at line 3562 of file btSoftBody.cpp.

◆ appendAnchor() [1/2]

void btSoftBody::appendAnchor ( int  node,
btRigidBody body,
bool  disableCollisionBetweenLinkedBodies = false,
btScalar  influence = 1 
)

Definition at line 504 of file btSoftBody.cpp.

◆ appendAnchor() [2/2]

void btSoftBody::appendAnchor ( int  node,
btRigidBody body,
const btVector3 localPivot,
bool  disableCollisionBetweenLinkedBodies = false,
btScalar  influence = 1 
)

Definition at line 511 of file btSoftBody.cpp.

◆ appendAngularJoint() [1/3]

void btSoftBody::appendAngularJoint ( const AJoint::Specs specs,
Body  body = Body() 
)

Definition at line 681 of file btSoftBody.cpp.

◆ appendAngularJoint() [2/3]

void btSoftBody::appendAngularJoint ( const AJoint::Specs specs,
btSoftBody body 
)

Definition at line 687 of file btSoftBody.cpp.

◆ appendAngularJoint() [3/3]

void btSoftBody::appendAngularJoint ( const AJoint::Specs specs,
Cluster body0,
Body  body1 
)

Definition at line 666 of file btSoftBody.cpp.

◆ appendDeformableAnchor() [1/2]

void btSoftBody::appendDeformableAnchor ( int  node,
btMultiBodyLinkCollider link 
)

Definition at line 584 of file btSoftBody.cpp.

◆ appendDeformableAnchor() [2/2]

void btSoftBody::appendDeformableAnchor ( int  node,
btRigidBody body 
)

Definition at line 531 of file btSoftBody.cpp.

◆ appendFace() [1/2]

void btSoftBody::appendFace ( int  model = -1,
Material mat = 0 
)

Definition at line 432 of file btSoftBody.cpp.

◆ appendFace() [2/2]

void btSoftBody::appendFace ( int  node0,
int  node1,
int  node2,
Material mat = 0 
)

Definition at line 448 of file btSoftBody.cpp.

◆ appendLinearJoint() [1/3]

void btSoftBody::appendLinearJoint ( const LJoint::Specs specs,
Body  body = Body() 
)

Definition at line 654 of file btSoftBody.cpp.

◆ appendLinearJoint() [2/3]

void btSoftBody::appendLinearJoint ( const LJoint::Specs specs,
btSoftBody body 
)

Definition at line 660 of file btSoftBody.cpp.

◆ appendLinearJoint() [3/3]

void btSoftBody::appendLinearJoint ( const LJoint::Specs specs,
Cluster body0,
Body  body1 
)

Definition at line 640 of file btSoftBody.cpp.

◆ appendLink() [1/3]

void btSoftBody::appendLink ( int  model = -1,
Material mat = 0 
)

Definition at line 392 of file btSoftBody.cpp.

◆ appendLink() [2/3]

void btSoftBody::appendLink ( int  node0,
int  node1,
Material mat = 0,
bool  bcheckexist = false 
)

Definition at line 406 of file btSoftBody.cpp.

◆ appendLink() [3/3]

void btSoftBody::appendLink ( Node node0,
Node node1,
Material mat = 0,
bool  bcheckexist = false 
)

Definition at line 415 of file btSoftBody.cpp.

◆ appendMaterial()

btSoftBody::Material * btSoftBody::appendMaterial ( )

Definition at line 302 of file btSoftBody.cpp.

◆ appendNode()

void btSoftBody::appendNode ( const btVector3 x,
btScalar  m 
)

Definition at line 372 of file btSoftBody.cpp.

◆ appendNote() [1/4]

void btSoftBody::appendNote ( const char *  text,
const btVector3 o,
const btVector4 c = btVector4(1, 0, 0, 0),
Node n0 = 0,
Node n1 = 0,
Node n2 = 0,
Node n3 = 0 
)

Definition at line 314 of file btSoftBody.cpp.

◆ appendNote() [2/4]

void btSoftBody::appendNote ( const char *  text,
const btVector3 o,
Face feature 
)

Definition at line 361 of file btSoftBody.cpp.

◆ appendNote() [3/4]

void btSoftBody::appendNote ( const char *  text,
const btVector3 o,
Link feature 
)

Definition at line 351 of file btSoftBody.cpp.

◆ appendNote() [4/4]

void btSoftBody::appendNote ( const char *  text,
const btVector3 o,
Node feature 
)

Definition at line 343 of file btSoftBody.cpp.

◆ appendTetra() [1/2]

void btSoftBody::appendTetra ( int  model,
Material mat 
)

Definition at line 472 of file btSoftBody.cpp.

◆ appendTetra() [2/2]

void btSoftBody::appendTetra ( int  node0,
int  node1,
int  node2,
int  node3,
Material mat = 0 
)

Definition at line 486 of file btSoftBody.cpp.

◆ applyClusters()

void btSoftBody::applyClusters ( bool  drift)

Definition at line 3377 of file btSoftBody.cpp.

◆ applyForces()

void btSoftBody::applyForces ( )

Definition at line 3741 of file btSoftBody.cpp.

◆ applyRepulsionForce()

void btSoftBody::applyRepulsionForce ( btScalar  timeStep,
bool  applySpringForce 
)
inline

Definition at line 1317 of file btSoftBody.h.

◆ BaryEval()

template<typename T >
static T btSoftBody::BaryEval ( const T &  a,
const T &  b,
const T &  c,
const btVector3 coord 
)
inlinestatic

Definition at line 1309 of file btSoftBody.h.

◆ calculateSerializeBufferSize()

int btSoftBody::calculateSerializeBufferSize ( ) const
virtual

Reimplemented from btCollisionObject.

Definition at line 4320 of file btSoftBody.cpp.

◆ checkContact()

bool btSoftBody::checkContact ( const btCollisionObjectWrapper colObjWrap,
const btVector3 x,
btScalar  margin,
btSoftBody::sCti cti 
) const

Definition at line 2748 of file btSoftBody.cpp.

◆ checkDeformableContact()

bool btSoftBody::checkDeformableContact ( const btCollisionObjectWrapper colObjWrap,
const btVector3 x,
btScalar  margin,
btSoftBody::sCti cti,
bool  predict = false 
) const

Definition at line 2777 of file btSoftBody.cpp.

◆ checkDeformableFaceContact()

bool btSoftBody::checkDeformableFaceContact ( const btCollisionObjectWrapper colObjWrap,
Face f,
btVector3 contact_point,
btVector3 bary,
btScalar  margin,
btSoftBody::sCti cti,
bool  predict = false 
) const

Definition at line 2825 of file btSoftBody.cpp.

◆ checkFace()

bool btSoftBody::checkFace ( int  node0,
int  node1,
int  node2 
) const

Definition at line 278 of file btSoftBody.cpp.

◆ checkLink() [1/2]

bool btSoftBody::checkLink ( const Node node0,
const Node node1 
) const

Definition at line 262 of file btSoftBody.cpp.

◆ checkLink() [2/2]

bool btSoftBody::checkLink ( int  node0,
int  node1 
) const

Definition at line 256 of file btSoftBody.cpp.

◆ cleanupClusters()

void btSoftBody::cleanupClusters ( )

Definition at line 3345 of file btSoftBody.cpp.

◆ clusterAImpulse()

void btSoftBody::clusterAImpulse ( Cluster cluster,
const Impulse impulse 
)
static

Definition at line 1338 of file btSoftBody.cpp.

◆ clusterCom() [1/2]

btVector3 btSoftBody::clusterCom ( const Cluster cluster)
static

Definition at line 1269 of file btSoftBody.cpp.

◆ clusterCom() [2/2]

btVector3 btSoftBody::clusterCom ( int  cluster) const

Definition at line 1280 of file btSoftBody.cpp.

◆ clusterCount()

int btSoftBody::clusterCount ( ) const

Definition at line 1263 of file btSoftBody.cpp.

◆ clusterDAImpulse()

void btSoftBody::clusterDAImpulse ( Cluster cluster,
const btVector3 impulse 
)
static

Definition at line 1330 of file btSoftBody.cpp.

◆ clusterDCImpulse()

void btSoftBody::clusterDCImpulse ( Cluster cluster,
const btVector3 impulse 
)
static

Definition at line 1345 of file btSoftBody.cpp.

◆ clusterDImpulse()

void btSoftBody::clusterDImpulse ( Cluster cluster,
const btVector3 rpos,
const btVector3 impulse 
)
static

Definition at line 1304 of file btSoftBody.cpp.

◆ clusterImpulse()

void btSoftBody::clusterImpulse ( Cluster cluster,
const btVector3 rpos,
const Impulse impulse 
)
static

Definition at line 1314 of file btSoftBody.cpp.

◆ clusterVAImpulse()

void btSoftBody::clusterVAImpulse ( Cluster cluster,
const btVector3 impulse 
)
static

Definition at line 1321 of file btSoftBody.cpp.

◆ clusterVelocity()

btVector3 btSoftBody::clusterVelocity ( const Cluster cluster,
const btVector3 rpos 
)
static

Definition at line 1286 of file btSoftBody.cpp.

◆ clusterVImpulse()

void btSoftBody::clusterVImpulse ( Cluster cluster,
const btVector3 rpos,
const btVector3 impulse 
)
static

Definition at line 1292 of file btSoftBody.cpp.

◆ cutLink() [1/2]

bool btSoftBody::cutLink ( const Node node0,
const Node node1,
btScalar  position 
)

Definition at line 1978 of file btSoftBody.cpp.

◆ cutLink() [2/2]

bool btSoftBody::cutLink ( int  node0,
int  node1,
btScalar  position 
)

Definition at line 1984 of file btSoftBody.cpp.

◆ dampClusters()

void btSoftBody::dampClusters ( )

Definition at line 3428 of file btSoftBody.cpp.

◆ defaultCollisionHandler() [1/2]

void btSoftBody::defaultCollisionHandler ( btSoftBody psb)

Definition at line 4158 of file btSoftBody.cpp.

◆ defaultCollisionHandler() [2/2]

void btSoftBody::defaultCollisionHandler ( const btCollisionObjectWrapper pcoWrap)

Definition at line 4076 of file btSoftBody.cpp.

◆ evaluateCom()

btVector3 btSoftBody::evaluateCom ( ) const

Definition at line 2735 of file btSoftBody.cpp.

◆ generateBendingConstraints()

int btSoftBody::generateBendingConstraints ( int  distance,
Material mat = 0 
)

generic Floyd's algorithm

Definition at line 1357 of file btSoftBody.cpp.

◆ generateClusters()

int btSoftBody::generateClusters ( int  k,
int  maxiterations = 8192 
)

generateClusters with k=0 will create a convex cluster for each tetrahedron or triangle otherwise an approximation will be used (better performance)

Definition at line 1521 of file btSoftBody.cpp.

◆ geometricCollisionHandler()

void btSoftBody::geometricCollisionHandler ( btSoftBody psb)

Definition at line 4258 of file btSoftBody.cpp.

◆ getAabb()

virtual void btSoftBody::getAabb ( btVector3 aabbMin,
btVector3 aabbMax 
) const
inlinevirtual

Definition at line 1174 of file btSoftBody.h.

◆ getCenterOfMass()

btVector3 btSoftBody::getCenterOfMass ( ) const
inline

Definition at line 1030 of file btSoftBody.h.

◆ getImpulseFactor()

virtual btMatrix3x3 btSoftBody::getImpulseFactor ( int  n_node)
inlinevirtual

Reimplemented in btReducedDeformableBody.

Definition at line 1107 of file btSoftBody.h.

◆ getLinearVelocity()

btVector3 btSoftBody::getLinearVelocity ( )

Definition at line 1034 of file btSoftBody.cpp.

◆ getMass()

btScalar btSoftBody::getMass ( int  node) const

Definition at line 930 of file btSoftBody.cpp.

◆ getRestLengthScale()

btScalar btSoftBody::getRestLengthScale ( )

Definition at line 1164 of file btSoftBody.cpp.

◆ getRigidTransform()

btTransform btSoftBody::getRigidTransform ( )

Definition at line 1067 of file btSoftBody.cpp.

◆ getSoftBodySolver() [1/2]

btSoftBodySolver * btSoftBody::getSoftBodySolver ( )
inline

Definition at line 1140 of file btSoftBody.h.

◆ getSoftBodySolver() [2/2]

btSoftBodySolver * btSoftBody::getSoftBodySolver ( ) const
inline

Definition at line 1148 of file btSoftBody.h.

◆ getSolver() [1/2]

btSoftBody::psolver_t btSoftBody::getSolver ( ePSolver::_  solver)
static

Definition at line 4032 of file btSoftBody.cpp.

◆ getSolver() [2/2]

btSoftBody::vsolver_t btSoftBody::getSolver ( eVSolver::_  solver)
static

Definition at line 4052 of file btSoftBody.cpp.

◆ getTotalMass()

btScalar btSoftBody::getTotalMass ( ) const

Definition at line 936 of file btSoftBody.cpp.

◆ getVolume()

btScalar btSoftBody::getVolume ( ) const

Definition at line 1244 of file btSoftBody.cpp.

◆ getWindVelocity()

const btVector3 & btSoftBody::getWindVelocity ( )

Return the wind velocity for interaction with the air.

Definition at line 4315 of file btSoftBody.cpp.

◆ getWorldInfo()

btSoftBodyWorldInfo * btSoftBody::getWorldInfo ( )
inline

Definition at line 881 of file btSoftBody.h.

◆ indicesToPointers()

void btSoftBody::indicesToPointers ( const int *  map = 0)

Definition at line 2459 of file btSoftBody.cpp.

◆ initDefaults()

void btSoftBody::initDefaults ( )

for now, create a collision shape internally

Definition at line 170 of file btSoftBody.cpp.

◆ initializeClusters()

void btSoftBody::initializeClusters ( )

Definition at line 3162 of file btSoftBody.cpp.

◆ initializeDmInverse()

void btSoftBody::initializeDmInverse ( )

Definition at line 3472 of file btSoftBody.cpp.

◆ initializeFaceTree()

void btSoftBody::initializeFaceTree ( )

Definition at line 2642 of file btSoftBody.cpp.

◆ integrateMotion()

void btSoftBody::integrateMotion ( )

Definition at line 2348 of file btSoftBody.cpp.

◆ interpolateRenderMesh()

void btSoftBody::interpolateRenderMesh ( )

Definition at line 3815 of file btSoftBody.cpp.

◆ pointersToIndices()

void btSoftBody::pointersToIndices ( )

Definition at line 2416 of file btSoftBody.cpp.

◆ predictMotion()

void btSoftBody::predictMotion ( btScalar  dt)

Definition at line 2099 of file btSoftBody.cpp.

◆ prepareClusters()

void btSoftBody::prepareClusters ( int  iterations)

Definition at line 3359 of file btSoftBody.cpp.

◆ PSolve_Anchors()

void btSoftBody::PSolve_Anchors ( btSoftBody psb,
btScalar  kst,
btScalar  ti 
)
static

Definition at line 3864 of file btSoftBody.cpp.

◆ PSolve_Links()

void btSoftBody::PSolve_Links ( btSoftBody psb,
btScalar  kst,
btScalar  ti 
)
static

Definition at line 3995 of file btSoftBody.cpp.

◆ PSolve_RContacts()

void btSoftBody::PSolve_RContacts ( btSoftBody psb,
btScalar  kst,
btScalar  ti 
)
static

Definition at line 3885 of file btSoftBody.cpp.

◆ PSolve_SContacts()

void btSoftBody::PSolve_SContacts ( btSoftBody psb,
btScalar  ,
btScalar  ti 
)
static

Definition at line 3960 of file btSoftBody.cpp.

◆ randomizeConstraints()

void btSoftBody::randomizeConstraints ( )

Definition at line 1472 of file btSoftBody.cpp.

◆ rayFaceTest() [1/2]

int btSoftBody::rayFaceTest ( const btVector3 rayFrom,
const btVector3 rayTo,
btScalar mint,
int &  index 
) const

Definition at line 2577 of file btSoftBody.cpp.

◆ rayFaceTest() [2/2]

bool btSoftBody::rayFaceTest ( const btVector3 rayFrom,
const btVector3 rayTo,
sRayCast results 
)

Definition at line 2054 of file btSoftBody.cpp.

◆ rayTest() [1/2]

int btSoftBody::rayTest ( const btVector3 rayFrom,
const btVector3 rayTo,
btScalar mint,
eFeature::_ feature,
int &  index,
bool  bcountonly 
) const

Definition at line 2502 of file btSoftBody.cpp.

◆ rayTest() [2/2]

bool btSoftBody::rayTest ( const btVector3 rayFrom,
const btVector3 rayTo,
sRayCast results 
)

Ray casting using rayFrom and rayTo in worldspace, (not direction!)

Definition at line 2039 of file btSoftBody.cpp.

◆ rebuildNodeTree()

void btSoftBody::rebuildNodeTree ( )

Definition at line 2697 of file btSoftBody.cpp.

◆ refine()

void btSoftBody::refine ( ImplicitFn ifn,
btScalar  accurary,
bool  cut 
)

Definition at line 1714 of file btSoftBody.cpp.

◆ releaseCluster()

void btSoftBody::releaseCluster ( int  index)

Definition at line 1505 of file btSoftBody.cpp.

◆ releaseClusters()

void btSoftBody::releaseClusters ( )

Definition at line 1515 of file btSoftBody.cpp.

◆ removeAnchor()

void btSoftBody::removeAnchor ( int  node)

Definition at line 566 of file btSoftBody.cpp.

◆ resetLinkRestLengths()

void btSoftBody::resetLinkRestLengths ( )

Definition at line 1233 of file btSoftBody.cpp.

◆ rotate()

void btSoftBody::rotate ( const btQuaternion rot)
virtual

Definition at line 1134 of file btSoftBody.cpp.

◆ scale()

void btSoftBody::scale ( const btVector3 scl)
virtual

Reimplemented in btReducedDeformableBody.

Definition at line 1143 of file btSoftBody.cpp.

◆ serialize()

const char * btSoftBody::serialize ( void *  dataBuffer,
class btSerializer serializer 
) const
virtual

fills the dataBuffer and returns the struct name (and 0 on failure)

Reimplemented from btCollisionObject.

Definition at line 4327 of file btSoftBody.cpp.

◆ setAngularVelocity()

void btSoftBody::setAngularVelocity ( const btVector3 angVel)

Definition at line 1056 of file btSoftBody.cpp.

◆ setCacheBarycenter()

void btSoftBody::setCacheBarycenter ( bool  cacheBarycenter)

Definition at line 3467 of file btSoftBody.cpp.

◆ setCollisionQuadrature()

void btSoftBody::setCollisionQuadrature ( int  N)

Definition at line 3852 of file btSoftBody.cpp.

◆ setCollisionShape()

virtual void btSoftBody::setCollisionShape ( btCollisionShape collisionShape)
inlinevirtual

Reimplemented from btCollisionObject.

Definition at line 892 of file btSoftBody.h.

◆ setDampingCoefficient()

void btSoftBody::setDampingCoefficient ( btScalar  damping_coeff)
inline

Definition at line 886 of file btSoftBody.h.

◆ setGravityFactor()

void btSoftBody::setGravityFactor ( btScalar  gravFactor)

Definition at line 3462 of file btSoftBody.cpp.

◆ setLinearVelocity()

void btSoftBody::setLinearVelocity ( const btVector3 linVel)

Definition at line 1047 of file btSoftBody.cpp.

◆ setMass()

void btSoftBody::setMass ( int  node,
btScalar  mass 
)

Definition at line 923 of file btSoftBody.cpp.

◆ setMaxStress()

void btSoftBody::setMaxStress ( btScalar  maxStress)

Definition at line 3809 of file btSoftBody.cpp.

◆ setPose()

void btSoftBody::setPose ( bool  bvolume,
bool  bframe 
)

Definition at line 1185 of file btSoftBody.cpp.

◆ setRestLengthScale()

void btSoftBody::setRestLengthScale ( btScalar  restLength)

Definition at line 1170 of file btSoftBody.cpp.

◆ setSelfCollision()

void btSoftBody::setSelfCollision ( bool  useSelfCollision)

Definition at line 4065 of file btSoftBody.cpp.

◆ setSoftBodySolver()

void btSoftBody::setSoftBodySolver ( btSoftBodySolver softBodySolver)
inline

Definition at line 1132 of file btSoftBody.h.

◆ setSolver()

void btSoftBody::setSolver ( eSolverPresets::_  preset)

Definition at line 2074 of file btSoftBody.cpp.

◆ setSpringStiffness()

void btSoftBody::setSpringStiffness ( btScalar  k)

Definition at line 3453 of file btSoftBody.cpp.

◆ setTotalDensity()

void btSoftBody::setTotalDensity ( btScalar  density)

Definition at line 983 of file btSoftBody.cpp.

◆ setTotalMass()

void btSoftBody::setTotalMass ( btScalar  mass,
bool  fromfaces = false 
)

Definition at line 947 of file btSoftBody.cpp.

◆ setVelocity()

void btSoftBody::setVelocity ( const btVector3 velocity)

Definition at line 899 of file btSoftBody.cpp.

◆ setVolumeDensity()

void btSoftBody::setVolumeDensity ( btScalar  density)

Definition at line 1019 of file btSoftBody.cpp.

◆ setVolumeMass()

void btSoftBody::setVolumeMass ( btScalar  mass)

Definition at line 989 of file btSoftBody.cpp.

◆ setWindVelocity()

void btSoftBody::setWindVelocity ( const btVector3 velocity)

Set a wind velocity for interaction with the air.

Definition at line 4310 of file btSoftBody.cpp.

◆ setZeroVelocity()

void btSoftBody::setZeroVelocity ( )

Definition at line 4723 of file btSoftBody.cpp.

◆ solveClusters() [1/2]

void btSoftBody::solveClusters ( btScalar  sor)

Definition at line 3368 of file btSoftBody.cpp.

◆ solveClusters() [2/2]

void btSoftBody::solveClusters ( const btAlignedObjectArray< btSoftBody * > &  bodies)
static

Definition at line 2319 of file btSoftBody.cpp.

◆ solveCommonConstraints()

void btSoftBody::solveCommonConstraints ( btSoftBody **  bodies,
int  count,
int  iterations 
)
static

placeholder

Definition at line 2313 of file btSoftBody.cpp.

◆ solveConstraints()

void btSoftBody::solveConstraints ( )

Definition at line 2208 of file btSoftBody.cpp.

◆ staticSolve()

void btSoftBody::staticSolve ( int  iterations)

Definition at line 2301 of file btSoftBody.cpp.

◆ transform()

void btSoftBody::transform ( const btTransform trs)
virtual

Reimplemented in btReducedDeformableBody.

Definition at line 1103 of file btSoftBody.cpp.

◆ transformTo()

void btSoftBody::transformTo ( const btTransform trs)
virtual

Reimplemented in btReducedDeformableBody.

Definition at line 1093 of file btSoftBody.cpp.

◆ translate()

void btSoftBody::translate ( const btVector3 trs)
virtual

Definition at line 1125 of file btSoftBody.cpp.

◆ upcast() [1/2]

static btSoftBody * btSoftBody::upcast ( btCollisionObject colObj)
inlinestatic

Definition at line 1163 of file btSoftBody.h.

◆ upcast() [2/2]

static const btSoftBody * btSoftBody::upcast ( const btCollisionObject colObj)
inlinestatic

Definition at line 1157 of file btSoftBody.h.

◆ updateArea()

void btSoftBody::updateArea ( bool  averageArea = true)

Definition at line 3077 of file btSoftBody.cpp.

◆ updateBounds()

void btSoftBody::updateBounds ( )

Definition at line 2966 of file btSoftBody.cpp.

◆ updateClusters()

void btSoftBody::updateClusters ( )

Definition at line 3229 of file btSoftBody.cpp.

◆ updateConstants()

void btSoftBody::updateConstants ( )

Definition at line 3154 of file btSoftBody.cpp.

◆ updateDeactivation()

void btSoftBody::updateDeactivation ( btScalar  timeStep)

Definition at line 4707 of file btSoftBody.cpp.

◆ updateDeformation()

void btSoftBody::updateDeformation ( )

Definition at line 3524 of file btSoftBody.cpp.

◆ updateFace()

template<class DBVTNODE >
void btSoftBody::updateFace ( DBVTNODE *  node,
bool  use_velocity,
bool  margin 
)
inline

Definition at line 1264 of file btSoftBody.h.

◆ updateFaceTree()

void btSoftBody::updateFaceTree ( bool  use_velocity,
bool  margin 
)
inline

Definition at line 1300 of file btSoftBody.h.

◆ updateLinkConstants()

void btSoftBody::updateLinkConstants ( )

Definition at line 3141 of file btSoftBody.cpp.

◆ updateNode()

void btSoftBody::updateNode ( btDbvtNode node,
bool  use_velocity,
bool  margin 
)
inline

Definition at line 1225 of file btSoftBody.h.

◆ updateNodeTree()

void btSoftBody::updateNodeTree ( bool  use_velocity,
bool  margin 
)
inline

Definition at line 1257 of file btSoftBody.h.

◆ updateNormals()

void btSoftBody::updateNormals ( )

Definition at line 2937 of file btSoftBody.cpp.

◆ updatePose()

void btSoftBody::updatePose ( )

Definition at line 3040 of file btSoftBody.cpp.

◆ updateState()

void btSoftBody::updateState ( const btAlignedObjectArray< btVector3 > &  qs,
const btAlignedObjectArray< btVector3 > &  vs 
)

Definition at line 1489 of file btSoftBody.cpp.

◆ useSelfCollision()

bool btSoftBody::useSelfCollision ( )

Definition at line 4070 of file btSoftBody.cpp.

◆ VSolve_Links()

void btSoftBody::VSolve_Links ( btSoftBody psb,
btScalar  kst 
)
static

Definition at line 4018 of file btSoftBody.cpp.

◆ wantsSleeping()

bool btSoftBody::wantsSleeping ( )

Definition at line 4731 of file btSoftBody.cpp.

Member Data Documentation

◆ m_anchors

tAnchorArray btSoftBody::m_anchors

Definition at line 822 of file btSoftBody.h.

◆ m_bounds

btVector3 btSoftBody::m_bounds[2]

Definition at line 833 of file btSoftBody.h.

◆ m_bUpdateRtCst

bool btSoftBody::m_bUpdateRtCst

Definition at line 834 of file btSoftBody.h.

◆ m_cacheBarycenter

bool btSoftBody::m_cacheBarycenter

Definition at line 846 of file btSoftBody.h.

◆ m_cdbvt

btDbvt btSoftBody::m_cdbvt

Definition at line 838 of file btSoftBody.h.

◆ m_cfg

Config btSoftBody::m_cfg

Definition at line 808 of file btSoftBody.h.

◆ m_clusterConnectivity

btAlignedObjectArray<bool> btSoftBody::m_clusterConnectivity

Definition at line 855 of file btSoftBody.h.

◆ m_clusters

tClusterArray btSoftBody::m_clusters

Definition at line 839 of file btSoftBody.h.

◆ m_collisionDisabledObjects

btAlignedObjectArray<const class btCollisionObject*> btSoftBody::m_collisionDisabledObjects

Definition at line 77 of file btSoftBody.h.

◆ m_dampingCoefficient

btScalar btSoftBody::m_dampingCoefficient

Definition at line 840 of file btSoftBody.h.

◆ m_deformableAnchors

btAlignedObjectArray<DeformableNodeRigidAnchor> btSoftBody::m_deformableAnchors

Definition at line 823 of file btSoftBody.h.

◆ m_faceNodeContacts

btAlignedObjectArray<DeformableFaceNodeContact> btSoftBody::m_faceNodeContacts

Definition at line 826 of file btSoftBody.h.

◆ m_faceNodeContactsCCD

btAlignedObjectArray<DeformableFaceNodeContact> btSoftBody::m_faceNodeContactsCCD

Definition at line 828 of file btSoftBody.h.

◆ m_faceRigidContacts

btAlignedObjectArray<DeformableFaceRigidContact> btSoftBody::m_faceRigidContacts

Definition at line 827 of file btSoftBody.h.

◆ m_faces

tFaceArray btSoftBody::m_faces

Definition at line 817 of file btSoftBody.h.

◆ m_fdbvnt

btDbvntNode* btSoftBody::m_fdbvnt

Definition at line 837 of file btSoftBody.h.

◆ m_fdbvt

btDbvt btSoftBody::m_fdbvt

Definition at line 836 of file btSoftBody.h.

◆ m_gravityFactor

btScalar btSoftBody::m_gravityFactor

Definition at line 845 of file btSoftBody.h.

◆ m_joints

tJointArray btSoftBody::m_joints

Definition at line 830 of file btSoftBody.h.

◆ m_links

tLinkArray btSoftBody::m_links

Definition at line 816 of file btSoftBody.h.

◆ m_materials

tMaterialArray btSoftBody::m_materials

Definition at line 831 of file btSoftBody.h.

◆ m_maxSpeedSquared

btScalar btSoftBody::m_maxSpeedSquared

Definition at line 842 of file btSoftBody.h.

◆ m_ndbvt

btDbvt btSoftBody::m_ndbvt

Definition at line 835 of file btSoftBody.h.

◆ m_nodeRigidContacts

btAlignedObjectArray<DeformableNodeRigidContact> btSoftBody::m_nodeRigidContacts

Definition at line 825 of file btSoftBody.h.

◆ m_nodes

tNodeArray btSoftBody::m_nodes

Definition at line 814 of file btSoftBody.h.

◆ m_notes

tNoteArray btSoftBody::m_notes

Definition at line 813 of file btSoftBody.h.

◆ m_pose

Pose btSoftBody::m_pose

Definition at line 810 of file btSoftBody.h.

◆ m_quads

btAlignedObjectArray<btVector3> btSoftBody::m_quads

Definition at line 843 of file btSoftBody.h.

◆ m_rcontacts

tRContactArray btSoftBody::m_rcontacts

Definition at line 824 of file btSoftBody.h.

◆ m_reducedModel

bool btSoftBody::m_reducedModel

Definition at line 861 of file btSoftBody.h.

◆ m_renderFaces

tRenderFaceArray btSoftBody::m_renderFaces

Definition at line 818 of file btSoftBody.h.

◆ m_renderNodes

tRenderNodeArray btSoftBody::m_renderNodes

Definition at line 815 of file btSoftBody.h.

◆ m_renderNodesInterpolationWeights

btAlignedObjectArray<btVector4> btSoftBody::m_renderNodesInterpolationWeights

Definition at line 849 of file btSoftBody.h.

◆ m_renderNodesParents

btAlignedObjectArray<btAlignedObjectArray<const btSoftBody::Node*> > btSoftBody::m_renderNodesParents

Definition at line 850 of file btSoftBody.h.

◆ m_repulsionStiffness

btScalar btSoftBody::m_repulsionStiffness

Definition at line 844 of file btSoftBody.h.

◆ m_restLengthScale

btScalar btSoftBody::m_restLengthScale

Definition at line 859 of file btSoftBody.h.

◆ m_scontacts

tSContactArray btSoftBody::m_scontacts

Definition at line 829 of file btSoftBody.h.

◆ m_sleepingThreshold

btScalar btSoftBody::m_sleepingThreshold

Definition at line 841 of file btSoftBody.h.

◆ m_softBodySolver

btSoftBodySolver* btSoftBody::m_softBodySolver

Definition at line 80 of file btSoftBody.h.

◆ m_softSoftCollision

bool btSoftBody::m_softSoftCollision

Definition at line 853 of file btSoftBody.h.

◆ m_sst

SolverState btSoftBody::m_sst

Definition at line 809 of file btSoftBody.h.

◆ m_tag

void* btSoftBody::m_tag

Definition at line 811 of file btSoftBody.h.

◆ m_tetras

tTetraArray btSoftBody::m_tetras

Definition at line 819 of file btSoftBody.h.

◆ m_tetraScratches

btAlignedObjectArray<TetraScratch> btSoftBody::m_tetraScratches

Definition at line 820 of file btSoftBody.h.

◆ m_tetraScratchesTn

btAlignedObjectArray<TetraScratch> btSoftBody::m_tetraScratchesTn

Definition at line 821 of file btSoftBody.h.

◆ m_timeacc

btScalar btSoftBody::m_timeacc

Definition at line 832 of file btSoftBody.h.

◆ m_userIndexMapping

btAlignedObjectArray<int> btSoftBody::m_userIndexMapping

Definition at line 879 of file btSoftBody.h.

◆ m_useSelfCollision

bool btSoftBody::m_useSelfCollision

Definition at line 852 of file btSoftBody.h.

◆ m_windVelocity

btVector3 btSoftBody::m_windVelocity

Definition at line 857 of file btSoftBody.h.

◆ m_worldInfo

btSoftBodyWorldInfo* btSoftBody::m_worldInfo

Definition at line 812 of file btSoftBody.h.

◆ m_X

btAlignedObjectArray<btVector3> btSoftBody::m_X

Definition at line 847 of file btSoftBody.h.

◆ m_z

btAlignedObjectArray<btScalar> btSoftBody::m_z

Definition at line 851 of file btSoftBody.h.


The documentation for this class was generated from the following files: