Need help with landscape material

Hey Guys! I’m trying to create some terrains and learn the trade on my way. I’ve learned a few basics of world machine and I’ve generated a heightmap to use in Unreal Landscape system. I’ve also created few greyscale maps or alpha masks for snow and the ground material.

But, I’m unable to achieve a material with layer blend. This is how it currently looks inside editor:


Here is the Material


World Machine setup


And here is a reference what I’m trying to achieve


I want to get that snow melting layer and expose the layer underneath which is some black material in this case.

I’m new to this stuff, trying to learn. So, please help me out.

Thank You

Generate a new weight map in world machine or just paint onto the landscape by hand -> for the material: Take a look at the landscape demo. There you can see how they made the snow/ice + rock :slight_smile:

Also take a look at this tutorial: -> Instead of the layer blend + layer node, you should just use one of them. When you use the layer nodes, you also have to give them a name (atm both are “none”)

So, I generated separate greyscale height masks in WM and imported them inside the layerInfo as snow and ground respectively. And changed my material into this

The snow layer looks blocky in few spots like this here


Why is this happening and how can I fix this?

Thank You.

I think it’s because of the resolution of your splat map :slight_smile:


“OK, so the secret sauce here is the splatmap size. For whatever reason, you should make the splat / color map around 2 to 4 times the size of the heightmap (factoring here the power of 2 e.g. 2048X2048 on a 1009 terrain) the landscape co-ord will take care of the rest (so set that to the terrain size).”

Thats means if I have a terrain heightmap of 2017 X 2017 then the color map should be 4096 X 4096 to get the proper resolution?

I’ve tried doing that and it gave me some rather odd results. There is an offset in the texture position somehow. So, that didn’t work out well.
I’ll keep trying though.


For best results, I import the weights directly. This gives me the same resolution for layers as the landscape mesh itself, and I can edit/fine-tune them later in the editor as needed.

Start-To-End Instructions

  1. Export your snow & ground heightmaps (NOT bitmaps) from World Machine as 8-bit RAW heightmaps. Save landscape heightmap as RAW16, as usual.
  2. Setup your material with all of the proper layer names you exported in Step 1. As you already have pictured a Ground and Snow layer, you can go to the next step.
  3. Create a new Landscape. At the top, click “Import from File”. Choose your landscape Heightmap file.
  4. Set the Material to the one you created in step 2.
  5. Expand the “Layers” section. There will be 1 entry for each Layer in your material.
  6. Assign/Create a LayerInfo for each entry. Weight-blended will mix it all to a max of 1, while non-blended layers will let you paint every layer up to 1. I recommend using Weight blended, but you should ensure that your layers don’t overlap in World Machine.
  7. Under the LayerInfo is a file listing. Select the 8-bit RAW file you created in step 1 for each corresponding entry.
  8. Fill out any location, rotation or scale data you want, then click Import.

This will leave you with a landscape that can be painted to change any aspect, as if you had hand-painted it completely in Unreal.

Oh, and you can reimport every layer if you update your WorldMachine build. I’m currently working on a WM Macro that will help with exporting this data. Not ready to release it yet…

Here’s an example of this process:

@Kjasi: Thanks for that workflow … it is greatly appreciated. I was struggling this myself and your workflow is much simpler than what I was trying. 8-}

Sorry, I forgot to update my thread. But here is my latest WM setup which is giving me this blocky version.


Earlier I was exporting the respective heightmaps for snow and ground as png. Now, I’m gonna try RAW 8 version as you suggested and see if it makes any difference.

Will let you know.

[UPDATE] I’ve tried but the .raw file crashes my editor and people at unreal suggest we use .png instead of .raw. So, if there is anything else I’m all ears.


That’s odd, since it works fine for me with 4.6.1… Hell, I’ve been using this method since 4.1 without any issues.

Are you importing the RAWs as layer maps when building the landscape, or are you trying to import them as image maps? I import the RAWs WITH the Landscape at generation time. I haven’t heard of PNGs working with this method, so I can’t attest to it’s usability. Using PNGs for materials, yes, but this process is for getting the layer weights imported into the landscape itself, rather than as a material.

