cs567.rigidbody
Class SpringForcePoint2Body

java.lang.Object
  extended by cs567.rigidbody.SpringForcePoint2Body
All Implemented Interfaces:
Force

public class SpringForcePoint2Body
extends java.lang.Object
implements Force

Spring force between one body and a proxy point.


Field Summary
(package private)  RigidBody R
           
(package private)  RigidBodySystem S
           
(package private)  javax.vecmath.Point2d x
           
 
Constructor Summary
SpringForcePoint2Body(RigidBody R, javax.vecmath.Point2d x, RigidBodySystem S)
           
 
Method Summary
 void applyForce()
          Causes force to be applied to affected bodies.
 void display(javax.media.opengl.GL gl)
          Display any instructive force information, e.g., connecting spring.
 RigidBodySystem getSystem()
          Reference to the system this force affects.
 void updatePoint(javax.vecmath.Point2d xNew)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

R

RigidBody R

x

javax.vecmath.Point2d x

S

RigidBodySystem S
Constructor Detail

SpringForcePoint2Body

SpringForcePoint2Body(RigidBody R,
                      javax.vecmath.Point2d x,
                      RigidBodySystem S)
Method Detail

updatePoint

public void updatePoint(javax.vecmath.Point2d xNew)

applyForce

public void applyForce()
Description copied from interface: Force
Causes force to be applied to affected bodies.

Specified by:
applyForce in interface Force

display

public void display(javax.media.opengl.GL gl)
Description copied from interface: Force
Display any instructive force information, e.g., connecting spring.

Specified by:
display in interface Force

getSystem

public RigidBodySystem getSystem()
Description copied from interface: Force
Reference to the system this force affects.

Specified by:
getSystem in interface Force