KrisLibrary
1.0.0
|
A 2D contact point, i.e. a position, normal, and friction coefficient. More...
#include <Contact.h>
Public Member Functions | |
Real | frictionConeHalfAngle () const |
void | setfrictionConeHalfAngle (Real phi) |
bool | isValidForce (const Vector2 &f) const |
Returns true if the force lies within the friction cone. | |
Real | minFriction (const Vector2 &f) const |
void | quadraticForm (Matrix2 &A, Vector2 &b, Real &c) const |
Returns the quadratic form of the constraint f'*A*f + b*f + c >= 0. | |
Public Attributes | |
Vector2 | x |
Vector2 | n |
Real | kFriction |
A 2D contact point, i.e. a position, normal, and friction coefficient.
Real ContactPoint2D::minFriction | ( | const Vector2 & | f | ) | const |
Returns the min friction coefficient value required for f to be produced (for normal held constant). The result is negative for invalid forces.
References Math::dot().