Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## 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.

Field Summary

Fields inherited from class toxi.physics.VerletSpring
`a, b`

Constructor Summary
`VerletMinDistanceSpring(VerletParticle a, VerletParticle b, float len, float str)`

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 toxi.physics.VerletSpring
`getRestLength, getStrength, lockA, lockB, setRestLength, setStrength`

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### VerletMinDistanceSpring

    public VerletMinDistanceSpring(VerletParticle a,
                                   VerletParticle b,
                                   float len,
                                   float str)

Method Detail

### 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 *

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD