Houdini 20.5 Unreal Landscapes

Generate a Landscape from Houdini

Workflow to generate a landscape in Houdini and import it into Unreal

On this page

This workflow covers how to setup a landscape in Houdini and then import it into Unreal. This example creates a mountain landscape with cliffs

A few key things you will learn in this workflow:

Create basic landscape

  1. Create a Geometry SOP and enter it to work in the Surface Operator network view.

  2. Create a Subnetwork SOP and name it Landscape_Generation. Double-click the node to work in the folder.

  3. Create a Heightfield SOP node.

  4. Select the Heightfield SOP node, turn on its Display flag, and then open the Parameter Editor.

  5. In the Parameter Editor, change the Initial Mask parameter to 1.

    • This allows you to use the entire landscape as a mask to apply things such as a base material.

  6. Create a Heightfield Copy Layer SOP and connect the input to the output of the Heightfield SOP node.

  7. In the Heightfield Copy Layer SOP node’s parameters, enter base in the Destination parameter.

    • You use this layer later to create a base material in Unreal engine.

  8. Create a Heightfield Noise SOP and connect the input1 to the output of the Heightfield Copy Layer SOP node.

  9. In the Heightfield Noise SOP node’s parameters, do the following:

    • In the Amplitude parameter, enter 250.

    • In Element Size, enter 800.

    • In Noise Type, change the dropdown menu to Perlin Flow.

    • In Max Octaves, enter 3.5.

    • This creates a landscape with slight angulation and variation.

Use masks to create cliffs

  1. Create a Heightfield Mask by Feature SOP and connect the input to the output of the Heightfield Noise SOP node.

  2. In the Heightfield Mask by Feature SOP node’s parameters, do the following:

    • In the Min Slop Angle parameter, enter 15.

    • In Max Slope Angle , enter 90.

    • This mask helps to generate the cliffs and ridges for the landscape.

  3. Create a Heightfield Terrace SOP and connect the input1 and input2 to the output of the Heightfield Mask by Feature SOP node.

  4. In the Heightfield Terrace SOP node’s parameters, do the following:

    • In Min Height , enter -50.

    • In Fade , enter 0.5.

    • In Max Step Size , enter 15.

  5. Create a Heightfield Layer Clear SOP and connect the input to the output of the Heightfield Terrace SOP node.

    • This clears your mask selection.

  6. Create a Heightfield Flow Field SOP and connect the input to the output of the Heightfield Layer Clear SOP node.

  7. In the Heightfield Flow Field SOP node’s parameters, do the following:

    • In Rain Amount , enter 0.5.

    • In Rain Density , enter 0.25.

    • In Smoothing Iterations , enter 20.

    • In Adjust Height , turn on the checkbox aNd enter 0.3.

You now have a landscape with layered cliffs and erosion.

Create a mask for erosion

  1. Create a Mask by Feature SOP and connect the input to the output of the Heightfield Flow Field SOP node.

  2. In the Heightfield Mask by Feature SOP node’s parameters, do the following:

    • Turn on Invert Mask.

    • Turn on Mask by Occlusion.

    • In Minimum Occlusion , enter 0.75.

    • In Maximum Occlusion , enter 0.9.

  3. Create a Heightfield Copy Layer SOP and connect the input to the output of the Heightfield Mask by Feature node.

  4. In the Heightfield Copy Layer SOP node’s parameters, enter erosion in the Destination parameter.

  5. Create a Heightfield Layer Clear SOP and connect the input to the output of the Heightfield Copy Layer SOP node.

    • This clears your mask selection.

Clean up layers (optional)

In Houdini, heightfields on the primitive attribute called name will use the string as landscape layers in Unreal Engine. You may want to clean up these attributes to keep your HDA more organized.

  1. Select the Heightfield Flow Field SOP.

  2. In the Geometry Spreadsheet tab, select the primitives.

    • You can see a list of attribute names that were created during the workflow.

    Note

    You must export the height name attribute for Houdini Engine to properly transfer the heightfield to Unreal Engine.

  3. Create a Blast SOP and connect the input to the output of the Heightfield Copy By Layer SOP node.

  4. In the Blast SOP node’s parameters, on the Group parameter, enter @name=cliff @name=flowdir.x @name=flowdir.y @name=flowdir.z @name=mesa @name=water @name=flow.

    • This removes the unwanted attribute names and Unreal Engine won’t read those layers.

Note

Make sure you do not delete the mask name attribute. This prevents the heightfield nodes to function properly.

Visualize layers (optional)

