C# Class Project290.Physics.Dynamics.Contacts.Contact

The class manages contact between two shapes. A contact exists for each overlapping AABB in the broad-phase (except if filtered). Therefore a contact object may exist that has no contact points.
Show file Open project: scastle/Solitude Class Usage Examples

Public Properties

Property Type Description
FixtureA Fixture
FixtureB Fixture
Manifold Project290.Physics.Collision.Manifold
TOI float

Public Methods

Method Description
FlagForFiltering ( ) : void

Flag this contact for filtering. Filtering will occur the next time step.

GetManifold ( Manifold &manifold ) : void

Get the contact manifold. Do not modify the manifold unless you understand the internals of Box2D.

GetWorldManifold ( Vector2 &normal, FixedArray2 &points ) : void

Gets the world manifold.

IsTouching ( ) : bool

Determines whether this contact is touching.

Private Methods

Method Description
Contact ( Fixture fA, int indexA, Fixture fB, int indexB ) : System
Create ( Fixture fixtureA, int indexA, Fixture fixtureB, int indexB ) : Contact
Destroy ( ) : void
Evaluate ( Manifold &manifold, Transform &transformA, Transform &transformB ) : void

Evaluate this contact with your own manifold and transforms.

Reset ( Fixture fA, int indexA, Fixture fB, int indexB ) : void
Update ( ContactManager contactManager ) : void

Update the contact manifold and touching status. Note: do not assume the fixture AABBs are overlapping or are valid.

Method Details

FlagForFiltering() public method

Flag this contact for filtering. Filtering will occur the next time step.
public FlagForFiltering ( ) : void
return void

GetManifold() public method

Get the contact manifold. Do not modify the manifold unless you understand the internals of Box2D.
public GetManifold ( Manifold &manifold ) : void
manifold Project290.Physics.Collision.Manifold The manifold.
return void

GetWorldManifold() public method

Gets the world manifold.
public GetWorldManifold ( Vector2 &normal, FixedArray2 &points ) : void
normal Vector2
points FixedArray2
return void

IsTouching() public method

Determines whether this contact is touching.
public IsTouching ( ) : bool
return bool

Property Details

FixtureA public property

public Fixture FixtureA
return Fixture

FixtureB public property

public Fixture FixtureB
return Fixture

Manifold public property

public Manifold,Project290.Physics.Collision Manifold
return Project290.Physics.Collision.Manifold

TOI public property

public float TOI
return float