Download

World Machine Heightmap Elevation in UE4

Hello,

So after importing the heightmaps in UE4 it’s always so much flatter than it shows in UE4. The solution to that has always been giving the landscape in UE4 a high Z value. But I have a problem with that. Now anyone know how can we import the heightmap and have a 1:1 elevation as in WM without touching the Z value in UE4?

Edit: Increasing the Z value to get the correct height leaves terrible results on the landscape. (Something similar to 8Bit heightmap steppies).

How big is total scale

I’ve never had a problem. Have you altered the default settings in WM in regards to terrain height scale? I believe it should be 2600 meters?
I used to have this problem in UDK with every terrain but haven’t seen it once in UE4 after dozens of terrains.

I’m just importing a 8129x8129 heightmap with default settings. The elevation is a lot flatter unless I put a high Z value in.

If I remember correctly it is 100% z scale in UE4 per 512 m of height in World Machine. So for example if you have set your world machine project to have height from -512 to 512 meters then you should set z scale to 200% in UE4. If your WM project height is 2600 meters then (2600 / 512) * 100 = 507,8125 so that is your z scale for your landscape in UE4.

EDIT: seems like default height in WM is 0 to 2625 meters so z scale of UE4 landscape in this case should be 512,6953125.

The way I have scaled z in UE4 from WM is the following:

  1. Create a box in Editor about the height of the WM max height, align bottom to height 0
  2. change perspective in editor to side view
  3. Scale the whole terrain until your top peak hits the box boundaries

I did that a few months ago but this is for me the easiest way

Fred

Nice idea fred.
As to my previous reply it was late and I forgot to add that I had the opposite problem as you in UDK. My terrains were ridiculously stretched out on the Z and had to be scaled to about 1/8
What version of WM are you using and what format are you exporting to?
I used to export RAW in UDK but now I always export 16 bit png. Maybe the file format makes a difference?

The problem with increasing the Z value is the landscape wouldn’t be smooth anymore. It gets some steppes happening and even smooth tool only moves them around and doesn’t smooth it actually.
I’n my case I have a stylized landscape that has to have an elevation about 2750 meters and giving it a Z value around 750% makes it look almost correct but brings a horrible stepping problem on it.
In my case 750% is extreme but it happens on lower values even like 400%. What should we do about it Epic?

Use this calculation : Worldmachine max hight * 0.1953125 = Z scale value for ue4

Set your WM project height to 512 meters.

Are you willing to share the world file so I can see what’s going on with it?

Question? How much better is World Machine than L3DT?

Honestly, I think the two are more different, than better or worse. L3DT has less predictable generation, if you are going the algorithm generation route. Though I like how fast L3DT is at generating terrains. It’s in my toolset, along with World Machine and the UE4 terrain sculpting. Basically, I’ll generate in L3DT using the blank canvas, or even the design map, and then tweak the design map. I’ll use the heightmap generated as a base, bring it into UE and then tweak in there with terrain sculpting. I’ll export from UE, and bring that heightmap into World Machine to filter and add details like erosion and such. Export from WM, import to UE, and tweak some more. So basically, the workflow is:

  1. Landscape concept (in your brain)
  2. L3DT for initial base
  3. UE4 for reference (good to check scale of features and such) and tweaking
  4. World Machine for fine details
  5. UE4 for more reference and tweaking
  6. Bounce back and forth between UE4 and WM until satisfied with final base heightmap

If I wasn’t so busy, I would do a more in-depth process breakdown on the wiki… I need to record my stable workflow anyhow for my own personal reference. My memory is too full of oh my god kitten video