WoLD Archives Search About Contact

World of Level Design

Tutorials to Becoming the Best Level Designer and Game Environment Artist (since 2008)

UE5: FIX Single Layer Water Material with Directional Light Blocky Hard Shadow Problem and Solution

Category: UE5
April 23, 2025

When using a Single Layer Water Shader, a common issue you'll experience is with Directional Light casting harsh shadows from nearby geometry. These shadows appear incorrectly on the water plane, creating an unnatural effect.

In this post, I'll show you how to fix this. We'll explore the setup, analyze the issue and provide step-by-step solutions, including ray-traced shadows, alternative lighting methods, and configuration tweaks.

Video Tutorial

Understanding the Problem

When a Directional Light casts shadows onto a water plane that uses Single Layer Water Material - blocky, hard shadows appear on the water surface, which shouldn't happen.

Water is semi-transparent, so harsh shadows from geometry should not be visible on its surface.

To diagnose the problem, let's review the setup:

  • Water Plane Material: The Material uses the Single Layer Water shading model. It works correctly in interior scenes without a Directional Light, so the material itself is not the issue.
  • Water Plane Properties: Shadow casting is disabled for the plane, ruling out the plane as the cause, since shadows would appear behind, not on top.
  • Directional Light: Shadow casting is enabled, as it should be for realistic lighting. Disabling it would disrupt the scene's lighting, so this isn't a viable fix.

The issue comes from the Directional Light. It doesn't seem to handle shadows correctly on top of Single Layer Water shader.

Below are 3 solutions to address this problem.

Solution 1: Ray-Traced Shadows

Using Ray Traced shadows resolves the issue by accurately rendering shadows on the water plane, ensuring the water behaves as expected without harsh shadows.
Select the Directional Light in your scene. In the light's properties, locate the "Cast Ray Trace Shadows" setting (under the "Ray Tracing" category). Change it from "Use Project Settings" to "Enabled."

This immediately corrects the shadow issue, allowing the water to appear transparent where shadows previously appeared.

You can enable Ray Trace Shadows Globally. Go to Edit > Project Settings and search for "Ray Tracing".

Enable the "Ray Trace Shadows" option.

This applies Ray Trace shadows across the project, ensuring consistent behavior for all Directional Lights.

Note: an RTX-compatible graphics card is required for Ray Tracing and Ray Tracing must be enabled in the project settings.

With ray-traced shadows enabled, the water plane no longer shows harsh shadows from nearby geometry, behaving as expected. This is the most effective solution for projects that support ray tracing.

Solution 2: Avoid Using Directional Lights

Since the Directional Light causes the issue, one solution is to eliminate it and use interior lights, such as point lights, rectangle lights, or spotlights, which work correctly with Single Layer Water shaders.

This approach restricts your lighting design, as Directional Lights are essential for outdoor scenes. Use this solution only when interior lighting is sufficient for your scene.

Solution 3: Use HDRI Lighting with Skylight

Another alternative is to replace the Directional Light with a Sky Light using an HDRI (High Dynamic Range Image) to light the scene. This eliminates the shadow issue while providing natural lighting.

Delete the directional light from the scene then add or select a Sky Light in your scene.

Disable "Realtime Capture" in the skylight settings and set the "Source Type" to "SLS Specified Cubemap." Then choose an HDRI cube map to light the environment.

The HDRI-lit scene eliminates harsh shadows on the water plane, provides realistic reflections and maintains a natural look. This solution doesn't require Ray Tracing to be used.

Solution 4: Adjust Directional Light Source Angle

Another viable option is to soften shadows by adjusting the Directional Light Source Angle.

Select the Directional Light and increase the "Source Angle" property. Higher values soften contact shadows on Static Meshes.

The only problem is it doesn't soften the shadows on the water plane. You'll need to enable 3 console commands.

Here is how.

Close your project in the editor. In the Epic Games Launcher, go to the Library tab, right-click your project, and select "Show in Folder."

Navigate to the Config folder and open DefaultEngine.ini (make a backup first).

Locate the last r. console command (e.g., r.LumenHardware).

Add the following three commands below it:

  • r.Water.SingleLayer.DepthPrepass=1
  • r.Water.SingleLayer.ShadersSupportVSMFiltering=1
  • r.Water.SingleLayer.VSMFiltering=1

Save the file and reopen your project.

Increase the source angle again to see softer shadows on both Static Meshes and the water plane.

Limitations: This solution only works for shallow water, where the bottom surface (e.g., landscape or static mesh) is visible.

Harsh shadows persist on deeper water, making this a limited fix.

Conclusion

For the best results, enable Ray Traced Shadows if your hardware supports it.

If not, consider HDRI lighting or interior lights to achieve realistic water rendering.

For shallow water, tweaking the source angle with console commands can be a quick fix. Experiment with these solutions to find the best fit for your scene.

UE5 Environment Asset Pack

If you liked the environment assets that were used in this tutorial, take a look at Environment Asset Pack: UE5 Modular Infinity Tiled Rooms and Pools Environment.

This is a very easy-to-use modular UE5 environment asset pack of interior tiled rooms and pools.It will allow you to create variety of interior liminal space layouts and change their visual look with 58 unique Static Meshes and 9 different Material Instances using UE5.

SUBSCRIBE & GET FREE UE5 PDF GUIDE

Subscribe to receive NEW/UPDATED and FREE "UE5 Beginner's Quick Start Guide" PDF (90 pages).

Subscribe and Get Free UE5 PDF Guide

Visit this page for more info about the guide...


Follow WoLD




UE5 FUNDAMENTALS VOL.1 COURSE


UE5: RETRO OFFICE PROJECT


LEARN THE PREPRODUCTION PROCESS


ABOUT WoLD & ALEXG

About World of Level Design

My name is AlexG. I am self-taught level designer, game environment artist and the creator of World of Level Design.com. I've learned everything I know from personal experimentation and decades of being around various online communities of fellow environment artist and level designers. On World of Level Design you will find tutorials to make you become the best level designer and game environment artist.

Read More »


Home Terms of Use/Trademarks/Disclaimers Privacy Policy Donate About Contact

All content on this website is copyrighted ©2008-2024 World of Level Design LLC. All rights reserved.
Duplication and distribution is illegal and strictly prohibited.

World of Level Design LLC is an independent company. World of Level Design website, its tutorials and products are not endorsed, sponsored or approved by any mentioned companies on this website in any way. All content is based on my own personal experimentation, experience and opinion. World of Level Design™ and 11 Day Level Design™ are trademarks of AlexG.

Template powered by w3.css