Navigation
API > API/Runtime > API/Runtime/GeometryCore
TBlockedGrid3 represents a 3D uniform grid.
The grid is allocated in BlockSize^3 blocks on-demand (BlockSize is a compile-time constant) allowing very large grids to be used without having to pre-allocate all the memory, eg for sparse/narrow-band use cases.
Block-level default values are returned when querying a grid cell in an unallocated block.,
Block-level access is provided to facilitate parallel algorithms. Additionally, 'Set' methods are provided that utilize critical sections provided by the caller.
| Name | TBlockedGrid3 |
| Type | class |
| Header File | /Engine/Source/Runtime/GeometryCore/Public/Spatial/BlockedDenseGrid3.h |
| Include Path | #include "Spatial/BlockedDenseGrid3.h" |
Syntax
template<typename ElemType, int32 BlockSize_>
class TBlockedGrid3 : public UE::Geometry::TBasicBlockedDenseGrid3< ElemType, BlockSize_ >
Inheritance Hierarchy
- TBlockedGrid3Layout → TBasicBlockedDenseGrid3 → TBlockedGrid3
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
TBlockedGrid3
(
int32 DimI, |
Create grid with specified domain. | Spatial/BlockedDenseGrid3.h | |
| Create empty grid | Spatial/BlockedDenseGrid3.h |
Typedefs
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| BlockData3Type | TBlockData3< ElemType, BlockSize_ > | Spatial/BlockedDenseGrid3.h | |
| BlockedDenseGridType | TBasicBlockedDenseGrid3< ElemType, BlockSize_ > | Spatial/BlockedDenseGrid3.h | |
| BlockedGrid3LayoutType | TBlockedGrid3Layout< BlockSize_ > | Spatial/BlockedDenseGrid3.h | |
| FBlock3 | TBasicBlockedDenseGrid3< ElemType, BlockSize_ >::FBlock3 | Spatial/BlockedDenseGrid3.h |
Constants
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| BlockElemCount | int32 | Spatial/BlockedDenseGrid3.h | |
| BlockSize | int32 | Spatial/BlockedDenseGrid3.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
TArray< const BlockData3Type * > GetAllocatedBlocks () |
Spatial/BlockedDenseGrid3.h | ||
TArray< BlockData3Type * > GetAllocatedBlocks () |
Spatial/BlockedDenseGrid3.h | ||
TArray< const BlockData3Type * > GetAllocatedConstBlocks() |
Spatial/BlockedDenseGrid3.h | ||
const TUniquePtr< BlockData3Type > & GetBlockData
(
int32 BlockIndex |
Spatial/BlockedDenseGrid3.h | ||
TUniquePtr< BlockData3Type > & GetBlockData
(
int32 BlockIndex |
Spatial/BlockedDenseGrid3.h | ||
TUniquePtr< BlockData3Type > & GetBlockData
(
const FVector3i& BlockIJK |
Spatial/BlockedDenseGrid3.h | ||
const TUniquePtr< BlockData3Type > & GetBlockData
(
const FVector3i& BlockIJK |
Spatial/BlockedDenseGrid3.h | ||
ElemType GetBlockDefaultValue
(
const FVector3i& BlockIJK |
Methods on the block's default values. | Spatial/BlockedDenseGrid3.h | |
int32 GetNumBlocks() |
Spatial/BlockedDenseGrid3.h | ||
bool IsBlockAllocated
(
const FVector3i& BlockIJK |
Spatial/BlockedDenseGrid3.h | ||
void ProcessBlockDefaultValue
(
const FVector3i& BlockIJK, |
Update the default value for the specified block using a functor | Spatial/BlockedDenseGrid3.h | |
void ProcessValueWithLock
(
int32 I, |
Call an external lambda with a reference to the grid value at (I,J,K). | Spatial/BlockedDenseGrid3.h | |
void ProcessValueWithLock
(
const FVector3i& CellIJK, |
Call an external lambda with a reference to the grid value at CellIJK. | Spatial/BlockedDenseGrid3.h | |
void SetBlockDefaultValue
(
const FVector3i& BlockIJK, |
Update the default value for the specified block. | Spatial/BlockedDenseGrid3.h | |
void SetValueWithLock
(
const FVector3i& CellIJK, |
Set the grid value at CellIJK, with user supplied locking in the form of a function of the form FCriticalSection& CriticalSectionProvider(id) | Spatial/BlockedDenseGrid3.h | |
void SetValueWithLock
(
int32 I, |
Set the grid value at (I,J,K), with user supplied locking in the form of a function of the form FCriticalSection& CriticalSectionProvider(id) | Spatial/BlockedDenseGrid3.h | |
BlockData3Type & TouchBlockData
(
const FVector3i& BlockIJK |
Spatial/BlockedDenseGrid3.h |
Protected
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
ElemType ReadBlockDefaultValue
(
const int32& BlockIndex |
Spatial/BlockedDenseGrid3.h | ||
ElemType ReadBlockDefaultValue
(
const FVector3i& BlockIJK |
Spatial/BlockedDenseGrid3.h | ||
void WriteBlockDefaultValue
(
const FVector3i& BlockIJK, |
Spatial/BlockedDenseGrid3.h | ||
void WriteBlockDefaultValue
(
const int32 BlockIndex, |
Spatial/BlockedDenseGrid3.h | ||
void WriteBlockDefaultValueWithLock
(
const int32 BlockIndex, |
Spatial/BlockedDenseGrid3.h |