How to cull a landscape or parts of a landscape?

How do you cull a landscape or parts of a landscape when you aren’t near it? I have more than one VERY large landscapes that I need to cull from view, but I’m not sure if it’s possible.

Culling will happen by default.

There are multiple aspects to landscape culling.

You can visualize with FreezeRendering

If it happens by default, why can I see my entire landscape then instead of just sections of it while in a level?

It is clipping to the cameras view frustum.

As I said earlier use ~ FreezeRendering to visualize.

Thank you, I see what you mean now. Is there a guide for a way to cull it by distance and not just by if I’m looking towards it?

Is there a guide for a way to cull it by distance and not just by if I’m looking towards it?

Same question as this. I’ve been doing testing and having the largest landscape causes a significant FPS drop when looking at it. If there’s a way to make distant landscape components not render it could bump up open world game FPS by 20 to 40 when the camera is facing the majority of the landscape.

Landscapes are supposed to have mesh impostors past 500m in any engine you use…

Yeah that’s true, but they don’t help performance enough. You can test it yourself if you’d like. Go into unreal 5, add a directional light and then add a small landscape. Turn on stat fps at the top left, and set max fps to unlimited in the console. Then write down your fps. Then delete that landscape and replace it with a medium sized one and write down your fps. Then delete that and replace it with the largest landscape and write down your fps.

You’ll quickly realize that unless someone can invent a method of truly culling landscape, then having an open world game on one big singular landscape is impossible without massive fps loss.

That’s complete nonsense.

First of all, no professional uses the landscape as it is, since its a BS product from 2000 thats never been updated or worked properly on publish.

Second of all, your worse baseline performance will always include 4 landscapes. Since thats the worse possible situation you encounter in world composition or with the newest system. Sitting at a corner of 4 tiled landscapes has all 4 of them loaded.

Third of all. Your impostors are meshes, not landscapes, and they usually only require 1 drawcall per tile.
Now in the case of a 200km landscape with tiles of 1km, thats 40k drawcalls wasted down the rabbit hole.
So do you do the math based on how many drawcalls you want to waste on landscape display.

Fourth of all.
After you finish editing your “landscape”, you just use the final meshes instead of the landscape/level system.
Procedural foliage instead of grass nodes. Etc.
Which prevents you from even having to baseline the cost of a landscape in the first place…

And then, maybe if you are actually good at understanding just how much the engine sucks, you get 60fps at 4k. maybe.

Okay so you obviously know more than I do, I didn’t even know you can convert landscape to a mesh at the end of development. I’m on my way to finishing my game eventually, so that’s good to know, hopefully I can figure that out on launch. But if I do that, will it keep all my instanced foliage I painted? If not then it’s not viable for an open world game with a static world.

Also what do you mean by procedural foliage instead of grass? Right now I’m painting foliage and using culling at distances for different foliage and it’s fine on the shipped product but it eats the hell out of ram in the editor on launch. Is there some other way? If you’re talking about randomly generated procedural foliage than that’s not an option because I’m making a static map with carefully painted foliage to create a flow and style to each biome.

I’m hoping to get an epic games grant and then use the money to hire someone to do the optimization, specifically with lumen. I’ve already optimized the hell out of all the meshes for foliage and stuff, but unless someone actually knows how to turn down lumen shadow quality, it’s not viable for any good looking game that wants to run 60fps at 1080 or higher.

Last thing here, you said what I said is complete nonsense, so maybe we’re misunderstanding each other. I’ve tested this a million different ways and get the same results every time. Bigger landscapes eat more FPS, the imposters make it more viable than the old days I suppose, but they don’t save infinite performance.

I tested with one directional light in a blank world. The frame rate’s vary frame by frame, but the ranges are very obvious. 511x511 was steady 240fps, 4081x4081 was 210 to 230fps, and 8161x8161 was 190 to 200fps. All of this is on a blank untextured unsculpted landscape. It gets worse if you actually do a ton of complicated stuff with the landscape. All of this was tested by positioning on the corner of each landscape while looking back at the rest of the landscape.

It really doesnt matter.

The landscape is trash so you can’t use it:
You have to figure out how to not use it while keeping what you design.

Physical material can be handled easily by exporting the layer maps and combining them creatively with up to 8 different colors.

Grass has to be procedural or hand painted.

Everything else pretty much doesn’t change.

The world isn’t limited to 1 map tile. If you are limited by this you are either doing it wrong or you don’t understand the engine (and who can blame you really?).

If your perforamnce drops so drastically between map tiles, maybe you ought to consider an hardware upgrade for working; Though it could be a lumen issue with landacapes, a single tile should not hit the gpu at all unless you are on a 1060 or very low end, in spite of the tile size.

Landscapes are made of Components.
Each component is a drawcall.
Your testing means nothing without knowing the amount of drawcalls actually in use.

2x2 components means half drawcalls than 1x1.

More components means more culling accuracy. (Could be significant in some scenarios, but really it isn’t).

Less components means better pefromance in editor.

Landscapes keep all layer textures in memory at all times when displayed. Ergo, more painted layers, less performance.
Impostors have a flattened/2d scene capture generated texture, and a 1 pin material, so they immidiately loose any material complexity.
Optionally, they do come with a normal map, which is useful to do other things like place procedural grass for instance. (I like mixing the imvertex and normalized heightmap into the B so that it can be used for vegetation bands, but then the material has to convert/split the texture correctly).

Grass from the landscape eats performance too. Mostly due to bugs with the culling system which may or may not have since been solved, but as i said. No one uses it professionally anyway.
The grass map system is just another layer of complexity that can be avoided alltogether, Though the model aggregation for culling does work slightly better than procedural or painted foliage, it fumbles on load almost constantly, and tends to get lost when the landscape is physically moved (the actor).
Simple solution. Avoid it. Use the peocedural generation tools, or hand paint the meshes.
(Just keep in mind the trid/vert count as you do).

On that note, grass models should be very low transparency for lod0, and transparent cards for lod2. The transition should happen at around 2m from the camera. Grass is not to cast shadows. Ever.
Grass can also be moved vertically as it gets farther for it to help it disappear (displacement pin). Its really more visual than culling at that point.
The meshes itself should be about 1mx1m as the base, .25m x .25m as clumps to scatter around the edges verticals where the 1m floats in the air.
Ei: quixel assets are trash / only good for cinematics.

Landscape Material
Not that it matters as you wont use it.
Layer height blend is expensive af.
It requires an extra texture, and it is mostly pointless as you won’t even see the ground in most gaming.
Landscape macrotexturing can be expensive depending on the number of textures used.
Layers and the system painting them is expensive and based on textures as well. More layers = more memory usage.
Material complexity gives you a good idea. Should always be in the greenish, sometimes pink on components eith 3 layers of paint.
You should never have more than 3 layers per component.
Distance adjustment of textures shuld happen at the UV level (with banding) as it is way cheaper than fading from high density tiling to low density.

Even with that, and a 3090, this sorry excuse of an engine is incapable of hitting 60fps at 4k native.
So, use cryengine and dont look back…

1 Like