Module org.dyn4j
Package org.dyn4j.dynamics.contact
Interface ContactConstraintSolver<T extends PhysicsBody>
-
- Type Parameters:
T
- thePhysicsBody
type
- All Known Implementing Classes:
SequentialImpulses
public interface ContactConstraintSolver<T extends PhysicsBody>
Represents an impulse/velocity based rigidPhysicsBody
collision resolver.- Since:
- 3.2.0
- Version:
- 4.0.0
- Author:
- William Bittle
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
initialize(List<ContactConstraint<T>> contactConstraints, TimeStep step, Settings settings)
Performs initialization of the contact constraints.boolean
solvePositionContraints(List<ContactConstraint<T>> contactConstraints, TimeStep step, Settings settings)
Solves theContactConstraint
s on the position level.void
solveVelocityContraints(List<ContactConstraint<T>> contactConstraints, TimeStep step, Settings settings)
Solves theContactConstraint
s on the velocity level.
-
-
-
Method Detail
-
initialize
void initialize(List<ContactConstraint<T>> contactConstraints, TimeStep step, Settings settings)
Performs initialization of the contact constraints.- Parameters:
contactConstraints
- the contact constraints to solvestep
- the time step informationsettings
- the current settings
-
solveVelocityContraints
void solveVelocityContraints(List<ContactConstraint<T>> contactConstraints, TimeStep step, Settings settings)
Solves theContactConstraint
s on the velocity level.- Parameters:
contactConstraints
- the contact constraints to solvestep
- the time step informationsettings
- the current settings
-
solvePositionContraints
boolean solvePositionContraints(List<ContactConstraint<T>> contactConstraints, TimeStep step, Settings settings)
Solves theContactConstraint
s on the position level.- Parameters:
contactConstraints
- the contact constraints to solvestep
- the time step informationsettings
- the current settings- Returns:
- boolean true if the constraints have been solved
-
-