Lumen, Nanite & Post-Process
UE5's headline rendering features are Lumen (dynamic global illumination and reflections) and Nanite (virtualized geometry). Programmers need to know what they do, what they cost, and which settings belong to them, because "the game runs at 40 FPS on the target machine" is often a rendering-settings problem before it is a code problem.
Lumen
Lumen computes indirect lighting (light bouncing off surfaces) and reflections in real time. Move the sun, open a door into a dark room, and the bounce light updates without baking lightmaps.
| Setting | Where |
|---|---|
| Dynamic Global Illumination Method = Lumen | Project Settings → Engine → Rendering (default for new projects) |
| Reflection Method = Lumen | same page |
| Software vs Hardware Ray Tracing | Use Hardware Ray Tracing when available (needs a ray-tracing GPU and DX12/Vulkan); software Lumen traces signed distance fields and works on more hardware |
| per-volume quality and overrides | Post Process Volume → Global Illumination / Reflections |
Things that matter for gameplay programmers:
- Lumen's lighting reacts over several frames. A light switched on fades in rather than popping. That is fine for most games and looks wrong for, say, a muzzle flash, which should use a short-lived light with Indirect Lighting Intensity turned down, or an emissive material.
- Lumen is a big chunk of the GPU frame. Scalability settings (
sg.GlobalIlluminationQuality, Settings → Engine Scalability in the editor) are how low-end targets cope. On platforms where it costs too much, games fall back to baked lighting (Lightmass) or screen-space GI.
Nanite
Nanite streams and renders meshes at pixel-scale detail: a mesh with millions of triangles costs roughly what is needed for the pixels it covers. You enable it per static mesh (Enable Nanite Support in the mesh editor, or when importing). Benefits: almost no LOD authoring, huge instance counts, few draw-call worries.
Limitations to check against the docs for your engine version (they have shrunk with each 5.x release):
- Support for skinned (skeletal) meshes, translucent materials and some material features is limited or newer than the rest of Nanite.
- Masked materials and World Position Offset work, but cost more than opaque, static ones. Animated foliage with WPO is a common performance trap.
- Virtual Shadow Maps are the shadow technique designed to pair with Nanite.
Post-process volumes
A Post Process Volume changes the camera's image while the camera is inside it: exposure, bloom, colour grading, vignette, depth of field, motion blur, Lumen settings. Each volume has:
- Infinite Extent (Unbound): applies everywhere (your "global" settings);
- Priority: higher-priority volumes override lower ones;
- Blend Radius and Blend Weight: how strongly it applies near and inside its bounds.
Every setting has an override checkbox; only ticked settings apply. From C++ you can also push post-process settings onto a camera component (FollowCamera->PostProcessSettings, with PostProcessBlendWeight) for effects that follow the player, such as a low-health desaturation.
// Desaturate as health drops (on the player's camera, client side)
void AArenaCharacter::UpdateLowHealthEffect(float HealthFraction)
{
const float Strength = FMath::Clamp(1.f - HealthFraction / 0.3f, 0.f, 1.f); // starts below 30 % health
FPostProcessSettings& PP = FollowCamera->PostProcessSettings;
PP.bOverride_ColorSaturation = true;
PP.ColorSaturation = FVector4(1.f, 1.f, 1.f, 1.f - 0.8f * Strength);
PP.bOverride_VignetteIntensity = true;
PP.VignetteIntensity = 0.4f + 0.6f * Strength;
}A model of volume blending
Overlapping volumes are applied in order of priority, each blended in by its weight. This model computes the final exposure bias and saturation for a camera inside two volumes, which is roughly how the renderer combines them (lerping from the current value toward each volume's value).
#include <algorithm>
#include <iostream>
#include <iomanip>
#include <optional>
#include <string>
#include <vector>
struct Volume {
std::string Name; int Priority; double Weight; // weight already includes blend radius falloff
std::optional<double> ExposureBias, Saturation; // unset = override checkbox not ticked
};
int main() {
std::cout << std::fixed << std::setprecision(2);
std::vector<Volume> vols = {
{"PPV_Cave (inside, near edge)", 10, 0.5, 1.5, 0.6},
{"PPV_Global (unbound)", 0, 1.0, 0.0, 1.0},
{"PPV_PoisonGas", 20, 0.25, std::nullopt, 0.2},
};
std::sort(vols.begin(), vols.end(), [](const Volume& a, const Volume& b) { return a.Priority < b.Priority; });
double exposure = 0.0, saturation = 1.0; // engine defaults
for (const auto& v : vols) {
if (v.ExposureBias) exposure += (*v.ExposureBias - exposure) * v.Weight;
if (v.Saturation) saturation += (*v.Saturation - saturation) * v.Weight;
std::cout << "after " << std::setw(30) << std::left << v.Name << std::right
<< " exposure " << exposure << ", saturation " << saturation << "\n";
}
}after PPV_Global (unbound) exposure 0.00, saturation 1.00
after PPV_Cave (inside, near edge) exposure 0.75, saturation 0.80
after PPV_PoisonGas exposure 0.75, saturation 0.65
The poison gas volume never touched exposure because its exposure override wasn't ticked, and with weight 0.25 it only pulled saturation a quarter of the way toward 0.2.
Useful view modes and commands
| Tool | Shows |
|---|---|
| Lit / Unlit / Lighting Only / Detail Lighting view modes | separating material from lighting problems |
| Lumen → Overview / Surface Cache visualization | what Lumen sees; pink areas lack surface cache coverage |
| Nanite Visualization → Triangles / Clusters / Overdraw | Nanite detail and overdraw hot spots |
stat gpu |
GPU time per pass (Lumen, shadows, base pass, post) |
r.ScreenPercentage 50 |
quick test: is the frame GPU-bound by resolution? |
ProfileGPU (Ctrl+Shift+,) |
a one-frame GPU breakdown |
Test yourself
What does Lumen provide?
- Virtualized geometry
- Dynamic global illumination and reflections
- Physics simulation
- Audio occlusion
Two post-process volumes overlap the camera. Which settings win?
- The larger volume's
- Higher priority volumes are applied later and override, scaled by their blend weight
- The first one placed in the level
- They cancel out
A post-process setting in a volume has no effect. What should you check first?
- That Nanite is enabled
- That its override checkbox is ticked
- That the volume simulates physics
- The tick group