Navigation
API > API/Runtime > API/Runtime/MovieScene
Pre-animated state extension that houses all cached values for objects animated by a specific UMovieSceneEntitySystemLinker- The presence of this extension denotes that pre-animated state should be stored in one form or another. If the extension is not present, this implies that there are no IMovieScenePlayers that need global Restore State, and no tracks set to 'Restore State'. FPreAnimatedStateExtension::NumRequestsForGlobalState defines whether this extension needs to cache any and all changes or not
- Each specific 'type' of pre-animated state is defined by a unique StorageID (TPreAnimatedStorageID), registered through RegisterStorage
- Pre-animated state is grouped into buckets in order to preserve significant ordering constraints (for instance, each object must restore state in the reverse order it was cached)
- Groups are managed by registered IPreAnimatedStateGroupManager instances. The main implementation is FPreAnimatedObjectGroupManager, which maintains an object to group mapping
| Name | FPreAnimatedStateExtension |
| Type | struct |
| Header File | /Engine/Source/Runtime/MovieScene/Public/Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h |
| Include Path | #include "Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h" |
Syntax
struct FPreAnimatedStateExtension
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FPreAnimatedStateExtension() |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h |
Destructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
~FPreAnimatedStateExtension() |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h |
Structs
Typedefs
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| FContributionRemover | TFunctionRef< void(IPreAnimatedStorage &, FPreAnimatedStorageIndex)> | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h |
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| NumRequestsForGlobalState | uint32 | The number of requests that have been made to capture global state - only one should exist per playing sequence | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h |
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| bEntriesInvalidated | bool | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
| EntityCaptureSource | TUniquePtr< FPreAnimatedEntityCaptureSource > | Meta-data pertaining to the entity IDs from which animated state originates | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
| EvaluationHookCaptureSource | TUniquePtr< UE::MovieScene::FPreAnimatedEvaluationHookCaptureSources > | Meta-data ledger for any pre-animated state that originates from evaluation hooks | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
| GroupManagers | TSortedMap< FPreAnimatedStorageID, TWeakPtr< IPreAnimatedStateGroupManager > > | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
| GroupMetaData | TSparseArray< FPreAnimatedGroupMetaData > | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
| Linker | UMovieSceneEntitySystemLinker * | Linker is always valid because this extension is owned by the Linker | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
| StorageImplementations | TSortedMap< FPreAnimatedStorageID, TSharedPtr< IPreAnimatedStorage > > | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
| TemplateCaptureSource | TUniquePtr< UE::MovieScene::FPreAnimatedTemplateCaptureSources > | Meta-data ledger for any pre-animated state that originates from track templates | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
| TrackInstanceCaptureSource | TUniquePtr< FPreAnimatedTrackInstanceCaptureSources > | Meta-data pertaining to pre-animated state originating from track instances | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
| TrackInstanceInputCaptureSource | TUniquePtr< FPreAnimatedTrackInstanceInputCaptureSources > | Meta-data pertaining to pre-animated state originating from track instances from a specific input | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
| UngroupedMetaData | TMap< FPreAnimatedStateCachedValueHandle, FAggregatePreAnimatedStateMetaData > | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
| WeakExternalCaptureSources | TArray< TWeakPtr< IPreAnimatedCaptureSource > > | Weakly held meta data provided by FMovieScenePreAnimatedState for various other origins | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
| WeakGenericObjectStorage | TWeakPtr< FAnimTypePreAnimatedStateObjectStorage > | Pointers to the storage for state bound to objects, organized by FMovieSceneAnimTypeID | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
| WeakGenericRootStorage | TWeakPtr< FAnimTypePreAnimatedStateRootStorage > | Pointers to the storage for state created from root tracks, or otherwise not bound to objects | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void AddMetaData
(
const FPreAnimatedStateMetaData& MetaData |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
void AddSourceMetaData
(
const FPreAnimatedStateEntry& Entry |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
void AddStorage
(
TPreAnimatedStorageID< StorageType > InStorageID, |
Add a specific storage type to this extension | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
void AddWeakCaptureSource
(
TWeakPtr< IPreAnimatedCaptureSource > InWeakMetaData |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
FPreAnimatedStorageGroupHandle AllocateGroup
(
TSharedPtr< IPreAnimatedStateGroupManager > GroupManager |
Called by group managers to allocate a new group | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
bool AreEntriesInvalidated() |
Check whether any previously cached entries may have become invalid due to a recent call to RestoreGlobalState If this function returns true, clients should consider re-saving pre-animated state even if it already did so | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
bool ContainsAnyStateForInstanceHandle
(
FRootInstanceHandle RootInstanceHandle |
Search for any captured state that originated from the specified root instance handle WARNING: This is a linear search across all state, and so is potentially very slow | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
void DiscardGlobalState
(
const FRestoreStateParams& Params |
Discards any state for any persistent tokens captured during the course of evaluation without restoring it. | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
void DiscardStaleObjectState () |
Called during Garbage Collection to clean up preanimated state on invalid bound objects. | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
void DiscardStateForGroup
(
FPreAnimatedStorageGroupHandle GroupHandle |
Discard any and all cached values for the specified group without restoring them. | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
void DiscardStateForStorage
(
FPreAnimatedStorageID StorageID, |
Discard the specified cached value and any and all capture source tracking related to it. | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
void DiscardTransientState () |
Discard any transient state and all meta-data for any currently animating objects, whilst preserving the cached values internally. | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
void EnsureMetaData
(
const FPreAnimatedStateEntry& Entry |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
TSharedPtr< GroupManagerType > FindGroupManager () |
Find a group manager by its type. | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
TSharedPtr< StorageType > FindStorage
(
TPreAnimatedStorageID< StorageType > InStorageID |
Find a specific storage type by its ID. | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
void FreeGroup
(
FPreAnimatedStorageGroupHandle Index |
Called by group managers to free an existing group | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
FPreAnimatedEntityCaptureSource * GetEntityMetaData() |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
FPreAnimatedEvaluationHookCaptureSources * GetEvaluationHookMetaData() |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
FPreAnimatedEntityCaptureSource * GetOrCreateEntityMetaData() |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
FPreAnimatedEvaluationHookCaptureSources * GetOrCreateEvaluationHookMetaData() |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
TSharedPtr< GroupManagerType > GetOrCreateGroupManager () |
Get or create a group manager by its type. | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
TSharedPtr< StorageType > GetOrCreateStorage
(
TPreAnimatedStorageID< StorageType > InStorageID |
Get a specific type of storage, creating it if it does not already exist | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
TSharedPtr< StorageType > GetOrCreateStorage () |
Get a specific type of storage, creating it if it does not already exist | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
FPreAnimatedTemplateCaptureSources * GetOrCreateTemplateMetaData() |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
FPreAnimatedTrackInstanceInputCaptureSources * GetOrCreateTrackInstanceInputMetaData() |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
FPreAnimatedTrackInstanceCaptureSources * GetOrCreateTrackInstanceMetaData() |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
TSharedPtr< IPreAnimatedStorage > GetStorageChecked
(
FPreAnimatedStorageID InStorageID |
Get a genericly typed storage entry by its erased ID, failing an assertion if it does not exist | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
EPreAnimatedStorageRequirement GetStorageRequirement
(
const FPreAnimatedStateEntry& Entry |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
FPreAnimatedTemplateCaptureSources * GetTemplateMetaData() |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
FPreAnimatedTrackInstanceInputCaptureSources * GetTrackInstanceInputMetaData() |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
FPreAnimatedTrackInstanceCaptureSources * GetTrackInstanceMetaData() |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
bool HasActiveCaptureSource() |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
void Initialize
(
UMovieSceneEntitySystemLinker* InLinker |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
bool IsCapturingGlobalState() |
Check if this extension has any current requests to capture global (persistent) state entries | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
bool MetaDataExists
(
const FPreAnimatedStateEntry& Entry |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
| Called to handle replaced objects | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
void RemoveMetaData
(
const FPreAnimatedStateMetaData& MetaData |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
void RemoveWeakCaptureSource
(
TWeakPtr< IPreAnimatedCaptureSource > InWeakMetaData |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
void ReplaceObjectForGroup
(
FPreAnimatedStorageGroupHandle GroupHandle, |
Called during blueprint re-instancing to replace the object bound to a specific group handle with another. | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
void ResetEntryInvalidation() |
Resets the entry invalidation flag | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
void RestoreGlobalState
(
const FRestoreStateParams& Params |
Restore any state for any persistent tokens captured during the course of evaluation | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
void RestoreStateForGroup
(
FPreAnimatedStorageGroupHandle GroupHandle, |
Restore any state cached for the specified group | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
void SavePreAnimatedState
(
FMovieSceneAnimTypeID InTokenType, |
These methods for globally saving pre-animated state shouldn't be used directly: | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
void SavePreAnimatedState
(
UObject& InObject, |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
void SavePreAnimatedStateDirectly
(
FMovieSceneAnimTypeID InTokenType, |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
void SavePreAnimatedStateDirectly
(
UObject& InObject, |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | ||
void UpdateMetaData
(
const FPreAnimatedStateMetaData& MetaData |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h |
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static TPreAnimatedStorageID< StorageType > RegisterStorage() |
Called from TAutoRegisterPreAnimatedStorageID to register a new application-wide storage type | Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h | |
static FPreAnimatedStorageID RegisterStorageInternal() |
Evaluation/PreAnimatedState/MovieScenePreAnimatedStateExtension.h |