org.ode4j.ode
Interface DBallJoint

All Superinterfaces:
DJoint

public interface DBallJoint
extends DJoint


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.ode4j.ode.DJoint
DJoint.DJointFeedback, DJoint.PARAM, DJoint.PARAM_GROUPS, DJoint.PARAM_N
 
Field Summary
 
Fields inherited from interface org.ode4j.ode.DJoint
P_OFS_1, P_OFS_2, P_OFS_3
 
Method Summary
 void getAnchor(DVector3 result)
          Get the joint anchor point, in world coordinates.
 void getAnchor2(DVector3 result)
          Get the joint anchor point, in world coordinates.
 double getParam(DJoint.PARAM_N parameter)
          Get joint parameter.
 void setAnchor(double x, double y, double z)
          Set the joint anchor point.
 void setAnchor(DVector3C a)
          Set the joint anchor point.
 void setAnchor2(double x, double y, double z)
          Set the joint anchor point.
 void setAnchor2(DVector3C a)
          Set the joint anchor point on body 2.
 void setParam(DJoint.PARAM_N parameter, double value)
          Param setting for Ball joints
 
Methods inherited from interface org.ode4j.ode.DJoint
attach, DESTRUCTOR, disable, enable, getBody, getData, getFeedback, getNumBodies, isEnabled, setData, setFeedback
 

Method Detail

setAnchor

void setAnchor(double x,
               double y,
               double z)
Set the joint anchor point.


setAnchor2

void setAnchor2(double x,
                double y,
                double z)
Set the joint anchor point.


setAnchor

void setAnchor(DVector3C a)
Set the joint anchor point.


setAnchor2

void setAnchor2(DVector3C a)
Set the joint anchor point on body 2.


getAnchor

void getAnchor(DVector3 result)
Get the joint anchor point, in world coordinates. This returns the point on body 1. If the joint is perfectly satisfied, this will be the same as the point on body 2.


getAnchor2

void getAnchor2(DVector3 result)
Get the joint anchor point, in world coordinates.

This returns the point on body 2. You can think of a ball and socket joint as trying to keep the result of dJointGetBallAnchor() and dJointGetBallAnchor2() the same. If the joint is perfectly satisfied, this function will return the same value as dJointGetBallAnchor() to within roundoff errors. dJointGetBallAnchor2() can be used, along with dJointGetBallAnchor(), to see how far the joint has come apart.


setParam

void setParam(DJoint.PARAM_N parameter,
              double value)
Param setting for Ball joints

Specified by:
setParam in interface DJoint

getParam

double getParam(DJoint.PARAM_N parameter)
Get joint parameter.

Specified by:
getParam in interface DJoint