Here is a visual representation of my process:

This thread has been a lifesaver for me as I was attempting to get maps from WM to UE for some time. I have since discovered 2 approaches and I am currently weighing the pros and cons of both.

The first one is just taking the inputs from the Unreal Output macro and plugging them into a splatter map converter, then spit that out as a single bmp. Then use that splattermap to height-blend all the layers in the material, using the channels from the map as height inputs.

The second approach is what you illustrated - outputting each height map as a separate file and using those at import as weight maps.

If I’m correct, there’s little benefit in using the former, as it won’t allow me to paint on top of it, right?

Correct. One benefit of the former method is that you can use as many unique textures as you want with a single splat-map. But with the new 128-texture limit in materials, this is less of a concern now.

Sorry, it was my mistake as I was trying to import the .raw file inside the paint section. Duh.

Thanks for the screenshot though.

But the snow texture still looks a bit blocky. Is the snow heightmap is the same resolution as the landscape one? Coz if that’s the case its not working well for me as you can see below


Yes, the resolution of the snow heightmap is the same as the landscape’s resolution. Each point of the landscape = a point that can be used for your weight maps. (Assuming you don’t resize, or rebuild the layer’s .raw files at a different resolution, which would be silly.)

I’m not sure what resolution you’re using in World Machine, but you can try increasing the landscape’s Normal Build Resolution. If you’re building a 505x505 landscape, then you might want to look at a 1009 or 2017 build resolution, (or any of Unreal’s recommended landscape sizes) as it will give you more detail. If you need to keep the same game-scale, then you can just scale the landscape down, so you have a denser mesh for your landscape in the same play area. All of my landscapes in the screen shots are 2017x2017 resolution, but I’m thinking I might double the resolution and reduce the in-game scale by 50% to give me a denser landscape mesh. (By default, landscapes tend to come in with a XYZ Scale of 100.)

If you’re not using one of Unreal’s recommended landscape sizes then you might want to change your resolution to something close to that, then give it another go. Results tend to get weird when not using one of the recommended sizes, which could explain your results.

My Landscape Resolution in WM is 2017 X 2017 and same for the weightmaps. And the scale is default at 100 in all axes.

The Unreal Engine scale when importing shouldn’t be 100x100x100. It should be 100x100x(WM Maximum Elevation found in General Setup * 0.1953125). When importing, note the predicted size of the terrain (Tiled importing) and just multiply or divide the scale values as necessary.

Sorry I didn’t understand exactly what you are saying. My WM Max Elevation is 2500m. Should I multiply that with the number (0.1953125) and set the z scale to resultant value?

That is correct. WM defaults to 2625m, and Unreal defaults to 100 in the Z scale, when it should be 512.6953125 using the default WM value. Since you changed yours to 2500, your Z Scale should be 488.28125.

Honestly, I don’t know how that number (0.1953125) was reached or why people think it’s THE number to use. I’ve always found that it makes my landscapes WAYYY over stretched, vertically. If it looks right to you in Unreal, then I say use it. Personally, I’ve found 100,100,125 to be close to perfect for matching World Machine’s height on a 2625m world.

Kia ora

Sorry really new to this. Is that Unreal Out put a macro you created your self, the only one I see is twice the size, it
Outputs: (Called UE4 Export)

HighAngel Mask
MidAngle mask
LowAngle Mask
Full NormalMap
HighAngle Normalmap
MidAngle Normalmap
LowAngle Normalmap
Ridgeline Mask
HighAngle Splatmap
MidAngle Splatmap
LowAngle Splatmap

I guess this would do the same thing, just use the maps one requires right?

Hey, sorry I didn’t get to your message before now. This is the output macro I made:

I think you would be better off creating an auto landscape material rather than using any additional maps from WM.
Especially if you plan to be able to paint new layers onto your landscape.

There are plenty of tutorials around, here’s a link to a playlist of a great tutorial series on landscape materials:

Hope this helps you out, if you have any problems following it let me know with a reply, I’d be happy to help out in any way. =]

Here’s a screenshot of how my material looked a few weeks back.