|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jbox2d.dynamics.joints.JointDef
org.jbox2d.dynamics.joints.DistanceJointDef
public class DistanceJointDef
Definition for a distance joint. A distance joint keeps two points on two bodies at a constant distance from each other.
| Field Summary | |
|---|---|
float |
dampingRatio
|
float |
frequencyHz
|
float |
length
The equilibrium length between the anchor points. |
Vec2 |
localAnchor1
The local anchor point relative to body1's origin. |
Vec2 |
localAnchor2
The local anchor point relative to body2's origin. |
| Fields inherited from class org.jbox2d.dynamics.joints.JointDef |
|---|
body1, body2, collideConnected, type, userData |
| Constructor Summary | |
|---|---|
DistanceJointDef()
|
|
| Method Summary | |
|---|---|
void |
initialize(Body b1,
Body b2,
Vec2 anchor1,
Vec2 anchor2)
Initialize the bodies, anchors, and length using the world anchors. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public Vec2 localAnchor1
public Vec2 localAnchor2
public float length
public float frequencyHz
public float dampingRatio
| Constructor Detail |
|---|
public DistanceJointDef()
| Method Detail |
|---|
public void initialize(Body b1,
Body b2,
Vec2 anchor1,
Vec2 anchor2)
b1 - First bodyb2 - Second bodyanchor1 - World anchor on first bodyanchor2 - World anchor on second body
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||