I need help deciding how to create my 512sq km world

TYPE OF DATA
I have been using 8 elevation maps of file type .asc at a resolution of 2m.

Another option is to use LIDAR data of 0.5points/m2 density. The weight of the 240 LIDAR files (of type .laz) is around 15GB, which is notably more than the 1GB of the first option.

What do you think is better? Maybe LIDAR data is more precise but generates too many polys once placed in a terrain generating app and then into UE5?

Landscape splines work on anything even without layers.

As for splines, I thought of just sculping buildings on Blender on top of the landscape tile that those buildings should be placed upon. As for the paths, I though of using Houdini or TerraSculptor to just add the texture of roads. I do not know for what else would I need splines, could you enlighten me?

Not really. It depends on what you are doing and your workflow.
If you are working with tiles you most definitely do not want to normalize each tile.
It would require a different scale and separate imports on each tile… making it, well, a mess?.

What do you mean by normalizing? Do you mean setting the same min/max values for all tiles?

Very much doubt it as there are similar worlds that run on Mobile out there.

Maybe he is referring to having such large terrains as Landscape Actors, which could be very limiting? But since we will use Static Meshes maybe it is more performance-friendly.
And as for the rest of assets, they will be low poly and with proper LODs and culling techniques, shouldn’t be a problem. Maybe foliage would be?

As for @noone ,

That isn’t how Unreal Engine works. It doesn’t map PNG grayscale pixel values to real world elevation ranges. So “under water” or “above water” is where you place a water plane if you are even going to use one. The entire Landscape actor can be moved anywhere on the world XYZ coordinates.
Blacker pixels just mean lower elevation while whiter pixels mean higher elevations.
You always want to normalize all PNG-16 files that you import into Unreal, and then set Scale Z where 100 is 512 meters of elevation range.

So basically, the height values that we can read in the .asc files do not matter for UE? Only for terrain editing tools, and then UE simply takes the mesh and places it?
As to normalize, what is it? To make X Y Z values = 100?
As for the water, I will have rivers and a lake. I though of using masks to determine where water is? At least that’s how it worked in GAEA.

I have been trying to use TerraSculptor. IT has allowed me to import a 6144 x 14336 pixels .tiff file. The original resolution was 2m, so in truth my terrain is 12km x 28km. I guess I will have to scale my terrain inside UE.

The .tiff file is divisible by 1024 and 2048 tiles, and since I will be using this terrain as a static mesh actor instead of a landscape actor, I guess it does not matter what resolution I will use for the tiles.

Your program has correctly read the height, but the size is a little bit off compared to what I believe should be. If 1 pixel = 2m, then this terrain should be aprox 12km x 28km, yet your program says it is 15.73km x 36.77km, which gives a total of 3790,32 sq km, something way out of order, since it should be 336 sq km (plus it does not even make sense since 15.73 x 36.77 = 578,39 sq km)

As for the extents in world units, my terrain used real world coordinates and it seems they have been inherited, which puts the mesh in a really long position in world units.

It also says that the total triangles are 176.119.810, which I guess it makes sense, but I believe that with tiling the map with 1k tiles (4sq km) and setting LOD with culling should work fine.
image
image

As for texturing, since I will be using static meshes, I should be able to use regular texture options such as atlases or maybe it would be better an array so to allow tiling. Then i would have 1 draw call for materials.

Within the programming/graphics context Normalizing only means one thing:

Bringing the value of something to be 0 to 1 maximum.

Character/ai movement for one.

Depends on the needs and accuracy.
For archviz toy want lidar, for games, it probably doesn’t matter.

1 Like

Well I have my landscape here. Take into account that this is 12km x 28km, so what seems to be small height changes from the POV of the character they will be pretty huge (in real world the smallest point is 18m and the tallest is 600m). Do you think this image captures this correctly? Maybe the mountains are not pronounced enough?


I would like to know what texturing options I have and where should I do it. Let’s say I divide the terrain in 3 columns x 7 rows. This tiles (1024x1024 at 2m resolution = 2048m x 2048m = 4km^2) would be separate static mesh actors. Maybe I should make smaller tiles so to adjust LODs better for things like displacement, shaders, etc.?

What would you @MostHost_LA and @noone recommend? Also if you could specify the performance characteristics of the method you propose (draw calls mainly) it would be great.

