Navigation
API > API/Plugins > API/Plugins/PCG > API/Plugins/PCG/Elements
Inheritance Hierarchy
- FPCGContext
- TPCGTimeSlicedContext
References
| Module | PCG |
| Header | /Engine/Plugins/PCG/Source/PCG/Public/Elements/PCGTimeSlicedElementBase.h |
| Include | #include "Elements/PCGTimeSlicedElementBase.h" |
Syntax
template<typename PerExecutionStateT, typename PerIterationStateT>
struct TPCGTimeSlicedContext : public FPCGContext
Remarks
A PCG context with helper utility to enable element authors to more easily implement timeslicing.
Functions
| Type | Name | Description | |
|---|---|---|---|
| bool | Returns true if both the execution state and iteration state were fully initialized and no problems arose that should abort the execution. | ||
| uint32 | Retrieves the number of times this context was executed | ||
| EPCGTimeSliceInitResult | Will return the result of the attempt to initialize the per execution state | ||
| EPCGTimeSliceInitResult | GetIterationStateResult
(
const int32 Index |
Will return the result of the attempt to initialize a specific iteration, by Index | |
| PerExecutionStateT & | |||
| const PerExecutionStateT & | |||
| TArray< PerIterationStateT > & | |||
| const TArray< PerIterationStateT > & | |||
| const TArray< EPCGTimeSliceInitResult > & | |||
| EPCGTimeSliceInitResult | InitializePerExecutionState
(
TFunctionRef< InitExecSignature > InitFunc |
Initializes per execution state data if required. | |
| const TArray< EPCGTimeSliceInitResult > & | InitializePerIterationStates
(
int32 NumIterations, |
Initializes per execution state data if required. | |
| void | SetTimeSliceIsEnabled
(
const bool bEnableTimeSlice |
||
| void | TrackObject
(
const UObject* Object |
Fire and forget function to make sure a UObject will not be GC'ed for the duration of the Context. |
Overridden from FPCGContext
| Type | Name | Description | |
|---|---|---|---|
| void | AddExtraStructReferencedObjects
(
FReferenceCollector& Collector |
||
| bool | Time slicing is not enabled by default. |
Typedefs
| Name | Description |
|---|---|
| InitExecSignature | |
| InitIterSignature |