engine
 
载入中...
搜索中...
未找到
Public 成员函数 | Protected 属性 | 所有成员列表
UE::MovieScene::FSystemInterrogator类 参考

A class specialized for interrogating Sequencer entity data without applying any state to objects. 更多...

#include <MovieSceneInterrogationLinker.h>

+ 类 UE::MovieScene::FSystemInterrogator 继承关系图:

Public 成员函数

int32 AddInterrogation (const FInterrogationParams &Params)
 Add a new time to interrogate this linker at, in the time-base of the imported tracks. 更多...
 
FInterrogationChannel AllocateChannel (FInterrogationChannel ParentChannel)
 Allocate a new interrogation channel that can be used to uniquely identify groups of tracks that animate the same property or output. 更多...
 
FInterrogationChannel AllocateChannel (UObject *Object, FInterrogationChannel ParentChannel)
 Allocate a new interrogation channel that relates to a specific object
 
FInterrogationChannel AllocateUnboundChannel (FInterrogationChannel ParentChannel, const FTransform &CurrentValueLocalSpace)
 Allocate a new channel for a set of transform tracks that isn't bound to any particular object (but can still exist within a hierarchy) 更多...
 
FMovieSceneEntityID FindEntityFromOwner (FInterrogationKey InterrogationKey, UObject *Owner, uint32 EntityID) const
 Find an entity given the entity's owner. 更多...
 
UObject * FindObjectFromChannel (FInterrogationChannel Channel) const
 Find the object that is allocated within a given channel
 
TArrayView< const FInterrogationParams > GetInterrogations () const
 Retrieve the current interrogations
 
UMovieSceneEntitySystemLinker * GetLinker () const
 Access the underlying linker used for interrogation.
 
int32 GetNumChannels () const
 Retrieve the number of channels allocated
 
FInterrogationChannel ImportLocalTransforms (USceneComponent *SceneComponent, IMovieScenePlayer *InPlayer, FMovieSceneSequenceID SequenceID)
 Import any transform tracks that relate to the specified scene component, or it's AActor if it is the root 更多...
 
void ImportTrack (UMovieSceneTrack *Track, const FGuid &ObjectBindingID, FInterrogationChannel InChannel)
 Import a track into this linker. 更多...
 
void ImportTrack (UMovieSceneTrack *Track, FInterrogationChannel InChannel)
 Import a track into this linker. 更多...
 
void ImportTracks (TArrayView< UMovieSceneTrack *const > Tracks, const FGuid &ObjectBindingID, FInterrogationChannel InChannel)
 Import multiple tracks into this linker. 更多...
 
FInterrogationChannel ImportTransformHierarchy (USceneComponent *SceneComponent, IMovieScenePlayer *InPlayer, FMovieSceneSequenceID SequenceID)
 Import the entire transform hierarchy for the specified component, including all attached parents and tracks relating to them. 更多...
 
void QueryLocalSpaceTransforms (const TBitArray<> &ChannelsToQuery, TSparseArray< TArray< FIntermediate3DTransform > > &OutTransformsByChannel)
 Query a specific set of channels for their local space transforms as defined by set bits within ChannelsToQuery 更多...
 
void QueryLocalSpaceTransforms (FInterrogationChannel InChannel, TArray< FIntermediate3DTransform > &OutTransforms)
 Query local space transforms 更多...
 
void QueryLocalSpaceTransforms (TSparseArray< TArray< FIntermediate3DTransform > > &OutTransformsByChannel)
 Query all local space transforms, even including channels that do not have any variable track data 更多...
 
void QueryLocalSpaceTransforms (USceneComponent *SceneComponent, TArray< FIntermediate3DTransform > &OutTransforms)
 Query local space transforms 更多...
 
void QueryWorldSpaceTransforms (const TBitArray<> &ChannelsToQuery, TSparseArray< TArray< FTransform > > &OutTransformsByChannel)
 Query a specific set of channels for their world space transforms as defined by set bits within ChannelsToQuery 更多...
 
void QueryWorldSpaceTransforms (FInterrogationChannel InChannel, TArray< FTransform > &OutTransforms)
 Query world space transforms for a channel 更多...
 
void QueryWorldSpaceTransforms (TSparseArray< TArray< FTransform > > &OutTransformsByChannel)
 Query all world space transforms, even including channels that do not have any variable track data 更多...
 
void QueryWorldSpaceTransforms (USceneComponent *SceneComponent, TArray< FTransform > &OutTransforms)
 Query world space transforms for a component 更多...
 
void Reset ()
 Reset this linker back to its original state
 
void TrackImportedEntities (bool bInTrackImportedEntities)
 Indicate that consumers of this class require a reverse-lookup table for imported entities to be maintained such that the various FindEntity functions can be called. 更多...
 
void Update ()
 Flush this interrogator by running all the systems relevant to the current data and populating the interrogation outputs.
 

Protected 属性

FMovieSceneEvaluationFieldEntitySet EntitiesScratch
 Scratch buffer used for generating entities for interrogation times
 
