r.CameraShakeDebug

r.CameraShakeDebug

#Overview

name: r.CameraShakeDebug

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

It is referenced in 3 C++ source files.

#Summary

#Usage in the C++ source code

The purpose of r.CameraShakeDebug is to enable extra debug information for camera shakes in Unreal Engine 5. This setting is primarily used for debugging and visualizing camera shake effects during development.

Regarding the associated variable GShowCameraShakeDebugCVar:

The purpose of GShowCameraShakeDebugCVar is to serve as the actual console variable that controls the r.CameraShakeDebug setting.

#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:22

Scope: file

Source code excerpt:


TAutoConsoleVariable<bool> GShowCameraShakeDebugCVar(
	TEXT("r.CameraShakeDebug"),
	false,
	TEXT("Show extra debug info for camera shakes (requires `showdebug CAMERA`)"));
TAutoConsoleVariable<bool> GShowCameraShakeDebugLocationCVar(
	TEXT("r.CameraShakeDebug.Location"),
	true,
	TEXT("Whether to show camera shakes' location modifications (defaults to true)"));

#Associated Variable and Callsites

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

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

Scope: file

Source code excerpt:

DECLARE_CYCLE_STAT(TEXT("AddCameraShake"), STAT_AddCameraShake, STATGROUP_Game);

TAutoConsoleVariable<bool> GShowCameraShakeDebugCVar(
	TEXT("r.CameraShakeDebug"),
	false,
	TEXT("Show extra debug info for camera shakes (requires `showdebug CAMERA`)"));
TAutoConsoleVariable<bool> GShowCameraShakeDebugLocationCVar(
	TEXT("r.CameraShakeDebug.Location"),
	true,

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

Scope (from outer to inner):

file
function     void UCameraModifier_CameraShake::DisplayDebugGraphs

Source code excerpt:


	// See if we should be recording and display shake data.
	const bool bShowLocationDebug = GShowCameraShakeDebugCVar.GetValueOnGameThread() && 
		GShowCameraShakeDebugLocationCVar.GetValueOnGameThread();
	const bool bShowRotationDebug = GShowCameraShakeDebugCVar.GetValueOnGameThread() && 
		GShowCameraShakeDebugRotationCVar.GetValueOnGameThread();
	bRecordDebugData = bShowLocationDebug || bShowRotationDebug;
	
	if (!bRecordDebugData)
	{
		return;