Files
UnrealEngineUWP/Engine/Source/Runtime/MovieScene/Private/MovieSceneSpawnableAnnotation.cpp
Andrew Rodham f44701da43 Sequencer: Added the ability to run asynchronous predictions for animated component transforms and future/past times
- Predictions do not understand changes of attachment that might occur between the current time and the predicted time
  - Separated the functions and data relating to managing interrogation channels and indices out into a separate class called FInterrogationChannels
  - The predictions import interrogation entities into the main ECS and will get processed along with all the other evaluations
  - Spawnable annotations are now available in-game (not just in-editor)

#rb Mike.Zyracki, Max.Chen
#jira none
#preflight 606757c002d50100019f0d4f

[CL 15930213 by Andrew Rodham in ue5-main branch]
2021-04-06 10:28:26 -04:00

32 lines
1.0 KiB
C++

// Copyright Epic Games, Inc. All Rights Reserved.
#include "MovieSceneSpawnableAnnotation.h"
#include "UObject/UObjectAnnotation.h"
static FUObjectAnnotationSparse<FMovieSceneSpawnableAnnotation,true> SpawnedObjectAnnotation;
void FMovieSceneSpawnableAnnotation::Add(UObject* SpawnedObject, const FGuid& ObjectBindingID, FMovieSceneSequenceID SequenceID, UMovieSceneSequence* InOriginatingSequence)
{
if (SpawnedObject)
{
FMovieSceneSpawnableAnnotation Annotation;
Annotation.ObjectBindingID = ObjectBindingID;
Annotation.SequenceID = SequenceID;
Annotation.OriginatingSequence = InOriginatingSequence;
SpawnedObjectAnnotation.AddAnnotation(SpawnedObject, MoveTemp(Annotation));
}
}
TOptional<FMovieSceneSpawnableAnnotation> FMovieSceneSpawnableAnnotation::Find(UObject* SpawnedObject)
{
const FMovieSceneSpawnableAnnotation& Annotation = SpawnedObjectAnnotation.GetAnnotation(SpawnedObject);
TOptional<FMovieSceneSpawnableAnnotation> ReturnValue;
if (!Annotation.IsDefault())
{
ReturnValue = Annotation;
}
return ReturnValue;
}