Sequencer.TickIntervalGroupingResolutionMs
Sequencer.TickIntervalGroupingResolutionMs
#Overview
name: Sequencer.TickIntervalGroupingResolutionMs
This variable is created as a Console Variable (cvar).
- type:
Var
- help:
Defines the maximum resolution for actor tick interval groupings. Bigger numbers will group more actors together when they have custom tick intervals, but will lead to less accurate intervals.\n
It is referenced in 5
C++ source files.
#Summary
#Usage in the C++ source code
The purpose of Sequencer.TickIntervalGroupingResolutionMs is to define the maximum resolution for actor tick interval groupings in Unreal Engine’s Sequencer system. This setting variable is primarily used in the movie scene and sequencer subsystems of Unreal Engine 5.
The Unreal Engine subsystem that relies on this setting variable is the MovieScene module, which is a core part of the Sequencer system. This can be seen from the file paths and namespaces in the provided code references.
The value of this variable is set using an FAutoConsoleVariableRef, which means it can be adjusted at runtime through the console or configuration files. It’s initialized with a default value of 50 milliseconds.
This variable interacts with other components of the MovieScene system, particularly in the context of tick intervals for sequence playback. It’s used in conjunction with FMovieSceneSequenceTickInterval and UMovieSceneSequenceTickManager to determine how actors and sequences are grouped for ticking purposes.
Developers must be aware that this variable affects the accuracy of tick intervals for sequences and actors. A larger value will group more actors together, potentially improving performance but at the cost of less precise timing.
Best practices when using this variable include:
- Consider the trade-off between performance and precision when adjusting this value.
- Be aware that changing this value may affect the behavior of existing sequences, particularly those that rely on precise timing.
- Use this in conjunction with other Sequencer settings to fine-tune performance and accuracy for your specific use case.
- When implementing custom tick logic, consider using the RoundTickIntervalMs() function to ensure consistency with this global setting.
- Be cautious when setting this value too low, as it may lead to performance issues due to excessive granularity in tick groupings.
#References in C++ code
#Callsites
This variable is referenced in the following C++ source code:
#Loc: <Workspace>/Engine/Source/Runtime/MovieScene/Private/MovieSceneSequenceTickInterval.cpp:12
Scope (from outer to inner):
file
namespace UE::MovieScene
Source code excerpt:
int32 GMovieSceneTickIntervalResolutionMs = 50;
static FAutoConsoleVariableRef CVarMovieSceneTickIntervalResolutionMs(
TEXT("Sequencer.TickIntervalGroupingResolutionMs"),
GMovieSceneTickIntervalResolutionMs,
TEXT("Defines the maximum resolution for actor tick interval groupings. Bigger numbers will group more actors together when they have custom tick intervals, but will lead to less accurate intervals.\n"),
ECVF_Default
);
} // namespace UE::MovieScene
#Loc: <Workspace>/Engine/Source/Runtime/MovieScene/Public/MovieSceneSequenceTickInterval.h:45
Scope: file
Source code excerpt:
bool bTickWhenPaused = false;
/** When true, allow the sequence to be grouped with other sequences based on Sequencer.TickIntervalGroupingResolutionMs. Otherwise the interval will be used precisely. */
UPROPERTY(EditAnywhere, Category="Playback")
bool bAllowRounding = true;
public:
/**
* Round this interval to the nearest Sequencer.TickIntervalGroupingResolutionMs milliseconds
*/
MOVIESCENE_API int32 RoundTickIntervalMs() const;
/**
* Resolve this tick interval within the specified context object (usually a movie scene player)
* inheriting properties from the first valid parent if possible
*/
static MOVIESCENE_API FMovieSceneSequenceTickInterval GetInheritedInterval(UObject* ContextObject);
#Loc: <Workspace>/Engine/Source/Runtime/MovieScene/Public/MovieSceneSequenceTickManager.h:20
Scope: file
Source code excerpt:
*
* Ticking clients are registered based on their desired tick interval, and grouped together with other
* clients that tick with the same interval (based on Sequencer.TickIntervalGroupingResolutionMs).
*
* Sequencer data is shared between all instances within the same group, allowing them to blend together.
* Clients ticking at different intervals do not support blending with each other.
*/
UCLASS(MinimalAPI)
class UMovieSceneSequenceTickManager : public UObject
{
public:
GENERATED_BODY()
MOVIESCENE_API UMovieSceneSequenceTickManager(const FObjectInitializer& Init);
/**
* Retrieve the tick manager for the specified playback context
*/
#Loc: <Workspace>/Engine/Source/Runtime/MovieScene/Public/MovieSceneSequenceTickManager.h:40
Scope (from outer to inner):
file
class class UMovieSceneSequenceTickManager : public UObject
Source code excerpt:
/**
* Register a new client to receive a tick at the specified tick interval.
* This client will be grouped with all other clients that tick within Sequencer.TickIntervalGroupingResolutionMs of the specified interval.
*
* @param TickInterval The interval at which to tick the client.
* @param InTickInterface The client that will receieve a tick
*/
MOVIESCENE_API void RegisterTickClient(const FMovieSceneSequenceTickInterval& TickInterval, TScriptInterface<IMovieSceneSequenceTickManagerClient> InTickInterface);
/**
* Unregister a previously registered client. The client must have been registered or an assertion will fail.
*
* @param InTickInterface The client to unregister
*/
MOVIESCENE_API void UnregisterTickClient(TScriptInterface<IMovieSceneSequenceTickManagerClient> InTickInterface);
#Loc: <Workspace>/Engine/Source/Runtime/MovieScene/Public/MovieSceneSequenceTickManager.h:128
Scope (from outer to inner):
file
class class UMovieSceneSequenceTickManager : public UObject
Source code excerpt:
TSharedPtr<FMovieSceneEntitySystemRunner> Runner;
/** The tick interval of this group, rounded to the nearest Sequencer.TickIntervalGroupingResolutionMs */
int32 RoundedTickIntervalMs = 0;
/** The frame budget for all linkers within this linker group in milliseconds */
float FrameBudgetMs = 0.f;
/** The value of UWorld::GetUnpausedTimeSeconds last time this group was evaluated */