Terrain Texture Generation

cover

3 min read

Intro

This texturing workflow expands on the previous work of creating a custom terrain solver. Here I will outline my general strategy to create proper UV coordinates for and asset with over 4M triangles. Afterwards, I will cover the generation of a pigmentation map used to build an albedo map. As a last step I will cover how the use of masks to automate some parts of the texturing process using Houdini and Marmoset. The idea is to prepare the model and deliver the asset to an artist so they can continue the texturing process.

features development with erosion

Texture Mapping Coordinates Strategy

There is already software specialized1 in the creation of UV coordinates for meshes with a high polygon count. But for the sake of reducing complexity I am doing as much work inside Houdini. To handle the creation of the UVs on these meshes my strategy consists of:

  1. Poly reduce geometry preserving the most important features, masking areas of high curvature for detail preservation 2
  2. Create UVs using clusters and a breadth search to cover the entire surface, using clusters
  3. Transfer UVs to the original high resolution geometry
  4. Bake all the maps and masks created by the terrain solver
  5. Export to Marmoset/Substance using a custom python script
uvs strategy

In the image above an operator distributes a number of points over the surface of the mesh, the user can paint or manipulate the boundaries of the uv shell to get an approximated shape, after a solver expands the boundaries of the each shell, this search is made over a low resolution mesh. Finally the uvs are created and transferred to the high resolution mesh.

Problem

Using plain masks and triplanar shaders is a starting point, but the result can become repetitive. Here is a test of just using one material input without any pigmentation or color variation on top of the projected material.

features development with erosion

Masks and Strokes

Taking advantage of the extra data generated by the terrain solver, a color map is generated to enhance the albedo texture.

features development with erosion

In this example strokes are generated following the direction of the erosion map, afterwards they are clustered by color variation and rasterized into a single texture map.

features development with erosion features development with erosion

Other Technical Bits

Copernicus and Texture Blending

As an example for a more photorealistic asset I created 5 triplanar mapped materials. The textures for these materials were re-mixed using content from FAB/Bridge. The process consist of blending two height maps and using the result as a mask to blend all the other channels, like: albedo, specular, etc…

The blending of the was done using Copernicus with a custom but simple OpenCL node

features development with erosion

To avoid manually exporting each map manually a basic TOP network was used to automate the process

Footnotes

Footnotes

  1. Rizomuv-vs

  2. The geometry is decimated using a procedure similar to Embark’s one click photogrammetry tool

Published: Jan 31 2025
Updated: Feb 13 2025