Bullet Collision Detection & Physics Library
|
#include <btDeformableBodySolver.h>
Public Member Functions | |
btDeformableBodySolver () | |
virtual | ~btDeformableBodySolver () |
virtual SolverTypes | getSolverType () const |
Return the type of the solver. More... | |
virtual void | updateSoftBodies () |
Perform necessary per-step updates of soft bodies such as recomputing normals and bounding boxes. More... | |
virtual void | solveDeformableConstraints (btScalar solverdt) |
btScalar | solveContactConstraints (btCollisionObject **deformableBodies, int numDeformableBodies) |
btScalar | solveSplitImpulse (const btContactSolverInfo &infoGlobal) |
void | splitImpulseSetup (const btContactSolverInfo &infoGlobal) |
void | reinitialize (const btAlignedObjectArray< btSoftBody * > &softBodies, btScalar dt) |
void | setConstraints () |
virtual void | predictMotion (btScalar solverdt) |
Predict motion of soft bodies into next timestep. More... | |
void | predictDeformableMotion (btSoftBody *psb, btScalar dt) |
void | backupVelocity () |
void | setupDeformableSolve (bool implicit) |
void | revertVelocity () |
void | updateVelocity () |
bool | updateNodes () |
void | computeStep (TVStack &ddv, const TVStack &residual) |
btScalar | computeDescentStep (TVStack &ddv, const TVStack &residual, bool verbose=false) |
virtual void | copySoftBodyToVertexBuffer (const btSoftBody *const softBody, btVertexBufferDescriptor *vertexBuffer) |
virtual void | processCollision (btSoftBody *softBody, const btCollisionObjectWrapper *collisionObjectWrap) |
virtual void | processCollision (btSoftBody *softBody, btSoftBody *otherSoftBody) |
Process a collision between two soft bodies. More... | |
void | setImplicit (bool implicit) |
void | setLineSearch (bool lineSearch) |
void | updateState () |
void | updateDv (btScalar scale=1) |
void | updateTempPosition () |
void | backupDv () |
void | revertDv () |
void | updateEnergy (btScalar scale) |
btScalar | kineticEnergy () |
virtual void | optimize (btAlignedObjectArray< btSoftBody * > &softBodies, bool forceUpdate=false) |
Optimize soft bodies in this solver. More... | |
virtual void | solveConstraints (btScalar dt) |
Solve constraints for a set of soft bodies. More... | |
virtual bool | checkInitialized () |
Ensure that this solver is initialized. More... | |
virtual void | copyBackToSoftBodies (bool bMove=true) |
Copy necessary data back to the original soft body source objects. More... | |
![]() | |
btSoftBodySolver () | |
virtual | ~btSoftBodySolver () |
virtual void | processCollision (btSoftBody *, const struct btCollisionObjectWrapper *)=0 |
Process a collision between one of the world's soft bodies and another collision object. More... | |
virtual void | setNumberOfPositionIterations (int iterations) |
Set the number of velocity constraint solver iterations this solver uses. More... | |
virtual int | getNumberOfPositionIterations () |
Get the number of velocity constraint solver iterations this solver uses. More... | |
virtual void | setNumberOfVelocityIterations (int iterations) |
Set the number of velocity constraint solver iterations this solver uses. More... | |
virtual int | getNumberOfVelocityIterations () |
Get the number of velocity constraint solver iterations this solver uses. More... | |
float | getTimeScale () |
Return the timescale that the simulation is using. More... | |
Public Attributes | |
btDeformableBackwardEulerObjective * | m_objective |
Protected Attributes | |
int | m_numNodes |
TVStack | m_dv |
TVStack | m_backup_dv |
TVStack | m_ddv |
TVStack | m_residual |
btAlignedObjectArray< btSoftBody * > | m_softBodies |
TVStack | m_backupVelocity |
btScalar | m_dt |
btConjugateGradient< btDeformableBackwardEulerObjective > | m_cg |
bool | m_implicit |
int | m_maxNewtonIterations |
btScalar | m_newtonTolerance |
bool | m_lineSearch |
![]() | |
int | m_numberOfPositionIterations |
int | m_numberOfVelocityIterations |
float | m_timeScale |
Private Types | |
typedef btAlignedObjectArray< btVector3 > | TVStack |
Additional Inherited Members | |
![]() | |
enum | SolverTypes { DEFAULT_SOLVER, CPU_SOLVER, CL_SOLVER, CL_SIMD_SOLVER, DX_SOLVER, DX_SIMD_SOLVER, DEFORMABLE_SOLVER } |
Definition at line 30 of file btDeformableBodySolver.h.
|
private |
Definition at line 32 of file btDeformableBodySolver.h.
btDeformableBodySolver::btDeformableBodySolver | ( | ) |
Definition at line 22 of file btDeformableBodySolver.cpp.
|
virtual |
Definition at line 32 of file btDeformableBodySolver.cpp.
void btDeformableBodySolver::backupDv | ( | ) |
Definition at line 126 of file btDeformableBodySolver.cpp.
void btDeformableBodySolver::backupVelocity | ( | ) |
Definition at line 301 of file btDeformableBodySolver.cpp.
|
inlinevirtual |
Ensure that this solver is initialized.
Implements btSoftBodySolver.
Definition at line 160 of file btDeformableBodySolver.h.
btScalar btDeformableBodySolver::computeDescentStep | ( | TVStack & | ddv, |
const TVStack & | residual, | ||
bool | verbose = false |
||
) |
Definition at line 153 of file btDeformableBodySolver.cpp.
Definition at line 201 of file btDeformableBodySolver.cpp.
|
inlinevirtual |
Copy necessary data back to the original soft body source objects.
Implements btSoftBodySolver.
Definition at line 161 of file btDeformableBodySolver.h.
|
inlinevirtual |
Definition at line 110 of file btDeformableBodySolver.h.
|
inlinevirtual |
Return the type of the solver.
Implements btSoftBodySolver.
Definition at line 56 of file btDeformableBodySolver.h.
btScalar btDeformableBodySolver::kineticEnergy | ( | ) |
Definition at line 108 of file btDeformableBodySolver.cpp.
|
inlinevirtual |
Optimize soft bodies in this solver.
Implements btSoftBodySolver.
Definition at line 158 of file btDeformableBodySolver.h.
void btDeformableBodySolver::predictDeformableMotion | ( | btSoftBody * | psb, |
btScalar | dt | ||
) |
Definition at line 386 of file btDeformableBodySolver.cpp.
|
virtual |
Predict motion of soft bodies into next timestep.
Implements btSoftBodySolver.
Definition at line 370 of file btDeformableBodySolver.cpp.
|
inlinevirtual |
Process a collision between two soft bodies.
Implements btSoftBodySolver.
Definition at line 119 of file btDeformableBodySolver.h.
|
inlinevirtual |
Definition at line 113 of file btDeformableBodySolver.h.
void btDeformableBodySolver::reinitialize | ( | const btAlignedObjectArray< btSoftBody * > & | softBodies, |
btScalar | dt | ||
) |
Definition at line 206 of file btDeformableBodySolver.cpp.
void btDeformableBodySolver::revertDv | ( | ) |
Definition at line 135 of file btDeformableBodySolver.cpp.
void btDeformableBodySolver::revertVelocity | ( | ) |
Definition at line 343 of file btDeformableBodySolver.cpp.
void btDeformableBodySolver::setConstraints | ( | ) |
Definition at line 231 of file btDeformableBodySolver.cpp.
void btDeformableBodySolver::setImplicit | ( | bool | implicit | ) |
Definition at line 476 of file btDeformableBodySolver.cpp.
void btDeformableBodySolver::setLineSearch | ( | bool | lineSearch | ) |
Definition at line 482 of file btDeformableBodySolver.cpp.
void btDeformableBodySolver::setupDeformableSolve | ( | bool | implicit | ) |
Definition at line 314 of file btDeformableBodySolver.cpp.
|
inlinevirtual |
Solve constraints for a set of soft bodies.
Implements btSoftBodySolver.
Definition at line 159 of file btDeformableBodySolver.h.
btScalar btDeformableBodySolver::solveContactConstraints | ( | btCollisionObject ** | deformableBodies, |
int | numDeformableBodies | ||
) |
Definition at line 237 of file btDeformableBodySolver.cpp.
|
virtual |
Definition at line 37 of file btDeformableBodySolver.cpp.
btScalar btDeformableBodySolver::solveSplitImpulse | ( | const btContactSolverInfo & | infoGlobal | ) |
Definition at line 244 of file btDeformableBodySolver.cpp.
void btDeformableBodySolver::splitImpulseSetup | ( | const btContactSolverInfo & | infoGlobal | ) |
Definition at line 250 of file btDeformableBodySolver.cpp.
void btDeformableBodySolver::updateDv | ( | btScalar | scale = 1 | ) |
Definition at line 193 of file btDeformableBodySolver.cpp.
void btDeformableBodySolver::updateEnergy | ( | btScalar | scale | ) |
Definition at line 143 of file btDeformableBodySolver.cpp.
bool btDeformableBodySolver::updateNodes | ( | ) |
Definition at line 356 of file btDeformableBodySolver.cpp.
|
virtual |
Perform necessary per-step updates of soft bodies such as recomputing normals and bounding boxes.
Implements btSoftBodySolver.
Definition at line 463 of file btDeformableBodySolver.cpp.
void btDeformableBodySolver::updateState | ( | ) |
Definition at line 187 of file btDeformableBodySolver.cpp.
void btDeformableBodySolver::updateTempPosition | ( | ) |
Definition at line 281 of file btDeformableBodySolver.cpp.
void btDeformableBodySolver::updateVelocity | ( | ) |
Definition at line 255 of file btDeformableBodySolver.cpp.
|
protected |
Definition at line 36 of file btDeformableBodySolver.h.
|
protected |
Definition at line 40 of file btDeformableBodySolver.h.
|
protected |
Definition at line 42 of file btDeformableBodySolver.h.
|
protected |
Definition at line 37 of file btDeformableBodySolver.h.
|
protected |
Definition at line 41 of file btDeformableBodySolver.h.
|
protected |
Definition at line 35 of file btDeformableBodySolver.h.
|
protected |
Definition at line 43 of file btDeformableBodySolver.h.
|
protected |
Definition at line 46 of file btDeformableBodySolver.h.
|
protected |
Definition at line 44 of file btDeformableBodySolver.h.
|
protected |
Definition at line 45 of file btDeformableBodySolver.h.
|
protected |
Definition at line 34 of file btDeformableBodySolver.h.
btDeformableBackwardEulerObjective* btDeformableBodySolver::m_objective |
Definition at line 50 of file btDeformableBodySolver.h.
|
protected |
Definition at line 38 of file btDeformableBodySolver.h.
|
protected |
Definition at line 39 of file btDeformableBodySolver.h.