bSupportsLumenGI

bSupportsLumenGI

#Overview

name: bSupportsLumenGI

The value of this variable can be defined or overridden in .ini config files. 7 .ini config files referencing this setting variable.

It is referenced in 4 C++ source files.

#Summary

#Usage in the C++ source code

The purpose of bSupportsLumenGI is to indicate whether a specific shader platform supports Lumen Global Illumination (GI) in Unreal Engine 5. Lumen is an advanced dynamic global illumination and reflections system that provides high-quality, real-time lighting.

This setting variable is primarily used within the Rendering subsystem of Unreal Engine 5, specifically in the RHI (Rendering Hardware Interface) module. It helps determine the capabilities of different shader platforms and allows the engine to adjust its rendering pipeline accordingly.

The value of this variable is set during the initialization of the shader platform information. It’s parsed from a configuration section using the GET_SECTION_BOOL_HELPER macro in the ParseDataDrivenShaderInfo function.

bSupportsLumenGI interacts with other capability flags such as bSupportsNanite, bSupportsSSDIndirect, and bSupportsTemporalHistoryUpscale. These flags collectively define the feature set available for a particular shader platform.

Developers must be aware that this variable is platform-specific. Not all hardware or rendering APIs may support Lumen GI, so it’s crucial to check this flag before attempting to use Lumen-related features in your rendering code.

Best practices when using this variable include:

  1. Always check the value of bSupportsLumenGI before enabling Lumen GI features in your game or application.
  2. Provide fallback rendering methods for platforms where bSupportsLumenGI is false.
  3. Use the GetSupportsLumenGI function to query this capability rather than accessing the variable directly.
  4. Consider this flag in combination with other capability flags to determine the overall feature set available for your target platforms.
  5. Be prepared to adjust your rendering pipeline or quality settings based on whether Lumen GI is supported.

#Setting Variables

#References In INI files

Location: <Workspace>/Engine/Config/Android/DataDrivenPlatformInfo.ini:119, section: [ShaderPlatform VULKAN_SM5_ANDROID]

Location: <Workspace>/Engine/Config/Mac/DataDrivenPlatformInfo.ini:36, section: [ShaderPlatform METAL_SM5]

Location: <Workspace>/Engine/Config/Mac/DataDrivenPlatformInfo.ini:76, section: [ShaderPlatform METAL_SM6]

Location: <Workspace>/Engine/Config/VulkanPC/DataDrivenPlatformInfo.ini:68, section: [ShaderPlatform VULKAN_SM5]

Location: <Workspace>/Engine/Config/VulkanPC/DataDrivenPlatformInfo.ini:187, section: [ShaderPlatform VULKAN_SM6]

Location: <Workspace>/Engine/Config/Windows/DataDrivenPlatformInfo.ini:54, section: [ShaderPlatform PCD3D_SM5]

Location: <Workspace>/Engine/Config/Windows/DataDrivenPlatformInfo.ini:105, section: [ShaderPlatform PCD3D_SM6]

#References in C++ code

#Callsites

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

#Loc: <Workspace>/Engine/Source/Runtime/RHI/Private/DataDrivenShaderPlatformInfo.cpp:234

Scope (from outer to inner):

file
function     void FGenericDataDrivenShaderPlatformInfo::ParseDataDrivenShaderInfo

Source code excerpt:

	GET_SECTION_BOOL_HELPER(bRequiresVendorExtensionsForAtomics);
	GET_SECTION_BOOL_HELPER(bSupportsNanite);
	GET_SECTION_BOOL_HELPER(bSupportsLumenGI);
	GET_SECTION_BOOL_HELPER(bSupportsSSDIndirect);
	GET_SECTION_BOOL_HELPER(bSupportsTemporalHistoryUpscale);
	GET_SECTION_BOOL_HELPER(bSupportsRTIndexFromVS);
	GET_SECTION_BOOL_HELPER(bSupportsIntrinsicWaveOnce);
	GET_SECTION_BOOL_HELPER(bSupportsConservativeRasterization);
	GET_SECTION_SUPPORT_HELPER(bSupportsWaveOperations);

#Loc: <Workspace>/Engine/Source/Runtime/RHI/Private/DataDrivenShaderPlatformInfo.cpp:458

Scope (from outer to inner):

file
function     void FGenericDataDrivenShaderPlatformInfo::UpdatePreviewPlatforms

Source code excerpt:

				// Settings that should be kept true if the runtime also supports it.
				PREVIEW_DISABLE_IF_RUNTIME_UNSUPPORTED(bSupportsNanite);
				PREVIEW_DISABLE_IF_RUNTIME_UNSUPPORTED(bSupportsLumenGI);
				PREVIEW_DISABLE_IF_RUNTIME_UNSUPPORTED(bSupportsPrimitiveShaders);
				PREVIEW_DISABLE_IF_RUNTIME_UNSUPPORTED(bSupportsUInt64ImageAtomics);
				PREVIEW_DISABLE_IF_RUNTIME_UNSUPPORTED(bSupportsGen5TemporalAA);
				PREVIEW_DISABLE_IF_RUNTIME_UNSUPPORTED(bSupportsInlineRayTracing);
				PREVIEW_DISABLE_IF_RUNTIME_UNSUPPORTED(bSupportsRayTracingShaders);
				PREVIEW_DISABLE_IF_RUNTIME_UNSUPPORTED(bSupportsMeshShadersTier0);

#Loc: <Workspace>/Engine/Source/Runtime/RHI/Public/DataDrivenShaderPlatformInfo.h:58

Scope (from outer to inner):

file
class        class FGenericDataDrivenShaderPlatformInfo

Source code excerpt:

	uint32 bRequiresVendorExtensionsForAtomics : 1;
	uint32 bSupportsNanite : 1;
	uint32 bSupportsLumenGI : 1;
	uint32 bSupportsSSDIndirect : 1;
	uint32 bSupportsTemporalHistoryUpscale : 1;
	uint32 bSupportsRTIndexFromVS : 1;
	uint32 bSupportsWaveOperations : int32(ERHIFeatureSupport::NumBits);
	uint32 bSupportsWavePermute : 1;
	uint32 MinimumWaveSize : 8;

#Loc: <Workspace>/Engine/Source/Runtime/RHI/Public/DataDrivenShaderPlatformInfo.h:491

Scope (from outer to inner):

file
class        class FGenericDataDrivenShaderPlatformInfo
function     static const bool GetSupportsLumenGI

Source code excerpt:

	{
		check(IsValid(Platform));
		return Infos[Platform].bSupportsLumenGI;
	}

	static FORCEINLINE_DEBUGGABLE const bool GetSupportsSSDIndirect(const FStaticShaderPlatform Platform)
	{
		check(IsValid(Platform));
		return Infos[Platform].bSupportsSSDIndirect;