au.Debug.Display.Y
au.Debug.Display.Y
#Overview
name: au.Debug.Display.Y
This variable is created as a Console Variable (cvar).
- type:
Var
- help:
X position on screen of debug statistics. \nDefault: -1 (Disabled, uses default debug position)
It is referenced in 3
C++ source files.
#Summary
#Usage in the C++ source code
The purpose of au.Debug.Display.Y is to control the vertical position (Y-coordinate) of audio debug statistics displayed on the screen in Unreal Engine 5. This setting variable is part of the audio debugging system.
The Unreal Engine subsystem that relies on this setting variable is the Audio system, specifically the audio debugging functionality. This can be inferred from the file name “AudioDebug.cpp” and the namespace “Audio” where the variable is used.
The value of this variable is set through the console variable system in Unreal Engine. It’s initialized with a default value of -1 and can be changed at runtime using console commands.
The au.Debug.Display.Y variable interacts with another variable named SoundDebugDisplayCornerYCVar. They share the same value, with SoundDebugDisplayCornerYCVar being the actual storage for the setting.
Developers must be aware that:
- The default value of -1 means the debug display will use the default debug position.
- Setting a value >= 0 will override the default position and place the debug display at that specific Y-coordinate on the screen.
Best practices when using this variable include:
- Use it in conjunction with au.Debug.Display.X to precisely position the audio debug display.
- Be cautious when setting very large values, as they might push the debug display off-screen.
- Reset to -1 when you want to return to the default positioning.
Regarding the associated variable SoundDebugDisplayCornerYCVar:
The purpose of SoundDebugDisplayCornerYCVar is to store the actual value of the Y-coordinate for the audio debug display. It’s the internal representation of the au.Debug.Display.Y console variable.
This variable is used directly in the audio debugging system, specifically in the FAudioDebugger::DrawDebugStatsInternal function. It determines the vertical starting position for rendering various audio debug statistics.
The value of SoundDebugDisplayCornerYCVar is set through the console variable system, mirroring the value of au.Debug.Display.Y.
It interacts with SoundDebugDisplayCornerXCVar to determine the overall position of the debug display. It’s also used in conjunction with other variables to render different types of audio debug information (mixes, modulators, reverb, sounds, and cues).
Developers should be aware that modifying SoundDebugDisplayCornerYCVar directly is not recommended. Instead, they should use the au.Debug.Display.Y console variable to change its value.
Best practices include using this variable only for reading within the audio debugging system and relying on the console variable system for any modifications to its value.
#References in C++ code
#Callsites
This variable is referenced in the following C++ source code:
#Loc: <Workspace>/Engine/Source/Runtime/Engine/Private/AudioDebug.cpp:150
Scope: file
Source code excerpt:
static int32 SoundDebugDisplayCornerYCVar = -1;
FAutoConsoleVariableRef CVarSoundDebugDisplayCornerY(
TEXT("au.Debug.Display.Y"),
SoundDebugDisplayCornerYCVar,
TEXT("X position on screen of debug statistics. \n")
TEXT("Default: -1 (Disabled, uses default debug position)"),
ECVF_Default);
namespace Audio
#Associated Variable and Callsites
This variable is associated with another variable named SoundDebugDisplayCornerYCVar
. They share the same value. See the following C++ source code.
#Loc: <Workspace>/Engine/Source/Runtime/Engine/Private/AudioDebug.cpp:148
Scope: file
Source code excerpt:
ECVF_Default);
static int32 SoundDebugDisplayCornerYCVar = -1;
FAutoConsoleVariableRef CVarSoundDebugDisplayCornerY(
TEXT("au.Debug.Display.Y"),
SoundDebugDisplayCornerYCVar,
TEXT("X position on screen of debug statistics. \n")
TEXT("Default: -1 (Disabled, uses default debug position)"),
ECVF_Default);
namespace Audio
{
#Loc: <Workspace>/Engine/Source/Runtime/Engine/Private/AudioDebug.cpp:1349
Scope (from outer to inner):
file
namespace Audio
function int32 FAudioDebugger::DrawDebugStatsInternal
Source code excerpt:
int32 X = SoundDebugDisplayCornerXCVar;
int32 Y = SoundDebugDisplayCornerYCVar < 0 ? InY : SoundDebugDisplayCornerYCVar;
Y = RenderStatMixes(&World, &Viewport, Canvas, X, Y);
Y = RenderStatModulators(&World, &Viewport, Canvas, X, Y, nullptr, nullptr);
Y = RenderStatReverb(&World, &Viewport, Canvas, X, Y);
Y = RenderStatSounds(&World, &Viewport, Canvas, X, Y);
Y = RenderStatCues(&World, &Viewport, Canvas, X, Y);