How to map texture to landscapes 0-1 UV coordinates, no tiling

Hi,
I’m trying to put a texture onto a landscape that has no tiling - same way you’d put a texture on a character model for instance. It should fill the 0-1 space.

I am trying to use landscape layer coordinates but having a hard time. How do I determine the correct scale? My terrain is 4033, but when I input 4033 it looks a little off. And the big problem is that the texture is not aligned, and the Mapping Panning values seem random. I have put many values in there but cannot figure out what it is actually doing because the results seem random.

For instance, I got one axis to align with a Mapping Panning U value of 0.41. Why? The problem is, that took an hour because I have to enter values on at a time, recompile the shader, and that can take up to a minute.

I must be doing something wrong, this cannot be the normal way to map a texture to a landscapes 0-1 space.

Any advice is apprecaited.

1 Like

You do this with world position offset and bound size.
That way no matter what the landscape size is, the UV will always be in a 0 to 1 range for the whole landscape.

1 Like

awesome thanks!

Hi, I have the same problem. But I can’t understand what you wrote as a solution. Can you explain more clearly?

3 Likes

Is there any update on this? I can’t seem to align normal map of landscape exported from Gaea to landscape itself

you can do it like this:


to get the landscape size select the landscape actor and check teh details panel here:


Overall resolution
just enter that number as the divisor to landscape coords

That’s a really bad suggestion.
Landscape layer coord can be given different values. With different values your division node would become more and more useless.

Using UV0 you’d never have the issue.
There’s some precise math for it I can see about digging out in a second…

landscapes typically dont change so it works fine for me.

why bother saying it is bad if you wont show a better suggestion?

That’s an Assumption. With a real emphasis on the first 3 letters part…
Landscapes change from level to level. What works in one level probably won’t work in another.

Object Position > Mask RG > Subtract A
Object Bounds > Mask RG > Subtract B
→ Result into > a new Subtract B

Absolute WP > Mask RG > the new Subtract A
→ Result into > Divide A

From: Object Bounds > Mask RG > Multiply * 2 > Into Divide B.

End result is a UV that will always cover any landscape of any size. Or any object for that matter - in X/Y directions.

it’s not an assumption in my project, it is how I’ve designed it. all landscapes are the same size, and if they werent it still doesnt matter because each has a unique material instance so i can just make the divisor a parameter. Ezpz.

Thanks for the additional solution, but you do have the communication skills of a cat.
If you dont like the inflexibility of my freely given solution, all you have to do is add yours and say, “this solution has the benefit of requiring no further input and works regardless of landscape size.” And then I’d say, “awesome, thanks dude.”

Actually the solution was given several years back, but obviously you never even read it.

What’s worse is that you further display your ignorance and share ■■■■■■■■ that shouldnt be shared, since it was never the solution nor will it ever be.
So in other words, me not ouright telling you to stfu and get off this forum is restraint i probably should have never shown you…