# Weird blue artifact on foliage

**URL:** <https://forums.unrealengine.com/t/weird-blue-artifact-on-foliage/2732467>\
**Category:** Rendering\
**Tags:** unreal-engine, question\
**Created:** [June 30, 2026, 9:19am UTC](https://forums.unrealengine.com/t/weird-blue-artifact-on-foliage/2732467 "2026-06-30T09:19:30Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![brs-sebascova](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/brs-sebascova/32/1052483_2.png) [@brs-sebascova](https://forums.unrealengine.com/u/brs-sebascova)\
**Post date:** [June 30, 2026, 3:45pm UTC](https://forums.unrealengine.com/t/weird-blue-artifact-on-foliage/2732467/2 "2026-06-30T15:45:03Z")

</div>

Hello there @aimbotRaz!

Checking around the community, this issue has popped up from time to time, and it boils down to the way Megalights is operating.

The feature doesn’t calculate lighting on every single frame. Instead, it casts multiple rays, then stacks multiple frames together to smooth out the shadows. So, when your camera is perfectly still, UE will just keep stacking frames on top of each other. And since grass blades and hair strands are quite thin, lighting will tend to bounce wrong, and generate the artifacts you are seeing. Then, when you move, the engine discards the frames and starts over, making the blue stuff dissapear.

To fix the problem, there are a few parameters to test around:

- Changing the lighting data format to either **Float16 RGBA** or **Float32 RGBA** , using `r.MegaLights.LightingDataFormat 1` or `2`

- You can combine this change with `r.MegaLights.DownsampleMode 1`, to clear up any remaining artifacts

- There’s also the option to adjust Megalights’ sample count, test with `r.MegaLights.NumSamplesPerPixel 2`

- Outside of Megalights, it’s worth testing to adjust your scene’s current AA setting. Go to Project Settings \> Rendering, and test with both TSR and TAA.

If the issue persists, for further reading, please check the related case below:

> [@UE 5.5 -\> UE 5.7 Megalights issue](https://forums.unrealengine.com/t/ue-5-5-ue-5-7-megalights-issue/2675192):
>
> Hello, I upgraded my project from 5.5 to 5.7 and noticed the lighting seems kind of broken now. If I disable megalights it’s fine but I had megalights enabled in 5.5 and it looked good, see comparisons. 5.5 (left, megalights on) / 5.7 (right, megalights on) Also noticing weird artifacts / blue lines popping with megalights on: I’m using the exact same lights, ma…

---

_[View the full topic](https://forums.unrealengine.com/t/weird-blue-artifact-on-foliage/2732467)._
