net.java.dev.joode.stepper
Class AbstractStepperFunction

java.lang.Object
  extended by net.java.dev.joode.stepper.AbstractStepperFunction
All Implemented Interfaces:
StepperFunction
Direct Known Subclasses:
QuickStepper

public abstract class AbstractStepperFunction
extends java.lang.Object
implements StepperFunction


Field Summary
static boolean GYROSCOPIC
           
 
Fields inherited from interface net.java.dev.joode.stepper.StepperFunction
EULER, RK4
 
Constructor Summary
AbstractStepperFunction()
           
 
Method Summary
protected  void addExternalForces(Body[] body, int bcount)
           
protected  int createRowOffsetArray(int jcount, Joint.Info1[] info, int[] ofs)
           
protected  Matrix3[] getInverseInertiaTensors(Body[] body, int bcount)
           
protected  int getJointInfo(Joint[] joint, int jcount, Joint.Info1[] info)
           
protected  void resetForces(Body[] body, int bcount)
           
 void step(World world, Body[] body, int bcount, Joint[] joint, int jcount, float stepsize)
           
protected abstract  void stepConstraints(int m, World world, Body[] body, int bcount, Joint[] joint, int jcount, Joint.Info1[] info, int[] ofs, Matrix3[] invI, float stepsize)
           
protected  void tagBodies(Body[] body, int bcount)
           
protected  void updateVelocity(Body[] body, int bcount, Matrix3[] invI, float stepsize)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

GYROSCOPIC

public static final boolean GYROSCOPIC
See Also:
Constant Field Values
Constructor Detail

AbstractStepperFunction

public AbstractStepperFunction()
Method Detail

step

public void step(World world,
                 Body[] body,
                 int bcount,
                 Joint[] joint,
                 int jcount,
                 float stepsize)
Specified by:
step in interface StepperFunction

tagBodies

protected void tagBodies(Body[] body,
                         int bcount)

addExternalForces

protected void addExternalForces(Body[] body,
                                 int bcount)

getInverseInertiaTensors

protected Matrix3[] getInverseInertiaTensors(Body[] body,
                                             int bcount)

getJointInfo

protected int getJointInfo(Joint[] joint,
                           int jcount,
                           Joint.Info1[] info)

createRowOffsetArray

protected int createRowOffsetArray(int jcount,
                                   Joint.Info1[] info,
                                   int[] ofs)

stepConstraints

protected abstract void stepConstraints(int m,
                                        World world,
                                        Body[] body,
                                        int bcount,
                                        Joint[] joint,
                                        int jcount,
                                        Joint.Info1[] info,
                                        int[] ofs,
                                        Matrix3[] invI,
                                        float stepsize)

updateVelocity

protected void updateVelocity(Body[] body,
                              int bcount,
                              Matrix3[] invI,
                              float stepsize)

resetForces

protected void resetForces(Body[] body,
                           int bcount)