Language:
Page Info
Skill Level:
Engine Version:

2. Required Asset Creation & Setup

Before we can create the Height Field Painter Blueprint, we will need to create and setup the following asset types inside of the UE4 Content Browser. In the following sections, we will go over how each of the assets needs to be setup as well as any special properties that you will need to be aware of.

Please note that the following is not specific to any UE4 project type. The following can be accomplished in any project that uses UE4 version 4.13 or later.

  • Render Target

  • Material

  • Blueprint (Based off Actor)

Render Target Creation & Setup

  1. Right-click inside of the Content Browser and from the displayed menu, go to Create Advanced Asset > Materials & Textures and then select the Render Target option.

    HFP_RT_Creation_00.png

  2. Name the newly created Render Target, RT_Height_Filed_Painter, and then press the Save All button to save your work.

    HFP_RT_Creation_01.png

Material Creation & Setup

  1. Right-click inside of the Content Browser and from the Create Basic Asset list, select the Material option to create a new Material, naming it MAT_HeighfieldPainter.

    HFP_Material_Creation_00.png

  2. Select the MAT_HeightfieldPainter Material in the Content Browser and then right-click on it. From the displayed menu, under the Common section, select the Duplicate option to create a copy of the Material, naming it MAT_ForceSplat.

    HFP_Material_Creation_01.png

  3. Double-click on the MAT_HeighfieldPainter Material to open it up and then select the Main Material Node. In the Details panel under the Material section, setup the following parameters.

    • Shading Model: Unlit

    HFP_Material_Creation_04.png

  4. The MAT_HeighfieldPainter Material is going to use the World Position Offset input to increase the Z-height of the Static Mesh vertices it is applied to. You can copy it into your Material by hovering your mouse over the image below and then clicking on the Copy Expression Graph option, copying-and-pasting the provided Material code into MAT_HeighfieldPainter.

    Copy Expression Graph

    HFP_Material_Creation_05.png

    Do not forget to Apply and Save your Material so that it can be used.

  5. Open up the MAT_ForceSplat Material and then select the Main Material Node. In the Details panel under the Material section set up the following parameters.

    • Blend Mode: Additive

    • Shading Model: Unlit

    • Allow Negative Emissive Color: Checked

    HFP_Material_Creation_02.png

  6. Since the MAT_ForceSplat Material is going to act as our paint brush for raising the surface of our height field, it will need to have a few options that will allow you to control its size and intensity. You can copy the completed Material into your Material by hovering your mouse over the image below and then clicking on the Copy Expression Graph option, copying-and-pasting the provided Material code into MAT_ForceSplat.

    Copy Expression Graph

    HFP_Material_Creation_03.png

    Do not forget to Apply and Save your Material when done so that it can be used.

With the required assets now setup, in the next section, we will take a look at creating a Blueprint that will link all of the assets together to create the height map painter.