toxi.physics
Class VerletMinDistanceSpring
java.lang.Object
toxi.physics.VerletSpring
toxi.physics.VerletMinDistanceSpring
public class VerletMinDistanceSpring
- extends VerletSpring
Implements a string which will only enforce its rest length if the current
distance is less than its rest length. This is handy if you just want to
ensure objects are at least a certain distance from each other, but don't
care if it's bigger than the enforced minimum.
Method Summary |
void |
update(boolean applyConstraints)
Updates both particle positions (if not locked) based on their current
distance, weight and spring configuration * |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
VerletMinDistanceSpring
public VerletMinDistanceSpring(VerletParticle a,
VerletParticle b,
float len,
float str)
update
public void update(boolean applyConstraints)
- Description copied from class:
VerletSpring
- Updates both particle positions (if not locked) based on their current
distance, weight and spring configuration *