# Megascans trees with nanite and virtual shadow maps glitch

**URL:** <https://forums.unrealengine.com/t/megascans-trees-with-nanite-and-virtual-shadow-maps-glitch/1331351>\
**Category:** Rendering\
**Tags:** Shadows, Raytracing, unreal-engine, trees, Megascans, Nanite\
**Created:** [October 13, 2023, 1:08pm UTC](https://forums.unrealengine.com/t/megascans-trees-with-nanite-and-virtual-shadow-maps-glitch/1331351 "2023-10-13T13:08:19Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Nick.Ster](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Nick.Ster](https://forums.unrealengine.com/u/Nick.Ster)\
**Post date:** [October 13, 2023, 1:08pm UTC](https://forums.unrealengine.com/t/megascans-trees-with-nanite-and-virtual-shadow-maps-glitch/1331351/1 "2023-10-13T13:08:20Z")

</div>

I have problem with shadows and Megascans trees. When nanite and ray tracing are enabled, trees are moving (with the wind) but shadows don’t, without ray tracing shadows are moving but some of them (like small branches shadows) disappear when camera is moving towards the trees, and there Is weird grid-like looking glitch, some of the shadows are “cut”.

Workaround I found is changing shadows map method from virtual shadow maps to shadow maps and turning off ray tracing. Is there a way for nanite, ray tracing and virtual shadow maps to work with Megascan trees?

[![](https://d3kjluh73b9h9o.cloudfront.net/original/4X/7/b/a/7ba51dc262d8231eb627e92a9c6e7c9d79cd0a9a.jpeg "source: imgur.com")](https://imgur.com/EJ2bnTC)

---

<div class="post-metadata">

**Author:** ![WillemPostUrk](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@WillemPostUrk](https://forums.unrealengine.com/u/WillemPostUrk)\
**Post date:** [October 15, 2023, 2:58pm UTC](https://forums.unrealengine.com/t/megascans-trees-with-nanite-and-virtual-shadow-maps-glitch/1331351/2 "2023-10-15T14:58:19Z")

</div>

Same problem here… Not sure if there’s a solution for this but haven’t found it yet.

Pretty new to UE and trying to figure out how to get animated shadows from Megascan Trees using Raytraced shadows.

(“Evaluate World Position Offset in Raytracing” checkbox  
does NOT work)

---

<div class="post-metadata">

**Author:** ![Online\_Learner\_KPoqc](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Online\_Learner\_KPoqc](https://forums.unrealengine.com/u/Online_Learner_KPoqc)\
**Post date:** [June 11, 2024, 11:32am UTC](https://forums.unrealengine.com/t/megascans-trees-with-nanite-and-virtual-shadow-maps-glitch/1331351/3 "2024-06-11T11:32:01Z")

</div>

Yes! the checkbox didn’t work for me as well. It seems to solve most of the shadow issues for everyone else though. Did you solve it?

---

<div class="post-metadata">

**Author:** ![Dazzling\_Divine](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Dazzling\_Divine](https://forums.unrealengine.com/u/Dazzling_Divine)\
**Post date:** [July 18, 2024, 4:32am UTC](https://forums.unrealengine.com/t/megascans-trees-with-nanite-and-virtual-shadow-maps-glitch/1331351/4 "2024-07-18T04:32:22Z")

</div>

> [@Online\_Learner\_KPoqc](#):
>
> u solve it?

I’m facing the same issue. Did you manage to solve it?

---

<div class="post-metadata">

**Author:** ![wouterdek-dev](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@wouterdek-dev](https://forums.unrealengine.com/u/wouterdek-dev)\
**Post date:** [July 24, 2024, 6:45pm UTC](https://forums.unrealengine.com/t/megascans-trees-with-nanite-and-virtual-shadow-maps-glitch/1331351/5 "2024-07-24T18:45:46Z")

</div>

Check if the tree mesh stays fully within the bounds of the tree mesh while it’s animating. You can do this with Show → Visualize → Out Of Bounds Pixels in the editor viewport.

---

<div class="post-metadata">

**Author:** ![Rented\_Magician](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Rented\_Magician](https://forums.unrealengine.com/u/Rented_Magician)\
**Post date:** [September 28, 2026, 6:47pm UTC](https://forums.unrealengine.com/t/megascans-trees-with-nanite-and-virtual-shadow-maps-glitch/1331351/6 "2026-09-28T18:47:21Z")

</div>

It’s been years. Has anyone found the answer?