You may want to visualize which layers are visible using a Heightfield Visualize SOP before exporting it to Unreal Engine.

Note

The layers and colors setup in any Heightfield SOPs do not get exported and transferred into Unreal materials. They are purely for visualization within Houdini.

  1. Create a Heightfield Visualize SOP and connect the input to the output of the Blast node.

  2. In the Heightfield Visualize SOP node’s parameters, do the following:

    • In Layer 9, select erosion from the dropdown menu. Change the color to orange.

    • In Layer 8, select base from the dropdown menu. Change the color to green.

You can see the different layers and how it affects the landscape.

  • The erosion layer is set when creating the mask erosion.

  • The base layer selects the entire landscape.

You can now delete the Heightfield Visualize SOP node.

Create the Unreal material

You can assign existing materials from Unreal to your generated landscape by adding unreal_material onto the Prim. You can then source your Unreal material path as a string and assign it to your HDA.

See Materials for more information.

Setup material in Unreal

  1. In Unreal, create new material and name it Landscape_Material.

  2. In the material graph, click ⇥ Tab and create two Constant3Vector.

    1. Change the color to orange for the first constant.

    2. Change the color to green for the second constant.

  3. Click ⇥ Tab and create a LandscapeLayerBlend.

    1. In the details panel, select the + symbol next to Layers to add two Array elements.

    2. In Index 0, expand the dropdown tab and change the name to erosion.

      • Change the Blend Type to LB Alpha Blend.

    3. In Index 1, change the name to base.

      • Change the Blend Type to LB Alpha Blend.

  4. Connect the Orange Constant color white output to the Layer erosion input.

    1. Connect the Green Constant color white output to the Layer Base input.

    2. Connect the Landscape Layer Blend output to the Emissive Color input.

  5. In the content drawer, the Landscape_Material and select Copy Reference.

    • You will need this later to paste into your Attribute Create SOP.

Setup material in Houdini

  1. In Houdini, create a Attribute Create SOP and connect the input to the output of the Blast SOP node.

  2. In the Attribute Create SOP node’s parameters, do the following:

    • In Name, enter unreal_material.

    • In Class, select Primitive.

    • In Type, select String.

    • In String, paste your Unreal material path.

  3. In Houdini, create a Output Geometry SOP and connect the input to the output of the Attribute Create SOP node.

You are now finished your Houdini setup and ready to export into an HDA.

Export settings for HDA

  1. Step out into Geometry view, the Landscape_Generation subnetwork and select Create Digital Asset.

  2. In the pop-up window, change the Asset Label name to Landscape Generation.

    • You can change the other settings to your preference.

  3. In the Edit Operator Type Properties pop-up window, locate the Existing Parameters tab.

    • You can expose parameters from your Heightfield SOP nodes to change them in Unreal Engine.

  4. In your Heightfield SOP, drag the Grid Samples parameter into the Existing Parameters tab.

    1. Do the same for the Heightfield Noise SOP, drag the Amplitude and Element Size parameter.

    • You should now see the three parameters added.

  5. Select Acccept.

Import into Unreal

Make sure you have a Houdini Engine for Unreal session running. See Session for more information.

  1. In Unreal, import the Landscape_Generation HDA.

  2. the HDA and select Instantiate at the origin.

Your landscape is now generated in Unreal with the proper materials assigned.

You can also see the exposed parameters in the Houdini Parameters section of the details panel to further edit your landscape within Unreal Engine.

See also

Landscapes

Getting Started

Landscape Splines

Workflow

Landscapes allows you to create and manipulate terrain and natural environments in Houdini using its procedural node-based workflow. You can then bring them into Unreal Engine to further edit, render, and bake them. The landscapes generated in Houdini can be highly detailed and dynamic to create complex terrains.

Features and capabilities

  • Use Houdini Heightfield tools to simulate erosions such as Hydro, Thermal, Flow, and more

This video shows a few landscape features used by Far Cry 5 using Houdini:

  • Houdini Engine for Unreal reads landscapes as a heightfield, points, or mesh

  • Create landscape layers, create textures, and material generation

  • Take landscapes from Unreal and use Houdini Engine to convert it into a static mesh

  • Houdini’s scattering capabilities

  • Use PDG to split up large worlds into smaller sizes for faster simulations and help with team collaboration

  • Landscapes exposes the inputs and outputs to seamlessly communicate between other HDAs

    • An example is you can use a river tool controlled by a curve. The landscape can influence the curve to guide its path while the river tool causes erosion to the landscape.

Associated information

Here are some nodes and concepts you may need to understand before creating landscapes: