Package org.jbox2d.collision.shapes
Class MassData
- java.lang.Object
-
- org.jbox2d.collision.shapes.MassData
-
public class MassData extends java.lang.Object
This holds the mass data computed for a shape.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description MassData
clone()
Return a copy of this object.void
set(MassData md)
-
-
-
Field Detail
-
mass
public float mass
The mass of the shape, usually in kilograms.
-
center
public final Vec2 center
The position of the shape's centroid relative to the shape's origin.
-
I
public float I
The rotational inertia of the shape about the local origin.
-
-
Constructor Detail
-
MassData
public MassData()
Blank mass data
-
MassData
public MassData(MassData md)
Copies from the given mass data- Parameters:
md
- mass data to copy from
-
-