FMovieSceneEntityComponentField EntityComponentField
 Entity component field containing all the entity owners relevant at specific times
 
TUniquePtr< FSystemInterrogatorEntityTracker > EntityTracker
 Tracker class that is used for keeping track of imported entities
 
TBitArray ImportedChannelBits
 BitArray containing set bits for any channel that has data associated with it. 更多...
 
TArray< FInterrogationParams > Interrogations
 An array of interrogation times
 
UMovieSceneEntitySystemLinker * Linker
 The linker we own
 
TMap< UObject *, FInterrogationChannel > ObjectToChannel
 Map from an object to its interrogation channel
 
TSortedMap< FInterrogationChannel, FInterrogationChannelInfo > SparseChannelInfo
 Array of information pertaining to a given channel
 

详细描述

A class specialized for interrogating Sequencer entity data without applying any state to objects.

Currently only tracks within the same time-base are supported. Will only link systems that are not excluded from EEntitySystemContext::Interrogation. Multiple different outputs can be interrogated simultaneously by Importing tracks onto separate channels allocated through AllocateChannel.

Systems may implement their own interrogation logic that can be run after updates to allow third-party interrogation behavior for specific channels or time.

Example usage: Interrogator.ImportTrack(MyTrack, FInterrogationChannel::Default());

for (int32 FrameNumber = 0; FrameNumber < 100; ++FrameNumber) Interrogator.InterrogateTime(FrameNumber);

Interrogator.Update();

UMyTrackSystem* MySystem = Interrogator.GetLinker()->FindSystem<UMyTrackSystem>(); if (MySystem) { TArray<DataType> OutData; MySystem->Interrogate(FInterogationKey::Default(), OutData); }

成员函数说明

◆ AddInterrogation()

int32 UE::MovieScene::FSystemInterrogator::AddInterrogation ( const FInterrogationParams &  Params)

Add a new time to interrogate this linker at, in the time-base of the imported tracks.

参数
ParamsThe desired time to interrogate at
返回
A unique index identifier for the specified time, or INDEX_NONE if the maximum number have been reached

◆ AllocateChannel()

FInterrogationChannel UE::MovieScene::FSystemInterrogator::AllocateChannel ( FInterrogationChannel  ParentChannel)

Allocate a new interrogation channel that can be used to uniquely identify groups of tracks that animate the same property or output.

参数
ParentChannelThe channel that should be considered this channel's parent, or FInterrogationChannel::Invalid if there is none
返回
A new interrogation channel

◆ AllocateUnboundChannel()

FInterrogationChannel UE::MovieScene::FSystemInterrogator::AllocateUnboundChannel ( FInterrogationChannel  ParentChannel,
const FTransform &  CurrentValueLocalSpace 
)

Allocate a new channel for a set of transform tracks that isn't bound to any particular object (but can still exist within a hierarchy)

参数
ParentChannelThe channel that should be considered this channel's parent, or FInterrogationChannel::Invalid if there is none
CurrentValueA value to use if this channel has now animated data after the interrogation
返回
A new interrogation channel that can be passed to ImportUnboundTrack

◆ FindEntityFromOwner()

FMovieSceneEntityID UE::MovieScene::FSystemInterrogator::FindEntityFromOwner ( FInterrogationKey  InterrogationKey,
UObject *  Owner,
uint32  EntityID 
) const

Find an entity given the entity's owner.

注解
: Must call TrackImportedEntities(true) prior to calling ImportTrack for this function to return the correct entity

◆ ImportLocalTransforms()

FInterrogationChannel UE::MovieScene::FSystemInterrogator::ImportLocalTransforms ( USceneComponent *  SceneComponent,
IMovieScenePlayer *  InPlayer,
FMovieSceneSequenceID  SequenceID 
)

Import any transform tracks that relate to the specified scene component, or it's AActor if it is the root

参数
SceneComponentThe scene component to import. A new channel will be allocated for this if one does not already exist.
InPlayerThe player interface to use for looking up object binding IDs pertaining to scene components or actors
SequenceIDThe current sequence ID for the interrogation
返回
The channel that was either pre-existing or allocated for SceneComponent

◆ ImportTrack() [1/2]

void UE::MovieScene::FSystemInterrogator::ImportTrack ( UMovieSceneTrack *  Track,
const FGuid &  ObjectBindingID,
FInterrogationChannel  InChannel 
)

Import a track into this linker.

This will add the track to the linker's evaluation field and cause entities to be created for it at each interrogation channel (if it is relevant at such times) Must be called before InterrogateTime() and Update().

参数
TrackThe track to import
ObjectBindingIDThe binding ID for the object binding that this track resides within
InChannelThe channel to import this track onto. FInterrogationChannel::Default() can be used if this interrogator is only being used for a single output.

◆ ImportTrack() [2/2]

void UE::MovieScene::FSystemInterrogator::ImportTrack ( UMovieSceneTrack *  Track,
FInterrogationChannel  InChannel 
)

Import a track into this linker.

This will add the track to the linker's evaluation field and cause entities to be created for it at each interrogation channel (if it is relevant at such times) Must be called before InterrogateTime() and Update().

参数
TrackThe track to import
InChannelThe channel to import this track onto. FInterrogationChannel::Default() can be used if this interrogator is only being used for a single output.

◆ ImportTracks()

void UE::MovieScene::FSystemInterrogator::ImportTracks ( TArrayView< UMovieSceneTrack *const >  Tracks,
const FGuid &  ObjectBindingID,
FInterrogationChannel  InChannel 
)
inline

Import multiple tracks into this linker.

See ImporTrack above.

◆ ImportTransformHierarchy()

FInterrogationChannel UE::MovieScene::FSystemInterrogator::ImportTransformHierarchy ( USceneComponent *  SceneComponent,
IMovieScenePlayer *  InPlayer,
FMovieSceneSequenceID  SequenceID 
)

Import the entire transform hierarchy for the specified component, including all attached parents and tracks relating to them.

参数
SceneComponentThe scene component to import. A new channel will be allocated for this if one does not already exist.
InPlayerThe player interface to use for looking up object binding IDs pertaining to scene components or actors
SequenceIDThe current sequence ID for the interrogation
返回
The channel that was either pre-existing or allocated for SceneComponent

◆ QueryLocalSpaceTransforms() [1/4]

void UE::MovieScene::FSystemInterrogator::QueryLocalSpaceTransforms ( const TBitArray<> &  ChannelsToQuery,
TSparseArray< TArray< FIntermediate3DTransform > > &  OutTransformsByChannel 
)

Query a specific set of channels for their local space transforms as defined by set bits within ChannelsToQuery

参数
ChannelsToQueryBit array containing set bits for each channel to query
OutTransformsByChannelSparse array to receive transforms allocated by their Channel index

◆ QueryLocalSpaceTransforms() [2/4]

void UE::MovieScene::FSystemInterrogator::QueryLocalSpaceTransforms ( FInterrogationChannel  InChannel,
TArray< FIntermediate3DTransform > &  OutTransforms 
)

Query local space transforms

参数
InChannelThe channel to query
OutTransformsArray to output transforms into, one per Interrogation

◆ QueryLocalSpaceTransforms() [3/4]

void UE::MovieScene::FSystemInterrogator::QueryLocalSpaceTransforms ( TSparseArray< TArray< FIntermediate3DTransform > > &  OutTransformsByChannel)

Query all local space transforms, even including channels that do not have any variable track data

参数
OutTransformsByChannelSparse array to receive transforms allocated by their Channel index

◆ QueryLocalSpaceTransforms() [4/4]

void UE::MovieScene::FSystemInterrogator::QueryLocalSpaceTransforms ( USceneComponent *  SceneComponent,
TArray< FIntermediate3DTransform > &  OutTransforms 
)

Query local space transforms

参数
SceneComponentThe scene component to query
OutTransformsArray to output transforms into, one per Interrogation

◆ QueryWorldSpaceTransforms() [1/4]

void UE::MovieScene::FSystemInterrogator::QueryWorldSpaceTransforms ( const TBitArray<> &  ChannelsToQuery,
TSparseArray< TArray< FTransform > > &  OutTransformsByChannel 
)

Query a specific set of channels for their world space transforms as defined by set bits within ChannelsToQuery

参数
ChannelsToQueryBit array containing set bits for each channel to query
OutTransformsByChannelSparse array to receive transforms allocated by their Channel index

◆ QueryWorldSpaceTransforms() [2/4]

void UE::MovieScene::FSystemInterrogator::QueryWorldSpaceTransforms ( FInterrogationChannel  InChannel,
TArray< FTransform > &  OutTransforms 
)

Query world space transforms for a channel

参数
InChannelThe channel to query
OutTransformsArray to output transforms into, one per Interrogation

◆ QueryWorldSpaceTransforms() [3/4]

void UE::MovieScene::FSystemInterrogator::QueryWorldSpaceTransforms ( TSparseArray< TArray< FTransform > > &  OutTransformsByChannel)

Query all world space transforms, even including channels that do not have any variable track data

参数
OutTransformsByChannelSparse array to receive transforms allocated by their Channel index

◆ QueryWorldSpaceTransforms() [4/4]

void UE::MovieScene::FSystemInterrogator::QueryWorldSpaceTransforms ( USceneComponent *  SceneComponent,
TArray< FTransform > &  OutTransforms 
)

Query world space transforms for a component

参数
SceneComponentThe scene component to query
OutTransformsArray to output transforms into, one per Interrogation

◆ TrackImportedEntities()

void UE::MovieScene::FSystemInterrogator::TrackImportedEntities ( bool  bInTrackImportedEntities)

Indicate that consumers of this class require a reverse-lookup table for imported entities to be maintained such that the various FindEntity functions can be called.

(Not enabled by default due to performance cost with high interrogation counts)

类成员变量说明

◆ ImportedChannelBits

TBitArray UE::MovieScene::FSystemInterrogator::ImportedChannelBits
protected

BitArray containing set bits for any channel that has data associated with it.

The number of bits (0 or 1) in this array defines how many channels are allocated


该类的文档由以下文件生成: