C# Class BEPUphysics.BroadPhaseSystems.SortAndSweep.Grid2DSortAndSweep

Broad phase implementation that partitions objects into a 2d grid, and then performs a sort and sweep on the final axis.
This broad phase typically has very good collision performance and scales well with multithreading, but its query times can sometimes be worse than tree-based systems since it must scan cells. Keeping rays as short as possible helps avoid unnecessary cell checks. The performance can degrade noticeably in some situations involving significant off-axis motion.
Inheritance: BroadPhase
Datei anzeigen Open project: Indiefreaks/igf Class Usage Examples

Public Methods

Method Description
Add ( BroadPhaseEntry entry ) : void

Adds an entry to the broad phase.

Grid2DSortAndSweep ( ) : System

Constructs a grid-based sort and sweep broad phase.

Grid2DSortAndSweep ( IThreadManager threadManager ) : System

Constructs a grid-based sort and sweep broad phase.

Remove ( BroadPhaseEntry entry ) : void

Removes an entry from the broad phase.

Protected Methods

Method Description
UpdateMultithreaded ( ) : void
UpdateSingleThreaded ( ) : void

Private Methods

Method Description
ComputeCell ( Vector3 &v, Int2 &cell ) : void
UpdateCell ( int i ) : void
UpdateEntry ( int i ) : void

Method Details

Add() public method

Adds an entry to the broad phase.
public Add ( BroadPhaseEntry entry ) : void
entry BEPUphysics.BroadPhaseEntries.BroadPhaseEntry Entry to add.
return void

Grid2DSortAndSweep() public method

Constructs a grid-based sort and sweep broad phase.
public Grid2DSortAndSweep ( ) : System
return System

Grid2DSortAndSweep() public method

Constructs a grid-based sort and sweep broad phase.
public Grid2DSortAndSweep ( IThreadManager threadManager ) : System
threadManager IThreadManager Thread manager to use for the broad phase.
return System

Remove() public method

Removes an entry from the broad phase.
public Remove ( BroadPhaseEntry entry ) : void
entry BEPUphysics.BroadPhaseEntries.BroadPhaseEntry Entry to remove.
return void

UpdateMultithreaded() protected method

protected UpdateMultithreaded ( ) : void
return void

UpdateSingleThreaded() protected method

protected UpdateSingleThreaded ( ) : void
return void