org.jbox2d.collision.shapes
Class ShapeDef

java.lang.Object
  extended by org.jbox2d.collision.shapes.ShapeDef
Direct Known Subclasses:
CircleDef, EdgeChainDef, PointDef, PolygonDef

public class ShapeDef
extends Object

Superclass for shape definitions. You should usually use CircleDef or PolygonDef to define concrete shapes.


Field Summary
 float density
          The shape's density, usually in kg/m^2.
 FilterData filter
          Contact filtering data.
 float friction
          The shape's friction coefficient, usually in the range [0,1].
 boolean isSensor
          A sensor shape collects contact information but never generates a collision response.
 float restitution
          The shape's restitution (elasticity) usually in the range [0,1].
 ShapeType type
          Holds the shape type for down-casting.
 Object userData
          Use this to store application specify shape data.
 
Constructor Summary
ShapeDef()
           
 
Method Summary
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

type

public ShapeType type
Holds the shape type for down-casting.


userData

public Object userData
Use this to store application specify shape data.


friction

public float friction
The shape's friction coefficient, usually in the range [0,1].


restitution

public float restitution
The shape's restitution (elasticity) usually in the range [0,1].


density

public float density
The shape's density, usually in kg/m^2.


filter

public FilterData filter
Contact filtering data.


isSensor

public boolean isSensor
A sensor shape collects contact information but never generates a collision response.

Constructor Detail

ShapeDef

public ShapeDef()