Table of Contents

Class ContactManager

Namespace
Alis.Core.Physic.Dynamics
Assembly
Alis.dll

The contact manager class

public class ContactManager

Inheritance

Inherited Members

Constructors

ContactManager(IBroadPhase)

Initializes a new instance of the Alis.Core.Physic.Dynamics.ContactManager class

internal ContactManager(IBroadPhase broadPhase)

Parameters

broadPhase IBroadPhase

The broad phase

Fields

BeginContact

Fires when a contact is created

public BeginContactDelegate BeginContact

Field Value

BeginContactDelegate

BroadPhase

The broad phase

public readonly IBroadPhase BroadPhase

Field Value

IBroadPhase

CollideMultithreadThreshold

A threshold for activating multiple cores to solve Collide. An World with a contact count above this threshold will use multiple threads to solve Collide. A value of 0 will always use multithreading. A value of (int.MaxValue) will never use multithreading. Typical values are {128 or 256}.

public int CollideMultithreadThreshold

Field Value

int

ContactFilter

The filter used by the contact manager.

public CollisionFilterDelegate ContactFilter

Field Value

CollisionFilterDelegate

ContactList

The contact list

public readonly ContactListHead ContactList

Field Value

ContactListHead

EndContact

Fires when a contact is deleted

public EndContactDelegate EndContact

Field Value

EndContactDelegate

OnBroadphaseCollision

Fires when the broadphase detects that two Fixtures are close to each other.

public BroadphaseDelegate OnBroadphaseCollision

Field Value

BroadphaseDelegate

PositionConstraintsMultithreadThreshold

A threshold for activating multiple cores to solve PositionConstraints. An Island with a contact count above this threshold will use multiple threads to solve PositionConstraints. A value of 0 will always use multithreading. A value of (int.MaxValue) will never use multithreading. Typical values are {128 or 256}.

public int PositionConstraintsMultithreadThreshold

Field Value

int

PostSolve

Fires after the solver has run

public PostSolveDelegate PostSolve

Field Value

PostSolveDelegate

PreSolve

Fires before the solver runs

public PreSolveDelegate PreSolve

Field Value

PreSolveDelegate

VelocityConstraintsMultithreadThreshold

A threshold for activating multiple cores to solve VelocityConstraints. An Island with a contact count above this threshold will use multiple threads to solve VelocityConstraints. A value of 0 will always use multithreading. A value of (int.MaxValue) will never use multithreading. Typical values are {128 or 256}.

public int VelocityConstraintsMultithreadThreshold

Field Value

int

_contactPoolList

The contact pool list

internal readonly ContactListHead _contactPoolList

Field Value

ContactListHead

updateList

A temporary list of contacts to be updated during Collide().

private readonly List<Contact> updateList

Field Value

List<Contact>

Properties

ContactCount

Gets or sets the value of the contact count

public int ContactCount { get; private set; }

Property Value

int

Methods

AddPair(int, int)

Adds the pair using the specified proxy id a

private void AddPair(int proxyIdA, int proxyIdB)

Parameters

proxyIdA int

The proxy id

proxyIdB int

The proxy id

Collide()

Collides this instance

internal void Collide()

Destroy(Contact)

Destroys the contact

internal void Destroy(Contact contact)

Parameters

contact Contact

The contact

FindNewContacts()

Finds the new contacts

internal void FindNewContacts()

ShouldCollide(Fixture, Fixture)

Describes whether should collide

private static bool ShouldCollide(Fixture fixtureA, Fixture fixtureB)

Parameters

fixtureA Fixture

The fixture

fixtureB Fixture

The fixture

Returns

bool

The collide