# Class FixtureDef

java.lang.Object
com.codename1.gaming.physics.box2d.dynamics.FixtureDef

public class FixtureDef extends Object
A fixture definition is used to create a fixture. This class defines an abstract fixture definition. You can reuse fixture definitions safely.

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `float`
  `density`
  The density, usually in kg/m^2
  `Filter`
  `filter`
  Contact filtering data;
  `float`
  `friction`
  The 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 restitution (elasticity) usually in the range [0,1].
  `Shape`
  `shape`
  The shape, this must be set.
  `Object`
  `userData`
  Use this to store application specific fixture data.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `FixtureDef()`

- ## Method Summary

  ### Methods inherited from class Object

  `clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Field Details

  - ### shape

    public Shape shape
    The shape, this must be set. The shape will be cloned, so you can create the shape on the stack.

  - ### userData

    public Object userData
    Use this to store application specific fixture data.

  - ### friction

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

  - ### restitution

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

  - ### density

    public float density
    The density, usually in kg/m^2

  - ### isSensor

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

  - ### filter

    public Filter filter
    Contact filtering data;

- ## Constructor Details

  - ### FixtureDef

    public FixtureDef()