FarLODDistanceTheshold
FarLODDistanceTheshold
#Overview
name: FarLODDistanceTheshold
The value of this variable can be defined or overridden in .ini config files. 1
.ini config file referencing this setting variable.
It is referenced in 3
C++ source files.
#Summary
#Usage in the C++ source code
The purpose of FarLODDistanceTheshold is to set a threshold for detecting particle systems with potentially excessive LOD (Level of Detail) distances in Unreal Engine 5. It is used in the particle system auditing process to identify and report particle systems that may have performance or visual quality issues due to their LOD configuration.
This setting variable is primarily used by the ParticleSystemAuditCommandlet, which is part of the UnrealEd module in the Editor subsystem of Unreal Engine 5. The commandlet is designed to analyze and report on various aspects of particle systems in a project.
The value of FarLODDistanceTheshold is set in the constructor of the UParticleSystemAuditCommandlet class, with a default value of 3000.0 units. However, it is also marked as a config property, which means it can be overridden in configuration files.
FarLODDistanceTheshold interacts with the LODDistances array of particle systems. The commandlet checks each LOD distance against this threshold to determine if at least one LOD is within an acceptable range.
Developers should be aware that this variable is used for auditing purposes and does not directly affect the runtime behavior of particle systems. It’s a tool for identifying potential issues in particle system configurations.
Best practices when using this variable include:
- Adjusting the threshold value based on the scale and requirements of your project.
- Using the ParticleSystemAuditCommandlet regularly during development to catch potential performance issues early.
- Reviewing the commandlet’s output and addressing any particle systems that are flagged for having all LOD distances above this threshold.
- Considering the performance implications of particle systems with high LOD distances, especially for lower-end hardware or mobile devices.
#Setting Variables
#References In INI files
Location: <Workspace>/Engine/Config/BaseEditor.ini:323, section: [/Script/Engine.ParticleSystemAuditCommandlet]
- INI Section:
/Script/Engine.ParticleSystemAuditCommandlet
- Raw value:
3000
- Is Array:
False
#References in C++ code
#Callsites
This variable is referenced in the following C++ source code:
#Loc: <Workspace>/Engine/Source/Editor/UnrealEd/Classes/Commandlets/ParticleSystemAuditCommandlet.h:43
Scope (from outer to inner):
file
class class UParticleSystemAuditCommandlet : public UCommandlet
Source code excerpt:
/** If a particle system has an LODDistance larger than this value, it will be reported */
UPROPERTY(config)
float FarLODDistanceTheshold;
/** The folder in which the commandlet's output files will be stored */
FString AuditOutputFolder;
/** Only assets in this collection will be considered. If this is left blank, no assets will be filtered by collection */
FString FilterCollection;
#Loc: <Workspace>/Engine/Source/Editor/UnrealEd/Private/Commandlets/ParticleSystemAuditCommandlet.cpp:29
Scope (from outer to inner):
file
function UParticleSystemAuditCommandlet::UParticleSystemAuditCommandlet
Source code excerpt:
{
HighSpawnRateOrBurstThreshold = 35.f;
FarLODDistanceTheshold = 3000.f;
}
int32 UParticleSystemAuditCommandlet::Main(const FString& Params)
{
if (!FParse::Value(*Params, TEXT("AuditOutputFolder="), AuditOutputFolder))
{
#Loc: <Workspace>/Engine/Source/Editor/UnrealEd/Private/Commandlets/ParticleSystemAuditCommandlet.cpp:307
Scope (from outer to inner):
file
function bool UParticleSystemAuditCommandlet::ProcessParticleSystems
Source code excerpt:
for (float LODDistance : PSys->LODDistances)
{
if (LODDistance <= FarLODDistanceTheshold)
{
bAtLeastOneLODUnderFarDistanceThresholdOrEmpty = true;
break;
}
}