I started to have a problem with my landscape material when I added world displacement layer blends. The material just stops compiling and I have no idea why this happens as I don’t think it’s so complex shader.
It has 1 unused Alpha Blend layer (because I’ve seen a tutorial on youtube in which the guy suggested so), one Weight Blend and 4 Height Blend layers. One height blend is not connected because I don’t have textures yet.
I’m using distance-based tessellation multiplier to fade out displacement map over distance (usual distance based thing). I also have visibility mask on my landscape.
Tessellation itself works just fine, but when I blend at least 2 world displacement maps (in this case these are just height maps) using layer blend node it just doesn’t want to work no matter what I do. It’s probably good to note that I actually use material functions for each layer to make it a bit cleaner and easier to change stuff.
I’ve already tried some things I found on the internet like changing texture sampler source to “shared: wrap” (which I would do anyway), turning off adaptive tessellation, crack-free displacement, using PN triangles.
What seems to fix this issue is turning one layer’s displacement off in my instance, but it’s not really what I want to do.
I really don’t know what’s happening and why is it happening. Base pass shader has 96 instructions and vertex shader has 30.
And yes, I’m pretty sure I need tessellation on my landscape because it just looks so flat and fake without it. I hope it can be fixed and it’s not engine related. I’ve seen LAM and I’m pretty sure it has a bunch of different layers with tessellation, so I don’t think there’s something wrong with Unreal itself.
I’d really love to get some help from the community as I haven’t ever run into this kind of problems, this is my first so advanced game that I’m working on now and I hope I’ll learn some stuff as the development goes.