#include <RuntimeSpatialHashGridHelper.h>
|
| | FGrid2D (const FVector2D &InOrigin, int64 InCellSize, int64 InGridSize) |
| |
| bool | IsValidCoords (const FGridCellCoord2 &InCoords) const |
| |
| bool | GetCellBounds (int64 InIndex, FBox2D &OutBounds) const |
| |
| bool | GetCellBounds (const FGridCellCoord2 &InCoords, FBox2D &OutBounds, bool bCheckIsValidCoord=true) const |
| |
| bool | GetCellCoords (const FVector2D &InPos, FGridCellCoord2 &OutCoords) const |
| |
| bool | GetCellCoords (const FBox2D &InBounds2D, FGridCellCoord2 &OutMinCellCoords, FGridCellCoord2 &OutMaxCellCoords) const |
| |
| bool | GetCellIndex (const FGridCellCoord2 &InCoords, uint64 &OutIndex) const |
| |
| bool | GetCellIndex (const FVector &InPos, uint64 &OutIndex) const |
| |
| int32 | GetNumIntersectingCells (const FBox &InBox) const |
| |
| int32 | ForEachIntersectingCellsBreakable (const FBox &InBox, TFunctionRef< bool(const FGridCellCoord2 &)> InOperation) const |
| |
| int32 | ForEachIntersectingCells (const FBox &InBox, TFunctionRef< void(const FGridCellCoord2 &)> InOperation) const |
| |
| int32 | ForEachIntersectingCells (const FSphere &InSphere, TFunctionRef< void(const FGridCellCoord2 &)> InOperation) const |
| |
| int32 | ForEachIntersectingCells (const FSphericalSector &InShape, TFunctionRef< void(const FGridCellCoord2 &)> InOperation) const |
| |
◆ FGrid2D()
| FSquare2DGridHelper::FGrid2D::FGrid2D |
( |
const FVector2D & |
InOrigin, |
|
|
int64 |
InCellSize, |
|
|
int64 |
InGridSize |
|
) |
| |
|
inline |
◆ ForEachIntersectingCells() [1/3]
◆ ForEachIntersectingCells() [2/3]
Runs a function on all intersecting cells for the provided sphere
- Returns
- the number of intersecting cells
◆ ForEachIntersectingCells() [3/3]
Runs a function on all intersecting cells for the provided spherical sector
- Returns
- the number of intersecting cells
◆ ForEachIntersectingCellsBreakable()
Runs a function on all intersecting cells for the provided box
- Returns
- the number of intersecting cells
◆ GetCellBounds() [1/2]
Returns the cell bounds
- Returns
- true if the specified coord was valid
◆ GetCellBounds() [2/2]
| bool FSquare2DGridHelper::FGrid2D::GetCellBounds |
( |
int64 |
InIndex, |
|
|
FBox2D & |
OutBounds |
|
) |
| const |
|
inline |
Returns the cell bounds
- Returns
- true if the specified index was valid
◆ GetCellCoords() [1/2]
Returns the cells coordinates of the provided box
- Returns
- true if the bounds was intersecting with the grid
◆ GetCellCoords() [2/2]
Returns the cell coordinates of the provided position
- Returns
- true if the position was inside the grid
◆ GetCellIndex() [1/2]
Returns the cell index of the provided coords
- Returns
- true if the coords was inside the grid
◆ GetCellIndex() [2/2]
| bool FSquare2DGridHelper::FGrid2D::GetCellIndex |
( |
const FVector & |
InPos, |
|
|
uint64 & |
OutIndex |
|
) |
| const |
|
inline |
Returns the cell index of the provided position
- Returns
- true if the position was inside the grid
◆ GetNumIntersectingCells()
| int32 FSquare2DGridHelper::FGrid2D::GetNumIntersectingCells |
( |
const FBox & |
InBox | ) |
const |
|
inline |
Get the number of intersecting cells of the provided box
- Returns
- the number of intersecting cells
◆ IsValidCoords()
Validate that the coordinates fit the grid size
- Returns
- true if the specified coordinates are valid
◆ CellSize
| int64 FSquare2DGridHelper::FGrid2D::CellSize |
◆ GridSize
| int64 FSquare2DGridHelper::FGrid2D::GridSize |
◆ Origin
| FVector2D FSquare2DGridHelper::FGrid2D::Origin |
The documentation for this struct was generated from the following files: