![]() |
UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
|
#include <MovieScenePlaybackManager.h>
Public Types | |
| using | FContexts = TArray< FMovieSceneContext, TInlineAllocator< 2 > > |
A utility class that can manage a playing sequence's status and current time, while also handling looping, ping-ponging, and other playback modes.
All public APIs take and return times in display rate (e.g. 30fps frames). Internally, everything is treated as ticks (e.g. 60000 ticks/sec).
| FMovieScenePlaybackManager::FMovieScenePlaybackManager | ( | ) |
Creates a default playback manager.
| FMovieScenePlaybackManager::FMovieScenePlaybackManager | ( | UMovieSceneSequence * | InSequence | ) |
Creates a playback manager immediately initialized with the given sequence.
| void FMovieScenePlaybackManager::ClearPlaybackEndTime | ( | ) |
Removes any previously specified time to stop at.
| FFrameTime FMovieScenePlaybackManager::GetCurrentTime | ( | ) | const |
Gets the current playback position, in display rate.
|
inline |
Gets the display rate of the sequence.
|
inline |
Gets whether looping dissection is enabled (see EMovieSceneLoopDissection).
| FFrameTime FMovieScenePlaybackManager::GetEffectiveEndTime | ( | ) | const |
Get the effective playback end time, in display rate, taking into account any end offset.
| TRange< FFrameTime > FMovieScenePlaybackManager::GetEffectivePlaybackRange | ( | ) | const |
Get the effective playback range, in display rate, taking into account start/end offsets.
| FFrameTime FMovieScenePlaybackManager::GetEffectiveStartTime | ( | ) | const |
Get the effective playback start time, in display rate, taking into account any start offset.
| FFrameTime FMovieScenePlaybackManager::GetEndOffset | ( | ) | const |
Gets the end offset of the playback in display rate.
|
inline |
Returns the current number of loops completed so far.
|
inline |
Gets the number of loops to play before ending playback.
| TOptional< FFrameTime > FMovieScenePlaybackManager::GetPlaybackEndTime | ( | ) | const |
Gets the time to stop at on the last loop of playback.
|
inline |
Get the playback status.
|
inline |
Gets the time transform to apply to the current time when updating. Only used if ShouldTransformPlaybackTime is true.
|
inline |
Gets the playback direction.
|
inline |
Gets the play-rate.
| FFrameTime FMovieScenePlaybackManager::GetStartOffset | ( | ) | const |
Gets the start offset of the playback in display rate.
|
inline |
Gets the tick resolution of the sequence.
| void FMovieScenePlaybackManager::Initialize | ( | UMovieSceneSequence * | InSequence | ) |
Initializes the playback manager for the given sequence. This resets all playback settings (play rate, start/end offsets, etc.) to their default values.
|
inline |
Gets whether the sequence should ping-pong between forwards and backwards playback.
|
inline |
Gets whether the sequence should be playing in reverse.
|
inline |
Gets whether the sequence should be playing forwards.
|
inline |
Reset the number of completed loops to zero.
| void FMovieScenePlaybackManager::ReversePlayDirection | ( | ) |
Reverses the playback direction.
| void FMovieScenePlaybackManager::SetCurrentTime | ( | const FFrameTime & | InFrameTime | ) |
Sets the current playback position, in display rate.
| void FMovieScenePlaybackManager::SetCurrentTimeOffset | ( | const FFrameTime & | InFrameTimeOffset | ) |
Sets the current playback position, in display rate, as an offset from the effective start time.
|
inline |
Sets whether looping dissection is enabled (see EMovieSceneLoopDissection).
| void FMovieScenePlaybackManager::SetEndOffset | ( | const FFrameTime & | InEndOffset | ) |
Sets the end offset of the playback in display rate.
| void FMovieScenePlaybackManager::SetEndOffsetAsTime | ( | const FFrameTime & | InEndTime | ) |
Sets the end time of the playback in display rate.
Sets the number of loops to play before ending playback.
Sets whether the sequence should ping-pong between forwards and backwards playback. Note that a "loop" is still one play through of the sequence, whether forwards or backwards, so odd numbers of loops corresponds to a "ping" without a "pong".
| void FMovieScenePlaybackManager::SetPlaybackEndTime | ( | const FFrameTime & | InEndTime | ) |
Sets the time to stop at on the last loop of playback.
|
inline |
Set the playback status.
|
inline |
|
inline |
Sets the playback direction.
| void FMovieScenePlaybackManager::SetStartOffset | ( | const FFrameTime & | InStartOffset | ) |
Sets the start offset of the playback in display rate.
Sets whether the playback time transform should be applied to time updates.
|
inline |
Gets whether the playback time transform should be applied to time updates.
Updates the playback state and returns the evaluation contexts to use for evaluating the sequence. More than one context may be returned if the sequence loops once or more, and "looping dissection" is enabled.
| InDeltaSeconds | The delta-time to update with |
| OutContexts | One or more update contexts to evaluate the sequence |
| FMovieSceneContext FMovieScenePlaybackManager::UpdateAtCurrentTime | ( | ) | const |
Returns an evaluation context for the current time, i.e. using a zero-width evaluation range set around the current time.
| void FMovieScenePlaybackManager::UpdateTo | ( | const FFrameTime | NextTime, |
| FContexts & | OutContexts | ||
| ) |
As per the other Update method, but takes a time (in display rate) instead of seconds.
| FMovieSceneContext FMovieScenePlaybackManager::UpdateToNextTick | ( | ) |
Updates the playback state over only the current tick. This generally does not advance the current time by one tick, but by one tick bound. That is, if the current time is tick 0, this will evaluate the [0, 0] range, advancing to an exclusive lower bound, so that the next update will be (0, XYZ).