bSupportsRTIndexFromVS

bSupportsRTIndexFromVS

#Overview

name: bSupportsRTIndexFromVS

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

It is referenced in 3 C++ source files.

#Summary

#Usage in the C++ source code

The purpose of bSupportsRTIndexFromVS is to indicate whether a specific shader platform supports the use of ray tracing (RT) index from vertex shaders (VS). This setting is related to the rendering system, specifically for ray tracing capabilities.

This setting variable is primarily used within the RHI (Rendering Hardware Interface) module of Unreal Engine. It is part of the FGenericDataDrivenShaderPlatformInfo class, which provides information about various shader platform capabilities.

The value of this variable is set during the parsing of data-driven shader information. This occurs in the ParseDataDrivenShaderInfo function within the DataDrivenShaderPlatformInfo.cpp file.

bSupportsRTIndexFromVS interacts with other shader platform capability flags, such as bSupportsSSDIndirect, bSupportsTemporalHistoryUpscale, and bSupportsWaveOperations. These flags collectively define the features supported by a particular shader platform.

Developers must be aware that this variable is platform-specific. Its value may vary depending on the target hardware and graphics API. It’s crucial to check this flag before attempting to use ray tracing index from vertex shaders in your rendering pipeline.

Best practices when using this variable include:

  1. Always check its value using the GetSupportsRTIndexFromVS function before implementing related features.
  2. Consider providing fallback rendering paths for platforms that don’t support this feature.
  3. Use this information to optimize shader code and rendering techniques based on the platform’s capabilities.
  4. Keep in mind that this is part of a larger set of shader platform capabilities, so it should be considered in conjunction with other related flags when making rendering decisions.

#Setting Variables

#References In INI files

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

Location: <Workspace>/Engine/Config/VulkanPC/DataDrivenPlatformInfo.ini:196, section: [ShaderPlatform VULKAN_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:237

Scope (from outer to inner):

file
function     void FGenericDataDrivenShaderPlatformInfo::ParseDataDrivenShaderInfo

Source code excerpt:

	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);
	GET_SECTION_BOOL_HELPER(bSupportsWavePermute);
	GET_SECTION_INT_HELPER(MinimumWaveSize);
	GET_SECTION_INT_HELPER(MaximumWaveSize);

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

Scope (from outer to inner):

file
class        class FGenericDataDrivenShaderPlatformInfo

Source code excerpt:

	uint32 bSupportsSSDIndirect : 1;
	uint32 bSupportsTemporalHistoryUpscale : 1;
	uint32 bSupportsRTIndexFromVS : 1;
	uint32 bSupportsWaveOperations : int32(ERHIFeatureSupport::NumBits);
	uint32 bSupportsWavePermute : 1;
	uint32 MinimumWaveSize : 8;
	uint32 MaximumWaveSize : 8;
	uint32 bSupportsIntrinsicWaveOnce : 1;
	uint32 bSupportsConservativeRasterization : 1;

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

Scope (from outer to inner):

file
class        class FGenericDataDrivenShaderPlatformInfo
function     static const bool GetSupportsRTIndexFromVS

Source code excerpt:

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

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