au.BypassAudioPlugins
au.BypassAudioPlugins
#Overview
name: au.BypassAudioPlugins
The value of this variable can be defined or overridden in .ini config files. 2
.ini config files referencing this setting variable.
This variable is created as a Console Variable (cvar).
- type:
Var
- help:
Bypasses any audio plugin processing.\n0: Not Disabled, 1: Disabled
It is referenced in 3
C++ source files.
#Summary
#Usage in the C++ source code
The purpose of au.BypassAudioPlugins is to control whether audio plugin processing is bypassed in the Unreal Engine audio system. This setting variable is used in the audio mixer subsystem of Unreal Engine.
The Audio Mixer module relies on this setting variable, specifically within the FMixerSourceManager class. It is used to determine whether to skip audio plugin processing for individual audio sources.
The value of this variable is set through a console variable (CVar) system. It is initialized to 0 and can be changed at runtime using console commands or through code.
The au.BypassAudioPlugins variable interacts directly with the BypassAudioPluginsCvar variable. They share the same value, with BypassAudioPluginsCvar being the actual integer storage for the setting.
Developers must be aware that when this variable is set to 1, all audio plugin processing will be bypassed. This can significantly affect the audio output of the game or application, as any effects or processing applied by audio plugins will not be applied.
Best practices when using this variable include:
- Use it primarily for debugging or performance testing purposes.
- Be cautious when enabling it in production builds, as it can drastically change the audio experience.
- Consider providing a user-facing option to toggle this setting if it’s intended to be used as a performance optimization.
Regarding the associated variable BypassAudioPluginsCvar:
The purpose of BypassAudioPluginsCvar is to serve as the actual storage for the au.BypassAudioPlugins setting. It is an integer variable that directly controls whether audio plugins are bypassed.
This variable is used within the Audio Mixer module, specifically in the FMixerSourceManager::ComputePluginAudio function.
The value of BypassAudioPluginsCvar is set through the CVar system, initialized to 0, and can be modified at runtime.
BypassAudioPluginsCvar interacts directly with au.BypassAudioPlugins, effectively being the backend storage for that console variable.
Developers should be aware that this variable is checked directly in audio processing code, and its value determines whether plugin processing occurs.
Best practices for BypassAudioPluginsCvar include:
- Avoid modifying this variable directly; instead, use the au.BypassAudioPlugins console variable.
- When reading this value in performance-critical code, consider caching it to avoid frequent checks of the console variable system.
- Be aware that changes to this variable will immediately affect audio processing, so it should be used cautiously in live environments.
#Setting Variables
#References In INI files
Location: <Workspace>/Projects/Lyra/Config/Android/AndroidEngine.ini:14, section: [ConsoleVariables]
- INI Section:
ConsoleVariables
- Raw value:
1
- Is Array:
False
Location: <Workspace>/Projects/Lyra/Config/IOS/IOSEngine.ini:9, section: [ConsoleVariables]
- INI Section:
ConsoleVariables
- Raw value:
1
- Is Array:
False
#References in C++ code
#Callsites
This variable is referenced in the following C++ source code:
#Loc: <Workspace>/Engine/Source/Runtime/AudioMixer/Private/AudioMixerSourceManager.cpp:79
Scope: file
Source code excerpt:
static int32 BypassAudioPluginsCvar = 0;
FAutoConsoleVariableRef CVarBypassAudioPlugins(
TEXT("au.BypassAudioPlugins"),
BypassAudioPluginsCvar,
TEXT("Bypasses any audio plugin processing.\n")
TEXT("0: Not Disabled, 1: Disabled"),
ECVF_Default);
static int32 FlushCommandBufferOnTimeoutCvar = 0;
#Associated Variable and Callsites
This variable is associated with another variable named BypassAudioPluginsCvar
. They share the same value. See the following C++ source code.
#Loc: <Workspace>/Engine/Source/Runtime/AudioMixer/Private/AudioMixerSourceManager.cpp:77
Scope: file
Source code excerpt:
ECVF_Default);
static int32 BypassAudioPluginsCvar = 0;
FAutoConsoleVariableRef CVarBypassAudioPlugins(
TEXT("au.BypassAudioPlugins"),
BypassAudioPluginsCvar,
TEXT("Bypasses any audio plugin processing.\n")
TEXT("0: Not Disabled, 1: Disabled"),
ECVF_Default);
static int32 FlushCommandBufferOnTimeoutCvar = 0;
FAutoConsoleVariableRef CVarFlushCommandBufferOnTimeout(
#Loc: <Workspace>/Engine/Source/Runtime/AudioMixer/Private/AudioMixerSourceManager.cpp:2451
Scope (from outer to inner):
file
namespace Audio
function void FMixerSourceManager::ComputePluginAudio
Source code excerpt:
void FMixerSourceManager::ComputePluginAudio(FSourceInfo& SourceInfo, FMixerSourceSubmixOutputBuffer& InSourceSubmixOutputBuffer, int32 SourceId, int32 NumSamples)
{
if (BypassAudioPluginsCvar)
{
// If we're bypassing audio plugins, our pre- and post-effect channels are the same as the input channels
SourceInfo.NumPostEffectChannels = SourceInfo.NumInputChannels;
// Set the ptr to use for post-effect buffers:
InSourceSubmixOutputBuffer.SetPostAttenuationSourceBuffer(&SourceInfo.SourceBuffer);