I’ve been looking into vertex painting, also the mesh painting tool in UE, using blend materials that take many textures, maybe texture arrays and UV unwrapping the tile? Or maybe I should do it in QGIS or TerreSculptor?

Also, for a terrain this big, what would be an “acceptable” ammount of polys? Right now i have 176 million. Of course with LODs and culling, blablabla it will not be this ammount rendered at once. Nevertheless, could you give me an indicator of what should it be to perform well?

Thanks.

Again, performance needs depend on desired lower end platform.

Re texturing:
Whatever works with the smallest possible file size (in pixels, as power of 2) is always best.

You can do pretty much anything, so you should study up or review mesh material methods depending on what ypur gameplay will need to accomodate for.

I have no idea. Check the heights of the tallest points - even than 600m isn’t that high of an elevation.

1 Like

@noone
I bought your software. I am trying to use the DEM explorer. But my terrain falls between two tiles and I can’t place my viewport there. I wonder if I should downlad two separate files?

Also, what is the resolution of this DEM maps? 1m? 2m? Depends on zoom level?

If it does depend on zoom level, then I should download many tiles on the highest zoom level possible?

edit: I have been playing around and it seems that it is zoom dependant. At zoom 12 i have a 2m resolution (6k pixels for a 12km map). Could I zoom in more and then download different maps and stitch them together? Also, from which website do you take this data, maybe they allow me to download the map by parts and I can stitch them together in QGIS, then import into TerreSculptor.

I have found many types of datasets from my gov website. One is the height data but also there is slope data. I remember @MostHost_LA said something about creating slopes. Could I use this slope data that covers the exact same territory as my heightmap? For what purpose would it be used? Does UE need it?

edit: well I have my map here:

It looks good as for the sculping but the texture is only temporary, it shouldn’t really look like this.

Sorry for being repetitive, but I do not really understand what texturing options do I have. Is this possible and performance efficient:

Since the terrain will be many static meshes, I thought I could apply the texturing techniques that we can use for any static mesh. Since this terrain will be tiled in 1k tiles (at 2m resolution, so 1 pixel = 2m, hence 1024x1024 tile = 2048km x 2048km) I will need techniques that avoid texture tiling (that makes the patterns look repetitive). I was wondering if using texture arrays would be the best practice here since they allow tiling. I think that we can have texture arrays of up to 14 textures, so I could have the different biomes of my map covered by only one texture array. At the same time, this is only 1 draw call right? Since I can UV unwrap in UE5.3, I thought I could create seams in my terrain tiles that would allow to position the unwrapped parts into different textures of the array.

No, slope data is slope data, not height.

Its a visual representation from back to white of what the slope angle at the specific pixel should be - calculated from the adjacent pixels, or real data from lidar, depending on what you can get.

You use that to do things like:
Ok, from 25% to 45% we have grass, so you print out a normalized map of that range, based on the slope data, and you have the splat map to apply as the grass layer.

No, but it can use it - when you import terrains or tirles with an asisgned material you habe the option of setting the image the layer should paint from.

Re texturing.
Its probably cheaper to run a single texture at 4k with WPO as the driving factor for UV placement and use it to cover the meshes regardless of where they are positioned.
Particularly at a distance.
That way there is only 1 image in ram rather than several per tile.

It really just depends on what you are doing and what you wish to achieve.

Materials can also react to LODs so you could increase quality when near.

1 Like

My aim is the usual for an open world RPG. Closer tiles should have more polys and higher quality material, farther away tiles should have less polys and worse material (or not be drawed at all).

Also, my terrain has a natural slope. So if I set that for example from 0 to 50 it should be grass, it will not fit my map well. Also for the rivers, I have rivers that start from a high altitude and decrease. How am I supposed to work with that if I want to add water to the rivers? Some parts of the rivers will be above sea level, others below.

You’d need to make water and rivers yourself anyway depending on gameplay.
Having the mesh itself just gives you better options to do so with custm fit sheets.

The slope is just a value per pixel. How you use it to derss up the landcape is up to you- or the artist.

1 Like

You’d need to make water and rivers yourself anyway depending on gameplay.

Do you mean inside UE? I thought of using a mask for rivers.

