Stretching on Some Parts of World Aligned Texture

I’m getting inconsistent texture stretching on my material. the stone material uses the model’s UV’s but the moss is projected using world position. what’s confusing me is that it’s only on some parts of the mesh and isn’t consistent with normal direction. could it have something to do with the unwrap? the stairs are unwrapped as a cascade and that part does have stretching.

the material graph below shows the material function for the moss, the blending between the stone and the moss is a lerp based on vertex colour.

i did that but it didn’t change the result. i also tried changing the y and z values in the scalar to see if it was somehow using those but that didn’t do anything either.

if i can’t get this to work i’ll try doing a true triplanar projection and see if that works.

Leave world position input on default, and adjust texture size for moss tiling instead.

I made a trilinear material and applied it to the mesh. the texture stretching is gone but there are still stretch marks and the texture is faded in those areas. changing the blend cutoff strength reduces the areas affected by the issue but increases the amount of stretching and begins to affect the texture.

is this just a limitation of projection?

i’m going to consider this to be a limitation of the projection method and mark this as answered. the setup i have seems to work pretty well on simple models but doesn’t like complex ones, probably because of normal orientation.

I had the same issue on a terrain with a slope effect for the cliff. I fixed it by plugging a Vertex normal WS node to the “World Space Normal (V3)” pin of the WorldAlignedTexture node. I also added a multiplicator to fine tune the vertex normal value. Here is my working configuration for the world aligned texture:

If like me you are working on a landscape shader and you still experience some stretching on some part of the terrain, you can use the Retopologize tool on the parts that still stretch, it did the trick for me.

More precisions:

I was working in unlit mode and didn’t notice that WorldAlignedNormal doesn’t seem to output the same result as the WorldAlignedTexture even when using the same inputs. So I ended up using WorldAlignedTexture for the normal texture too; also, in other levels the “XY texture” output could give me erratic results, I had to switch to the “Z texture” output.

Interesting, I’ll take another look at this when I have time. Thanks.