Brick Pattern Artifact in Volumetric Clouds

A repeating brick-like pattern is visible in volumetric clouds when they overlap very distant geometry (or at the transition between nearby and distant geometry). The artifact consists of 4-pixel-wide horizontal blocks with alternating row offsets.

From testing, this appears to occur only when using the bilateral upsampling path (r.VolumetricRenderTarget.UpsamplingMode=4). Other upsampling modes do not produce the artifact.

If possible, could you identify the shader or render pass responsible, or suggest a way to reduce the artifact?

A minimal reproduction project and screenshots are attached:

Steps to Reproduce

  1. Set “r.VolumetricRenderTarget.Mode=1”.
  2. Create or open a level containing:
  • SkyAtmosphere
  • VolumetricClouds (Tracing Max Distance 500, View Sample Count Scale 8)
  • Directional Light
  • A large sphere used as the planet surface
  1. Move the camera to the upper edge of the cloud layer and look toward the horizon.
  2. Observe the clouds where they overlap very distant geometry (or at the transition between nearby and very distant geometry).
  3. Reducing the screen percentage makes the artifact easier to see.
  4. Using cloud materials with stronger contrast and shadowing also makes the artifact more apparent.

I found a fix for this artifact.

In “VolumetricRenderTarget.usf”, the following condition is used to decide whether to use bilateral upsampling:

if (MaxDepth4Diff > ThresholdToBilinear)I added a check that compares the furthest cloud depth against the closest mesh depth:

const float FurthestCloud = max(max(VolumeFrontDepth0.x, VolumeFrontDepth1.x), max(VolumeFrontDepth2.x, VolumeFrontDepth3.x));
const float ClosestMesh = min(min(VolumeFrontDepth0.y, VolumeFrontDepth1.y), min(VolumeFrontDepth2.y, VolumeFrontDepth3.y));
const bool bMeshHiddenByCloud = ClosestMesh < FurthestCloud;
if (MaxDepth4Diff > ThresholdToBilinear && bMeshHiddenByCloud)

This skips the bilateral path when the sampled scene geometry is fully occluded by the clouds. In my testing, this removes the brick pattern without negatively affecting cloud-mesh edge blending.

Hi Alexander, I just had a chance to take a look at this issue, but I am unable to reproduce it using the steps you provided. To me, the distant geometry is not blocky but rather blurry, which makes sense given the bilinear sampling we do to reconstruct clouds. Are there any other steps I need to take to ensure that I get those artifacts?

Hi Tim,

I recreated the project from scratch using a vanilla UE 5.8.0 installation from the Epic Games Launcher, following the reproduction steps exactly.

To make the artifact even easier to spot, I increased Tracing Max Distance to 500 and View Sample Count Scale to 8 (these changes have been added to the reproduction steps) and used higher-contrast clouds with shadows. The artifact is especially obvious at the lower resolution, where the brick pattern clearly follows mesh edges that are completely hidden by the clouds. Several colleagues were able to reproduce it on their machines as well.

The relevant code section also appears to point to the issue. The bilateral upsampling path does not consider cloud depth, so mesh depth discontinuities can still trigger bilateral upsampling even when the clouds fully occlude those edges.

I’m happy with the workaround I found and don’t need any further help. If you’re able to reproduce the issue and find a cleaner fix, I’d be interested to see it. Otherwise, I’m perfectly fine with closing the ticket and leaving it on the public forum in case someone else runs into the same artifact.

See screenshots at default and 25% screen percentage with the affected regions marked in red:

Alternatively, open NewerWorld.umap in the attached project, and you should see the same scene as shown in the screenshots: https://www.dropbox.com/scl/fi/ql62tllm7k7qgekcb14b4/CloudBrickArtifacts.zip?rlkey=usagu87vifn39pdmbvqf5ib7w&amp;st=yuflejtw&amp;dl=0

CloudBrickArtifacts.zip(23.1 KB)

Hi Alexander,

Thanks for taking the time to provide us with a repro project and for adding extra details. I was able to verify that the brick artifacts shop up, and I have now created a Jira issue to track the issue, since the dev team is currently occupied with other tasks. They will try to review your proposed fix as soon as they can. Here is the public issue tracker for you: https://issues.unrealengine.com/issue/UE\-388559\. If you haven’t seen any traction on this within a reasonable time frame, please ping this ticket, and I can see about getting some traction for you. Please let me know if you have any further questions.

Hello,

Thanks for your help. That was happenign when using the mode=1 which is less tested on our side.

I ended up not taking you change because it was breaking upsampling over occluders close to the camera on groune (see JIRA images I posted). Instead this was only about tweaking the bilateral up sampling threshold factor to have it not trigger on large tangent depth difference in the distance. It is an empirical fudge factor but I could not find any better with depth differences also. Cloud issues like that becomes complex to fix because once you pull a fix for a case, other cases might break… Tricky business.

I hope the fix will be good for you. 57444437 on UE6 main. I can provide a link to public github if necessary when it becomes available there.

https://github.com/EpicGames/UnrealEngine/commit/0c551a3b64f97b7120b0b2a2a3bcab036011e64a is the public repository change.

Thanks!