Table of Contents

Interface ICollisionTestContinuation

Namespace
BepuPhysics.CollisionDetection
Assembly
BepuPhysics.dll

Defines a type which includes information necessary to apply some form of post processing to a collision test result.

public interface ICollisionTestContinuation

Methods

Create(int, BufferPool)

Creates a collision test continuation with the given number of slots for subpairs.

void Create(int slots, BufferPool pool)

Parameters

slots int

Number of subpair slots to include in the continuation.

pool BufferPool

Pool to take resources from.

OnChildCompleted<TCallbacks>(ref PairContinuation, ref ConvexContactManifold, ref CollisionBatcher<TCallbacks>)

Handles what to do next when the child pair has finished execution and the resulting manifold is available.

void OnChildCompleted<TCallbacks>(ref PairContinuation report, ref ConvexContactManifold manifold, ref CollisionBatcher<TCallbacks> batcher) where TCallbacks : struct, ICollisionCallbacks

Parameters

report PairContinuation

Continuation instance being considered.

manifold ConvexContactManifold

Contact manifold for the child pair.

batcher CollisionBatcher<TCallbacks>

Collision batcher processing the pair.

Type Parameters

TCallbacks

Type of the callbacks used in the batcher.

OnUntestedChildCompleted<TCallbacks>(ref PairContinuation, ref CollisionBatcher<TCallbacks>)

Handles what to do next when the child pair was rejected for testing, and no manifold exists.

void OnUntestedChildCompleted<TCallbacks>(ref PairContinuation report, ref CollisionBatcher<TCallbacks> batcher) where TCallbacks : struct, ICollisionCallbacks

Parameters

report PairContinuation

Continuation instance being considered.

batcher CollisionBatcher<TCallbacks>

Collision batcher processing the pair.

Type Parameters

TCallbacks

Type of the callbacks used in the batcher.

TryFlush<TCallbacks>(int, ref CollisionBatcher<TCallbacks>)

Checks if the parent pair is complete and should be flushed.

bool TryFlush<TCallbacks>(int pairId, ref CollisionBatcher<TCallbacks> batcher) where TCallbacks : struct, ICollisionCallbacks

Parameters

pairId int

Id of the pair to attempt to flush.

batcher CollisionBatcher<TCallbacks>

Collision batcher processing the pair.

Returns

bool

True if the pair was done and got flushed, false otherwise.

Type Parameters

TCallbacks

Type of the callbacks used in the batcher.