top of page

LANDSCAPE AUTO MATERIAL HOW TO USE

Setup

1. Add Landscape Auto Material package to your project

2. Duplicate the master material instance Landscape_Automaterial_Inst from Content / LandscapeAutoMaterial / Materials / LandscapeAutoMaterial

3. Apply a copy of instance to your Landscape actor in the Level

4. Set up a GlobalScale parameter in a material instance suitable for your landscape size

5. If you want to use additional weighted-blended layers: paint all the landscape using layer "Auto". Nothing seems happened but it is difficult for proper weighted-blend working

6. Done!

 

Texture preferences

You can enable or disable various texture inputs (albedo, roughness,heightmask etc), and link texture references you want.

Attention: When you are switching boolean parameters in the master material shader, compilation will be started. It is strongly recommended to switch boolean parameters in the empty scene to avoid an excessive shader recompilation.

01 Planar

The basic parameters that are the same for any other material layer

 

 

Automatic Grass parameters.

By default auto-grass meshes are generating on "Planar" material layer. See "Advanced Customization" if you want to generate auto-grass meshes on differrent additional layer.

Attention: Any changes of auto-grass parameters in master material instance do not updates automaticaly in viewport. After parameters change you are have to modify any of your GrassType object in scene. For example check and uncheck a "Grid" parameter checkbox.

It is because of bug in UE4 - parameters linked with LandscapeGrassOutput are not visible in material instance and there is workaraound in material structure.

Types of landscape layers

All basic materials are weight-blended layers.

Only overlay layers like coloring, caustics and foliage eraser layers are non weight-blended. So if you will paint a weight-blended layer on the top of non-weight-blended layer, non-weight-blended layer still exists. And to clean non-weight-blended layer you have to clean painting of that layer using click+shift erasing painting.

 

Automatic grass meshes

You can set up auto-grass meshes in next GrassType objects:

 

Default grass (black color in splat mask):

LandscapeGrassType'/Game/LandscapeAutoMaterial/Meshes/Grass/Grass_01.Grass_01'

 

Small formations (blue color in splat mask):

LandscapeGrassType'/Game/LandscapeAutoMaterial/Meshes/Grass/Grass_02.Grass_02'

 

Medium formations (yellow color in splat mask):

LandscapeGrassType'/Game/LandscapeAutoMaterial/Meshes/Bushes/Bushes_01.Bushes_01'

 

Big formations (red color in splat mask)

LandscapeGrassType'/Game/LandscapeAutoMaterial/Meshes/Stones/Stones_01.Stones_01'

 

Splatmask: Texture2D'/Game/LandscapeAutoMaterial/Textures/Generic/SplatterMask_D.SplatterMask_D'

 

Currently you can't set up grass output actors dirrectly in master material instance, because of UE4 doesn't implemented this functional.

You can modify copy of the master material and set up different Landscape Grass Types in Grass Output Node:

Water caustics

A non-weight-blended overlay layer. Imitates a water caustics on landscape.

Optimization

You can use next schemes to boost your FPS:

1. Turn off Tessellation in the Master Material

(tesellation will hit your performance in huge landscapes)

LandscapeAutoMaterial/Materials/LandscapeAutoMaterial/Landscape_Automaterial_M

 

2. Set up "LODDistance Factor" in landscape preferences suitable for you - for example this parameter equals to 2.5 with Square Root in LOD Falloff in Fly-by scene.

3. Turn cast shadows off to all 3-lod for grass meshes

4. Tweak grass lod distances (Screen size parameter) to compromise quality \ performance

Also you can turn off 2-lod shadows for different grass and set up higher lod distance for 1st lod

5. Set up lower grass density in Grass Type settings for grass and bushes

6. Set up Start and End cull distance for grass more efficiently

7. You can disable unused additional layers in the master material instance:

00 SETUP \ Layer_N_Enabled = false

8. You can decrease a multiplier of automatic-grass generation density in the master material instance:

00 SETUP \ Planar_Foliage_Generation_Density = 0.5 (default = 1)

Advanced parameters

Extra-details customization of blending and tesellation parameters.

Limitations

1. In case of SM5 (PC, Consoles) you can use up to 128 textures in your landscape material. In case of SM3 you can use maximum 16 textures. You can optimize some channels from different textures per channel to the one texture and decrease texture samplers in the shader.

If you are using for the sample MAC system (non-SM5) you need to decrease used textures in material to 16.

You need to turn off some MaterialLayers in Landscape_Automaterial_Inst/ Just

Turn off next checkboxes and the shader will compiled successfully:

 

00 SETUP:

Layer1_Enabled

Layer2_Enabled

Layer3_Enabled

 

02 Slope:

Slopes_Use_HeightVariation

 

2. Landscape grass output (autogenerated grass) available only for Dynamic Light setup (like in Epic Kite Demo). To switch ON force dynamic light in your project you need to turn off "Allow static lighting" checkbox in project settings.

 

3. Unfortunately UE4 Landscape Output can't generate collision for grass meshes due to performance issues. You can workaround it issue placing unique collision for huge geometry by the handle.

Common parameters

All parameters are sorted as groups in Master-material Landscape_Automaterial_Inst.

 

00 SETUP

Якорь 2
Якорь 3
Якорь 4
Якорь 5
Якорь 6
Якорь 7
Якорь 8
Якорь 9
Якорь 10
bottom of page