Texture Distance Fade with RVT on Landscape materials.

Hello,

Im trying to do this Landscape Material that only uses textures upclose and fades into flat colors the further away they are, at the same time im using RVT for blending between the landscape and static objects, however since flat color is being “rendered” last in the basecolor it paints the entire RVT_Color texture flat green, im still super rusty when it comes to creating my own shaders in unreal but i kinda feel like there should be a way to make it only blend with the texture rather than the flat color, or have the flat green color not draw on the RVT_Color texture?

What it looks like now:

Distance Field Named Reroute used in the Lerp node for the Basecolor:

Landscape Material:

Write on RVT:

Landscape Layer Basecolor Blend Lerp:

Im understand that it might be complicated to fix but I’d love to know any workarounds or sollutions.

Thanks.

Hello there @Dennishierta!

Checking around the community, I think whats going on here is the way RVT and TDF interact. Mainly, RVT is captured using a virtual, top-down projection, not the player’s camera. So, the capture ignores player’s depth, and any logic tied to distances stops working, resulting in that flat color you are seeing.

To fix that, moving that distance logic in your shader could do the trick. Instead of blending the textures before they are baked into RVT, make it happen after it. Checking your current setup, you could add a new output node for the landscape material, plug it before the Distance Fade Lerp, and then adjust your RVT setup to use the new node.

For further details on RVT and it’s functions, you can check it’s UE doc here:

Hello, I think you solved it, what i did was I split the landscape layers into 2 per materials, so essentially one for Pre Distance Fade and one for Post Distance Fade and used the Pre Distance Fade Version to draw on the RVT. (however im not entirely sure how bad this is going to be performance wise when the landscape layers starts to add up to the amount needed for a typical landscape.)

Thanks, have a good day :slight_smile: