Navigation
API > API/Runtime > API/Runtime/Chaos
Index based view, specialized for working with several ranges within a same array such as particles.
| Name | TPBDActiveView |
| Type | class |
| Header File | /Engine/Source/Runtime/Experimental/Chaos/Public/Chaos/PBDActiveView.h |
| Include Path | #include "Chaos/PBDActiveView.h" |
Syntax
template<typename TItemsType>
class TPBDActiveView
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
TPBDActiveView
(
TItemsType& InItems |
Chaos/PBDActiveView.h |
Variables
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| Items | TItemsType & | Chaos/PBDActiveView.h | ||
| Ranges | TArray< FActiveViewRange > | Chaos/PBDActiveView.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void ActivateRange
(
int32 Offset, |
Activate (or deactivate) the range starting at the specified offset. | Chaos/PBDActiveView.h | |
int32 AddRange
(
int32 NumItems, |
Add a new active (or inactive) range at the end of the list, and return its offset. | Chaos/PBDActiveView.h | |
| Return a list of pair (offset, range) of all active ranges. | Chaos/PBDActiveView.h | ||
int32 GetActiveSize() |
Return the total number of active items from all active ranges. | Chaos/PBDActiveView.h | |
TConstArrayView< FActiveViewRange > GetAllRanges() |
Return internal ranges. | Chaos/PBDActiveView.h | |
TItemsType & GetItems() |
Return all items, including those not in the view. | Chaos/PBDActiveView.h | |
int32 GetNumRanges() |
Chaos/PBDActiveView.h | ||
TConstArrayView< int32 > GetRanges() |
Chaos/PBDActiveView.h | ||
int32 GetRangeSize
(
int32 Offset |
Return the number of items in the range starting at the specified offset. | Chaos/PBDActiveView.h | |
bool HasActiveRange() |
Return whether there is any active range in the view. | Chaos/PBDActiveView.h | |
void ParallelFor
(
TFunctionRef< void(TItemsType&, int32)> Function, |
Execute the specified function in parallel, on all items for each active range (sequential range, parallel items). Set MinParallelSize to run sequential on the smaller ranges. | Chaos/PBDActiveView.h | |
void ParallelFor
(
TFunctionRef< void(TItemsType&, int32)> Function, |
Execute the specified function in nested parallel for loops, on all items for each active range (parallel range, parallel items). Set MinParallelSize to run sequential on the smaller ranges. | Chaos/PBDActiveView.h | |
void RangeFor
(
TFunctionRef< void(TItemsType&, int32, int32)> Function |
Execute the specified function in sequence for all active range. Callee responsible for inner loop. | Chaos/PBDActiveView.h | |
void RangeFor
(
TFunctionRef< void(TItemsType&, int32, int32)> Function, |
Execute the specified function in parallel for all active ranges. Callee responsible for inner loop. | Chaos/PBDActiveView.h | |
void Reset
(
int32 Offset |
Remove all ranges above the current given size. | Chaos/PBDActiveView.h | |
void SequentialFor
(
TFunctionRef< void(TItemsType&, int32)> Function |
Execute the specified function on all active items. | Chaos/PBDActiveView.h |