Optimizing Fog in HDRP- Game Dev Series 163
Objective: make the fog in HDRP looks more high quality.
Fog can be a key effect to improve your game scene, especially creating some scene with theme like cyberpunk, medieval, or horror.
In this article, I would import the fog effect created by GameDevHQ and try to optimize it in HDRP.
Shader of fog
After imported the fog effect, you would see our old friend- pink blocks.
This time, we will not changing the shader into HDRP, but Sprite> Default instead. You would immediately see the difference.
Then we can adjust the color and opacity of this material to make it looks naturally.
Optimizing with light effect
When using fog under lighting, it would easily looks fake when the fog effect somehow more like a transparency object.
Here are some ways to make it looks better.
First, let’s add a light into game scene as demonstration.
Under Global Volume, add a Fog override.
Then check the following option, especially Fog Attenuation Distance and Volumetric Fog.
You should see when enable Volumetric Fog, the light effect blend in fog immediately.
To get a more fabulous result, lower the amount of Fog Attenuation Distance then check the result.