Language:
Page Info
Tags:
Engine Version:

Material Inputs

Choose your OS:

Here we take a look at the available inputs when making a Material. By feeding values (by way of constants, parameters, and textures) into these inputs, you can define just about any physical surface you can imagine.

Not all inputs are used with every combination of Blend Mode and Shading Model. As such, we will designate when each input is available for use, so that you know which inputs are used with each type of Material you create.

Inputs and Material Settings

Not all inputs will be useful for every type of Material you create. For instance, when developing a Light Function - a Material that is applied to a light - you can only use the Emissive Color input on the material and nothing else, since other inputs, such as Metallic or Roughness, would not be applicable. Because of this, it is important to know what type of Material you are creating before you start worrying too much about inputs. The three primary controlling properties in this are:

  • Blend Mode - This controls how your Material will blend in with the pixels behind it.

  • Shading Model - This defines how light is calculated for the surface of the Material.

  • Material Domain - This controls how the Material is intended to be used, such as whether it is meant to be part of a surface, a Light Function, or a Post Process Material.

Fortunately, Unreal Engine 4 removes the guess work for which inputs you need for a given type of Material. As you change these settings in the Material, you will notice that your available inputs will update, and inputs that you do not need will be disabled.

Base Color

Base Color simply defines the overall color of the Material. It takes in a Vector3 (RGB) value and each channel is automatically clamped between 0 and 1.

If taken from the real world, this is the color when photographed using a polarizing filter (polarization removes the specular of nonmetals when aligned).

BaseColor_QS.png

Metallic

The Metallic input literally controls how "metal-like" your surface will be. Nonmetals have Metallic values of 0, metals have Metallic values of 1. For pure surfaces, such as pure metal, pure stone, pure plastic, etc. this value will be 0 or 1, not anything in between. When creating hybrid surfaces like corroded, dusty, or rusty metals, you may find that you need some value between 0 and 1.

Metallic_21.png

Specular

The Specular input should not be connected and left as its default value of 0.5 for most cases.

It is value between 0 and 1 and is used to scale the current amount of specularity on non-metallic surfaces. It has no effect on metals.

Specular_21.png

Roughness

The Roughness input literally controls how rough the Material is. A rough Material will scatter reflected light in more directions than a smooth Material. This can be seen in how blurry or sharp the reflection is or in how broad or tight the specular highlight is. Roughness of 0 (smooth) is a mirror reflection and roughness of 1 (rough) is completely matte or diffuse.

Roughness is a property that will frequently be mapped on your objects in order to add the most physical variation to the surface.

Click for full size

Emissive Color

The Emissive Color input controls which parts of your Material will appear to glow because they are emitting light. Ideally, this will receive a masked texture (mostly black except in the areas that need to glow).

Values greater than 1 are allowed as HDR lighting is supported.

Click for full size

Opacity

The Opacity input is used when using the Translucent Blend Mode . It allows you to input a value between 0 and 1 where:

  • 0.0 represents completely transparent.

  • 1.0 represents fully opaque.

Opaque and masked blend modes also use Opacity when using one of the subsurface shading models.

Click for full size

Opacity is mostly used for Translucent, Additive, and Modulated Materials.

Opacity Mask

Opacity Mask is similar to Opacity, but is only available when using the Masked Blend Mode. As with Opacity, this takes in a value between 0.0 and 1.0, but unlike Opacity, varying shades of gray are not seen in the result. When in Masked mode, a Material is either completely visible or completely invisible. This makes it a perfect solution when you need Materials that define complex solid surfaces such as wire mesh, chain link fences, and so on. The opaque portions will still respect lighting.

You can use the Opacity Mask Clip Value property on the base Material node to control the point where clipping takes place. See the Masked Blend Mode documentation for more details.

Click for full size

Normal

The Normal input takes in a normal map, which is used to provide significant physical detail to the surface by perturbing the "normal," or facing direction, of each individual pixel.

Axes.png

In the image above, both weapons are using the same Static Mesh. The lower one exhibits a highly detailed normal map, which provides tremendous additional detail and gives the illusion that the surface contains many more polygons than are actually being rendered. Such normal maps are often created from high-resolution modeling packages, such as Pixologic ZBrush.

NormalNetwork.png

World Position Offset

The World Position Offset input allows for the vertices of a mesh to be manipulated in world space by the Material. This is useful for making objects move, change shape, rotate, and a variety of other effects. This is useful for things like ambient animation.

Click for full size

The above network will cause your object to simultaneously spiral and wave up and down, like it is dancing!

When using World Position Offset to expand your object beyond its original bounds, keep in mind that the renderer still uses those original bounds. This means that you may see culling and shadowing errors. You may go into the properties of a mesh and set its Scale Bounds property to compensate, though this has a draw on performance and may lead to shadowing errors.

World Displacement & Tessellation Multiplier

World Displacement works very much like World Position Offset, but it uses Tessellation vertices rather than the base vertices of the mesh. In order for this to be enabled, the Tessellation property on the Material must be set to something other than None.

Tessellation Multiplier controls the amount tessellation along the surface, allowing more detail to be added where needed. As with World Displacement, for this to be enabled, the Tessellation property must be set to something other than None.

Click for full size

When using World Displacement to expand your object beyond its original bounds, keep in mind that the renderer still uses those original bounds. This means that you may see culling and shadowing errors. You may go into the properties of a mesh and set its Scale Bounds property to compensate, though this has a draw on performance and may lead to shadowing errors.

Subsurface Color

The Subsurface Color input is only enabled when the Shading Model property is set to Subsurface. This input allows you to add a color to your Material to simulate shifts in color when light passes through the surface. For instance, human characters might have a red subsurface color on their skin to simulate the blood beneath its surface.

Click for full size

Ambient Occlusion

Ambient Occlusion is used to help simulate the self-shadowing that happens within crevices of a surface. Generally, this input will be connected to an AO map of some type, which is often created within 3D modeling packages such as Maya, 3ds Max, or ZBrush.

NormalNetwork.png

Refraction

The Refraction input takes in a texture or value that simulates the index of refraction of the surface. This is useful for things like glass and water, which refract light that passes through them.

Click for full size

Common Indices of Refraction

Air

1.00

Water

1.33

Ice

1.31

Glass

1.52

Diamond

2.42

Clear Coat

The Clear Coat Shading Model can be used to better simulate multilayer materials that have a thin translucent layer of film over the surface of the Material. In addition to this, the Clear Coat Shading Model can also be used with either metal or nonmetal surfaces. In fact, it was specifically designed to model this second class of smooth colored films over a non-colored metal. Some examples of Clear Coat Materials include acrylic or lacquer clear coats, and colored films over metals such as soda cans or car paint.

Clearcoat.png

The Clear Coat Shading Model opens up two new Material inputs on the Main Material node.

Clear Coat: Amount of clear coat layer, 0 acts like the standard shading model, 1 is the full clear coat model. This is useful for masking.

Clear Coat Roughness: Roughness for the clear coat layer. Our approximation is accurate for small values. Very rough clear coat layers are supported but will not be very accurate compared to their real world counterparts.

Tags