UE5 SpeedTree Wind Issue on Foliage Instances

SpeedTree wind animation isn’t appearing correctly on foliage instances. I exported a simple grass model from SpeedTree with wind. The wind animation plays fine on hand-placed grass, but grass painted onto the landscape in Foliage Mode ends up getting stretched all over the place. Below are a couple screenshots to illustrate the issue. The hand-placed grass is on the left.

Wind disabled:

Wind enabled:


The material setup is pretty simple, I basically have the SpeedTree node going into World Position Offset with a simple switch so I can toggle it on or off in the material instance.

Material setup:

I’ve seen some suggestions about turning on ‘Evaluate World Position Offset’ in Foliage Mode, but that made no difference. The issue seems to get more exaggerated on instances painted further away on the terrain from where I painted the first instance.

Any ideas? Thanks.

2 Likes

Bump! Having the same issue over here… Grasses and Trees are strechted beyond belief.

I’m using speedtree trees. I have the same problem.

UE 5.0.3 and have the same issue. Same problem: hand placed trees seem to be just fine. But I’m doing a freaking island and the idea of hand placing EVERYTHING is :nauseated_face:

Foliage tools are great. Part of the story involves a hurricane, so I kinda need the trees to move.

Changing line 1902 in Shaders/Private/MaterialTemplate.ush from #if USE_INSTANCING to #if USE_INSTANCING || USE_INSTANCE_CULLING seems to fix it

4 Likes

The above is a weird workaround, but seems to work for all of my SpeedTree models.

Once I made that change, everything worked perfectly!

1 Like

Glad to help:)

P.S. I have not noticed any artifacts during my work in UE5 after changing this line, so, i think everything’ll be fine)

where do you find this .ush file???

Engine / Plugins / Editor / Shaders / Private / MaterialTemplate.ush

Find your installation of Unreal Engine and you should be able to find the file.

I m new to UE5. To be sure that we are on the same issue,my trees were glitching and changing sizes when I used wind for their animation.
I solved it by going to the materials and changing wind parameters on leaves and trunks when necessary