Anyways, I was wondering, if I create a tiled terrain and I import it as static meshes, how do I preserve their relative location with respect to the other tiles? I am using a convention to name them “name_x0_x0” but I think this is only useful when importing the terrain as landscape actors. How would i do it so that when I place the static mesh actor in the scene it keeps the relative position?

Also, could you give me an opinion on the following texturing idea:

My terrain is constituted by tiles that are static meshes. That means that I have to assign a material to each tile (meshes of 1024x1024 pixels). Since the masks cover the whole map, I have two options:
1- Divide the masks in 1024x1024 tiles. Then make a different material for every mesh with the respective parts of the mask that have to affect it. For example, the top left tile would need to have a material that uses the masks for the top left tile. It would be tedious work but it could be done.

2- Use the full-map masks in one only material. Then I could use my terrain masks (river, mountain, valley, etc.) for the full map and for each terrain mesh tile I would mask the masks to select the part of them that affects that particular mesh. Maybe if I used a pixel coord node multiplied by 1024 I could adjust the part of the terrain masks that is used for that mesh instance. This would reduce draw calls but would increase complexity. I guess it would also be easier to do too.

When you import from houdini for instance, the transforms are kept as part of the objects.
Same with blender unless you move the objects to 0,0,0.

[quote=“carmanfer, post:29, topic:1303821, username:carmanfer”]Masks …
This would reduce draw calls but would increase complexity.
[/quote]
It wouldn’t reduce drawcalls. You have 1 per tile no katter what.
If you have 2 materials you’d have 2 per tile.

Drawcalls have nothing to do with what a material does internally.

Your best approach to avoid overloading VRAm with textures is to create a system that functions similar to the landacape paint:
A WPO positioned texture stretched across the whole landscape is used to control what layers of what material show up.
Thats also useful since you can run high detail normal maps baked onto low detail LODs over the whole landscape, reducing light changes when geometry shifts.

The theory behind it is that you have x amount of textures (usually just 3) per paint layer, plus the packed texture handling up to 4 - possibly 8 layers when using negative space (the black).
Plus the global normal map, and possibly 1 more global diffuse.
Vs 144 textures when you use one for each tile.

1 Like

I will try your method.

Nevertheless, are you sure my method I wouldn’t reduce draw calls?

I thought that using a double mask I could use one master material that would contain all the terrain masks (river, mountains, valley, etc.) packed, then I could select which part of this terrain masks is shown in a certain tile by masking the masks and displaying only the part that belongs to that tile. It would still be just one material, so I guess it would be 1 draw call for all the tiles combined? It’s like a texture atlas which is just one draw call too. Isn’t this right?

Also, what texture quality do you consider an equilibrium between quality and performance for large tiles? I read that 2k would do alright? Maybe 4k?

Yes, why would it?
Nothing you do within a material shader has any impact with how many objects are on screen in this case
Ofc if you set the opacity to 0 on the object they potentially get culled/not rendered.

To somrhow change the drawcalls you’d have to aggregate landscape pieces together - say with HLODs for instance.

Its not how many materials total that give you the number of drawcalls.
Is how many materials on a single mesh -1 for the mesh itself.
So if you have 3 materials on 1 object, and spawn 10 copies of that object, that’s 30 draw calls.

It really depends on how you map and set up the material. Even something ridiculously small can look good when set up properly.

Start at 2k. Move up if you cant get it to look right.

You can do some basic math of how big a pixel is in world space by just assuming that the height/width of the texture marches the size in km of the landscape’s total.

So if you have a 2k map distributed on an 8km tile, you then have each pixel cover approximately 4m^2 I believe.

Depending on what kind of work you do in the material that can either be a lot of resoluton or very little… it really just depends on art direction a lot too.

1 Like

Yes, why would it?

I was comparing the case where we had 1 different material per landscape tile to having only one master material for all tiles. As far as I’m aware, having the same material in multiple meshes implies that you only have one draw call for all the meshes in terms of materials (of course you will also have as many draw calls as meshes are drawed).

So if you have 10 meshes that use the same material that would be 10+1=11 draw calls.
But if you had 10 meshes that use different materials that would be 10+10=20 draw calls.

What? No.

Every mesh is a drawcall. Period.

