In this lesson, you will learn how to automate graphics quality adjustment by leveraging the Scalability.ini system to assign distinct hardware tiers to different target devices.
Understanding the Scalability Hierarchy
Unreal Engine uses a layered configuration system to balance visual fidelity against performance. While general settings live in BaseScalability.ini, you can create platform-specific overrides in your project’s Config folder. By targeting devices based on their processing power, you ensure that a high-end PC doesn't look like a mobile device, and a mobile device doesn't attempt to render settings that would tank its frame rate.
Implementing Platform Overrides
The engine identifies your target hardware and applies groups based on categories like [ShaderPipelineCache], [ViewDistanceQuality], or [ShadowQuality]. You define these in files named PlatformScalability.ini (e.g., AndroidScalability.ini or IOSScalability.ini).
When you define a level (0 through 4, where 0 is Low and 4 is Epic), the engine automatically switches between these sets upon launch. Here is how you might structure a configuration for a lower-tier mobile device:
[ShadowQuality@0]
r.ShadowQuality=0
r.Shadow.CSM.MaxCascades=1
r.Shadow.MaxResolution=512
[ShadowQuality@3]
r.ShadowQuality=3
r.Shadow.CSM.MaxCascades=3
r.Shadow.MaxResolution=2048
By using the @ syntax followed by the scalability level index, you instruct the engine to swap these console variables dynamically. You can verify which settings are active by using the command r.AllowCommandPrefilter 1 and checking the Scalability console command output during runtime.
Automatic Tier Detection
The engine performs hardware benchmarking upon the first launch. The results of this benchmark determine which index—Low, Medium, High, or Epic—the device is assigned. This initial "autodetect" phase populates the UserScalability.ini file. By setting these specific overrides, you move beyond "one-size-fits-all" settings and ensure your project adheres to the strict performance budgets established in your previous profiling sessions. Always remember to test these tiers on actual hardware, as simulated environments often fail to replicate thermal throttling or specific driver behaviors present on real target devices.
Key Takeaway: Use platform-specific .ini files to map hardware tiers to custom CVar overrides, ensuring optimal performance across the diverse hardware spectrum without manual user intervention.