Triplanar mapping from Local Space - problem when scaling. How to make it work?

Lyubomir Iko
Mon, 08 Aug 2022 16:14:38 +0000
Asset Creation

World Space Aligned function that comes with Unreal cannot be used when objects are rotated:

So I modify a copy of the function so that the projection is in Local Space; like this:

The rotation problem is fixed, However now I cannot scale the object independently from the texture…

I try to subtract the position of the object from the AbsoluteWorldPosition, then use TransformVector to ignore the local scale:

This doesn’t work either.
I try to turn off Tangent Space Normal and I did a lot of other variations…

But so far - nothing. Please help.
To summarize - I need Triplanar mapping done from Local Space that is independent from scaling the object in the world.

17 posts - 5 participants