r.CameraShakeDebug.InfoRecordLimit

r.CameraShakeDebug.InfoRecordLimit

#Overview

name: r.CameraShakeDebug.InfoRecordLimit

This variable is created as a Console Variable (cvar).

It is referenced in 4 C++ source files.

#Summary

#Usage in the C++ source code

The purpose of r.CameraShakeDebug.InfoRecordLimit is to control the duration of recorded camera shake debug information in Unreal Engine 5. It sets the number of seconds of debug data to keep for camera shake debugging purposes.

Regarding the associated variable GCameraShakeDebugInfoRecordLimitCVar:

The purpose of GCameraShakeDebugInfoRecordLimitCVar is to provide a runtime-accessible way to modify the r.CameraShakeDebug.InfoRecordLimit value.

#References in C++ code

#Callsites

This variable is referenced in the following C++ source code:

#Loc: <Workspace>/Engine/Source/Runtime/Engine/Private/Camera/CameraModifier_CameraShake.cpp:38

Scope: file

Source code excerpt:

	TEXT("Draws larger graphs for camera shake debug info"));
TAutoConsoleVariable<float> GCameraShakeDebugInfoRecordLimitCVar(
	TEXT("r.CameraShakeDebug.InfoRecordLimit"),
	2,
	TEXT("How many seconds to keep while recording camera shake debug info (defaults to 2 seconds)"));

UCameraModifier_CameraShake::UCameraModifier_CameraShake(const FObjectInitializer& ObjectInitializer)
	: Super(ObjectInitializer)
#if UE_ENABLE_DEBUG_DRAWING

#Associated Variable and Callsites

This variable is associated with another variable named GCameraShakeDebugInfoRecordLimitCVar. They share the same value. See the following C++ source code.

#Loc: <Workspace>/Engine/Source/Runtime/Engine/Private/Camera/CameraModifier_CameraShake.cpp:37

Scope: file

Source code excerpt:

	false,
	TEXT("Draws larger graphs for camera shake debug info"));
TAutoConsoleVariable<float> GCameraShakeDebugInfoRecordLimitCVar(
	TEXT("r.CameraShakeDebug.InfoRecordLimit"),
	2,
	TEXT("How many seconds to keep while recording camera shake debug info (defaults to 2 seconds)"));

UCameraModifier_CameraShake::UCameraModifier_CameraShake(const FObjectInitializer& ObjectInitializer)
	: Super(ObjectInitializer)

#Loc: <Workspace>/Engine/Source/Runtime/Engine/Private/Camera/CameraModifier_CameraShake.cpp:75

Scope (from outer to inner):

file
function     bool UCameraModifier_CameraShake::ModifyCamera

Source code excerpt:


#if UE_ENABLE_DEBUG_DRAWING
	const float DebugDataLimit = GCameraShakeDebugInfoRecordLimitCVar.GetValueOnGameThread();
#endif

	// Update and apply active shakes
	if( ActiveShakes.Num() > 0 )
	{
		for (FActiveCameraShakeInfo& ShakeInfo : ActiveShakes)

#Loc: <Workspace>/Engine/Source/Runtime/Engine/Private/Camera/CameraModifier_CameraShake.cpp:605

Scope (from outer to inner):

file
function     void UCameraModifier_CameraShake::DisplayDebugGraphs

Source code excerpt:

	const float GraphLeftXPos = GraphRightXPos - GraphWidth;

	const float DebugDataLimit = GCameraShakeDebugInfoRecordLimitCVar.GetValueOnGameThread();
	const float PixelsPerSecond = GraphWidth / (DebugDataLimit > 0 ? DebugDataLimit : 3.f);

	for (int i = 0; i < DebugShakes.Num(); i++)
	{
		const FCameraShakeDebugData& DebugShake = DebugShakes[i];
		if (DebugShake.DataPoints.IsEmpty())