r.Shaders.ForceDXC

r.Shaders.ForceDXC

#Overview

name: r.Shaders.ForceDXC

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

It is referenced in 2 C++ source files.

#Summary

#References in C++ code

#Callsites

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

#Loc: <Workspace>/Engine/Source/Runtime/RenderCore/Private/Shader.cpp:107

Scope: file

Source code excerpt:


static TAutoConsoleVariable<int32> CVarShadersForceDXC(
	TEXT("r.Shaders.ForceDXC"),
	1,
	TEXT("Forces DirectX Shader Compiler (DXC) to be used for all shaders instead of HLSLcc if supported.\n")
	TEXT(" 1: Force new compiler for all shaders (default)\n")
	TEXT(" 0: Disable"),
	ECVF_ReadOnly);

#Loc: <Workspace>/Engine/Source/Runtime/RenderCore/Private/Shader.cpp:1440

Scope (from outer to inner):

file
function     bool IsDxcEnabledForPlatform

Source code excerpt:

	if (FDataDrivenShaderPlatformInfo::GetSupportsDxc(Platform))
	{
		static FShaderPlatformCachedIniValue<bool> ShaderForceDXC(TEXT("r.Shaders.ForceDXC"));
		if (bHlslVersion2021 || (ShaderForceDXC.Get(Platform) != 0))
		{
			return true;
		}
	}
	// Check backend specific console variables next