Go to the documentation of this file.
16 #ifndef SURGSIM_PHYSICS_CONSTRAINTIMPLEMENTATION_H
17 #define SURGSIM_PHYSICS_CONSTRAINTIMPLEMENTATION_H
72 const std::shared_ptr<Localization>& localization,
74 size_t indexOfRepresentation,
75 size_t indexOfConstraint,
80 Eigen::SparseVector<double, Eigen::RowMajor, ptrdiff_t>
m_newH;
98 const std::shared_ptr<Localization>& localization,
100 size_t indexOfRepresentation,
101 size_t indexOfConstraint,
110 #endif // SURGSIM_PHYSICS_CONSTRAINTIMPLEMENTATION_H
Eigen::SparseVector< double, Eigen::RowMajor, ptrdiff_t > m_newH
Preallocated variable for derived implementations of doBuild.
Definition: ConstraintImplementation.h:80
virtual void doBuild(double dt, const ConstraintData &data, const std::shared_ptr< Localization > &localization, MlcpPhysicsProblem *mlcp, size_t indexOfRepresentation, size_t indexOfConstraint, ConstraintSideSign sign)=0
Builds the subset of an Mlcp physics problem associated to this implementation.
@ CONSTRAINT_NEGATIVE_SIDE
Definition: ConstraintImplementation.h:39
size_t getNumDof() const
Gets the number of degree of freedom for this implementation.
Definition: ConstraintImplementation.cpp:40
A description of a physical mixed LCP system to be solved.
Definition: MlcpPhysicsProblem.h:44
Base class for all constraint implementations. A ConstraintImplementation defines 1 side of a constra...
Definition: ConstraintImplementation.h:43
virtual ~ConstraintImplementation()
Destructor.
Definition: ConstraintImplementation.cpp:30
Definition: CompoundShapeToGraphics.cpp:30
@ CONSTRAINT_POSITIVE_SIDE
Definition: ConstraintImplementation.h:39
ConstraintSideSign
Enum defining on which side of the constraint an implementation is (positive or negative side)
Definition: ConstraintImplementation.h:39
ConstraintType
Definition: ConstraintType.h:25
virtual size_t doGetNumDof() const =0
Does get number of degree of freedom.
Base class for all CosntraintData Derived classes should be specific to a given constraint.
Definition: ConstraintData.h:28
static ConstraintImplementationFactory & getFactory()
Definition: ConstraintImplementation.cpp:34
This class manages ConstraintImplementations, and can be used to look up the correct implementation b...
Definition: ConstraintImplementationFactory.h:39
ConstraintImplementation()
Constructor.
Definition: ConstraintImplementation.cpp:26
virtual SurgSim::Physics::ConstraintType getConstraintType() const =0
Gets the constraint type for this ConstraintImplementation.
void build(double dt, const ConstraintData &data, const std::shared_ptr< Localization > &localization, MlcpPhysicsProblem *mlcp, size_t indexOfRepresentation, size_t indexOfConstraint, ConstraintSideSign sign)
Builds the subset of an Mlcp physics problem associated to this implementation.
Definition: ConstraintImplementation.cpp:45