On top of it, if a mesh has more than one material it will cost more calls to render as many materials it has.

Master materials don’t magically reduce or increase drawcalls they are just like any other material would be.

Say you have 10 meshes with 2 materials each, that’s 20 drawcalls.

Say you have 10 meshes with 3 materials each, that’s 30 drawcalls.

It doesnt matter at all if the material used is the same on all 10 meshes to drawcall count

1 Like

I’m working on something similar, this has been an interesting read.

How are you handling collision on your static mesh landscape chunks? I would think anything close to matching the terrain would be fairly complex and a big performance hit.

1 Like

Well I saw a video that stated otherwise: https://www.youtube.com/watch?v=A-P0llMckSw

Anyways, I’m having trouble aligning the mesh tiles. Maybe I should just use regular landscape tools since now I have the computational power to load the landscape with world partition. I don’t know. This is two tiles in blender:

It doesn’t matter how do I position it, there is always some slight difference in the edges. But this “slight” difference is in truth huge because one tile is 4sq km. Any idea on how to fix it?

I have not done that yet. My guess would be to have the closest tiles using collision and the rest having it deactivated. Maybe with nanite it would be improved. Each tile of mine 4sq km and 2 million tris, but I plan on decimating them in blender to reduce that to 1 million. So if I’m standing in the corner of a tile, I would have 4 tiles active, therefore 16sq km that would be 8 million tris (or if I decimate, 4 million). So I could have some collision set for 4 million tris.

Of course you could also make the tiles smaller (1 sq km) and then the collision would only apply to much less tris, maybe 250k per tile. In the worst case, you could have 4 tiles active (if you are standing in the corner of one, the other three would be active), so then that would be 1 million tris with collision.

As for what type of collision, I don’t know, I haven’t looked into it yet. One option is to make a low poly version of your mesh, and use that as collision. But it will not be as precise, and if the tiles are big it might be noticable that you are either floating or shoved into the ground.

edit: now that I think of it. I think that directly decimating the tiles for the main mesh + nanite should work well (so to reduce tris), then you could use the same mesh as collision asset. If the tiles are sufficiently small and are constituted by a “few” tris, then you should be good to go. Then, there wouldn’t be any discrepancy between collision and actual mesh.

Large worlds are always interesting to lurk in on. But ^this^ is a potential game killer… So it really needs to be looked at now, even before the visual aspect. Interested to know… Apart from biome (foliage / rivers and so on), what’s the ultimate goal… What’s the plan for the terrain when its done… How do you plan to populate it all with interesting stuff??? Have you looked at all the pre-existing marketplace plugins too from landscapes to planets to voxels… Generally landscapes don’t perform well in UE vs meshes. :wink: Mosthost has written books about this. :stuck_out_tongue_winking_eye:

1 Like

What’s the plan for the terrain when its done…

My game is a historical open-world RPG. The player should be able to walk almost everywhere (except high slope terrain). The terrain does not need to be modified after importing into UE5, and obviously neither in-game. The landscape is a heightmap from a real location, so I cannot use premade ones from the marketplace. I do not need to modify the terrain after import so it doesn’t really matter if I use static meshes (by the way, UE5.3.1 allows to modify vertices in engine I believe).

How do you plan to populate it all with interesting stuff???

To populate the world with interesting stuff I already have the story of the real events that ocurred. By the way, I have recalculated the terrain size and it’s not 512sq km, but rather 260 sq km, at a 2m resolution, hence it would be 9000 pixels width x 14000 pixels height (aprox).

Generally landscapes don’t perform well in UE vs meshes.

Yes, that’s why we’re here. If I could just get rid of the seams between tiles I could just import them into UE and problem solved.

PS: I am no expert in coding, but when using static mesh actors for landscape instead of landscape actors is way better performance-wise, then maybe Epic is doing something wrong.

1 Like

I did a test:

  • 1.6mil tri landscape mesh
  • Nanite on
  • Collision: use complex as simple
  • Collision: Customized collision mesh (using same landscape mesh)

It ran around 40fps. System specs nvidia 3080, 128gb ram, i9-13900k.

I think collision is your biggest issue. I’m going to do some more test breaking it into smaller sections. Maybe with small enough chunks, you can only have collision enabled on your current mesh.

1 Like