bSupportsArrayTextureCompression
bSupportsArrayTextureCompression
#Overview
name: bSupportsArrayTextureCompression
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 bSupportsArrayTextureCompression is to indicate whether a specific shader platform supports array texture compression. This is a capability related to the rendering system in Unreal Engine 5.
This setting variable is primarily used within the RHI (Rendering Hardware Interface) module of Unreal Engine. It’s part of the FGenericDataDrivenShaderPlatformInfo class, which is responsible for managing shader platform-specific information.
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.
bSupportsArrayTextureCompression interacts with other shader platform capability flags, such as bSupportsDebugViewShaders, bSupportsMobileMultiView, and bSupportsDistanceFields. 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 differ depending on the target hardware and graphics API. It’s crucial to check this flag before attempting to use array texture compression features in shaders or rendering code.
Best practices when using this variable include:
- Always check its value before relying on array texture compression features.
- Use the provided static function GetSupportsArrayTextureCompression() to query this capability for a specific shader platform.
- Consider providing fallback mechanisms for platforms that don’t support array texture compression.
- Keep in mind that this is part of a data-driven system, so its value might change based on the platform configuration without requiring code changes.
#Setting Variables
#References In INI files
Location: <Workspace>/Engine/Config/VulkanPC/DataDrivenPlatformInfo.ini:30, section: [ShaderPlatform VULKAN_SM5]
- INI Section:
ShaderPlatform VULKAN_SM5
- Raw value:
false
- Is Array:
False
Location: <Workspace>/Engine/Config/VulkanPC/DataDrivenPlatformInfo.ini:157, section: [ShaderPlatform VULKAN_SM6]
- INI Section:
ShaderPlatform VULKAN_SM6
- Raw value:
false
- Is Array:
False
#References in C++ code
#Callsites
This variable is referenced in the following C++ source code:
#Loc: <Workspace>/Engine/Source/Runtime/RHI/Private/DataDrivenShaderPlatformInfo.cpp:205
Scope (from outer to inner):
file
function void FGenericDataDrivenShaderPlatformInfo::ParseDataDrivenShaderInfo
Source code excerpt:
GET_SECTION_BOOL_HELPER(bSupportsDebugViewShaders);
GET_SECTION_BOOL_HELPER(bSupportsMobileMultiView);
GET_SECTION_BOOL_HELPER(bSupportsArrayTextureCompression);
GET_SECTION_BOOL_HELPER(bSupportsDistanceFields);
GET_SECTION_BOOL_HELPER(bSupportsDiaphragmDOF);
GET_SECTION_BOOL_HELPER(bSupportsRGBColorBuffer);
GET_SECTION_BOOL_HELPER(bSupportsCapsuleShadows);
GET_SECTION_BOOL_HELPER(bSupportsPercentageCloserShadows);
GET_SECTION_BOOL_HELPER(bSupportsIndexBufferUAVs);
#Loc: <Workspace>/Engine/Source/Runtime/RHI/Public/DataDrivenShaderPlatformInfo.h:31
Scope (from outer to inner):
file
class class FGenericDataDrivenShaderPlatformInfo
Source code excerpt:
uint32 bSupportsDebugViewShaders : 1;
uint32 bSupportsMobileMultiView : 1;
uint32 bSupportsArrayTextureCompression : 1;
uint32 bSupportsDistanceFields : 1; // used for DFShadows and DFAO - since they had the same checks
uint32 bSupportsDiaphragmDOF : 1;
uint32 bSupportsRGBColorBuffer : 1;
uint32 bSupportsCapsuleShadows : 1;
uint32 bSupportsPercentageCloserShadows : 1;
uint32 bSupportsIndexBufferUAVs : 1;
#Loc: <Workspace>/Engine/Source/Runtime/RHI/Public/DataDrivenShaderPlatformInfo.h:245
Scope (from outer to inner):
file
class class FGenericDataDrivenShaderPlatformInfo
function static const bool GetSupportsArrayTextureCompression
Source code excerpt:
{
check(IsValid(Platform));
return Infos[Platform].bSupportsArrayTextureCompression;
}
static FORCEINLINE_DEBUGGABLE const bool GetSupportsDistanceFields(const FStaticShaderPlatform Platform)
{
check(IsValid(Platform));
return Infos[Platform].bSupportsDistanceFields;