394 Game Development and Simulation with Unreal Technology
You should h ave noticed that we lef t th e landscape mater ia l empty when we created
our landscapes in Tutorials 7.1 and 7.2.
In the following section we will discuss La ndscape Materials [28] and Landscape
specific Ma terial Expressions [26]. A more compreh ensive list and descriptions of
functionalities may be found on the Unreal Engine documentation Website
2
.
CROSS-REFERENCE
To learn more Unreal Engine 4’s Materials and Mater ia l Editor, check out
Chapter 4 and Section 4.3 on page 127.
7.3 LANDSCAPE MATERIALS
Although you can use any material as a landscape material, Unreal Engine 4 allows
for much more complex and specialize material systems to be used in tandem with
landscapes. These specialized materials give you a tremendous amou nt of control and
flexibility in texturing Landscapes in UE4. We will take a look at what is so special
about Landscape Materials, learn how we can utilize them in our landscapes, and
how the rendering engine in UE4 provides specific functiona lities to these materials.
7.3.1 HOW LANDSCAPE MATERIALS BLEND
In UE4, the rendering mechanism uses a weight blending approach in combinin g
landscape materials, as opposed to alpha blending. The blending values f or all of the
layers involved with a landscape material at any given lo cation will be n ormalized
–i.e., they add up to 1.0.
There are advantage and disadvantages to this approach. T he advantage is that you
will have the flexibility to paint any layer on any location in the landscape. As you
add more and more of that layer, its weight increases wh ile simultaneously decreas-
ing the weights of the other layers.
This comes at a cost. If you have a layer at 100% weight – e.g., the first layer you
paint, you may not be able to remove it. This is b ecause when a layer is at 100%
weight, normalization forces the weight of all the other layers to be 0. When attem pt-
ing to remove this layer, UE4 will not have a mechanism to know which layer you
want it to be replaced with.
7.3.2 LANDSCAPE MATERIAL EXPRESSIONS
Landscape material expressions are those expressions that allow you to design land-
scape specific functionalities for the materials to be used as a landscape material.
2
https://docs.unrealengine.com/latest/INT/Engine/Rendering/Materials/
ExpressionReference/index.html