33 #ifndef DART_CONSTRAINT_CONSTRAINTBASE_HPP_
34 #define DART_CONSTRAINT_CONSTRAINTBASE_HPP_
46 namespace constraint {
78 virtual const std::string&
getType()
const;
std::size_t index
Definition: SkelParser.cpp:1672
ConstrainedGroup is a group of skeletons that interact each other with constraints.
Definition: ConstrainedGroup.hpp:58
Constraint is a base class of concrete constraints classes.
Definition: ConstraintBase.hpp:75
std::size_t getDimension() const
Return dimesion of this constranit.
Definition: ConstraintBase.cpp:64
std::size_t mDim
Dimension of constraint.
Definition: ConstraintBase.hpp:135
virtual ~ConstraintBase()
Destructor.
Definition: ConstraintBase.cpp:47
virtual void applyImpulse(double *lambda)=0
Apply computed constraint impulse to constrained skeletons.
virtual void getInformation(ConstraintInfo *info)=0
Fill LCP variables.
virtual dynamics::SkeletonPtr getRootSkeleton() const =0
virtual const std::string & getType() const
Returns a string representing the constraint type.
Definition: ConstraintBase.cpp:53
virtual void getVelocityChange(double *vel, bool withCfm)=0
Get velocity change due to the uint impulse.
virtual void uniteSkeletons()
Definition: ConstraintBase.cpp:70
ConstraintBase()
Default contructor.
Definition: ConstraintBase.cpp:41
virtual bool isActive() const =0
Return true if this constraint is active.
virtual void applyUnitImpulse(std::size_t index)=0
Apply unit impulse to constraint space.
static dynamics::SkeletonPtr compressPath(dynamics::SkeletonPtr skeleton)
Definition: ConstraintBase.cpp:76
virtual void unexcite()=0
Unexcite the constraint.
virtual void update()=0
Update constraint using updated Skeleton's states.
virtual void excite()=0
Excite the constraint.
ConstraintSolver manages constraints and computes constraint impulses.
Definition: ConstraintSolver.hpp:57
std::shared_ptr< Skeleton > SkeletonPtr
Definition: SmartPointer.hpp:60
Definition: BulletCollisionDetector.cpp:65
ConstraintInfo.
Definition: ConstraintBase.hpp:50
double * w
Slack variable.
Definition: ConstraintBase.hpp:64
int * findex
Friction index.
Definition: ConstraintBase.hpp:67
double invTimeStep
Inverse of time step.
Definition: ConstraintBase.hpp:70
double * hi
Upper bound of x.
Definition: ConstraintBase.hpp:58
double * b
Bias term.
Definition: ConstraintBase.hpp:61
double * x
Impulse.
Definition: ConstraintBase.hpp:52
double * lo
Lower bound of x.
Definition: ConstraintBase.hpp:55