The Layercake Tutorial



Layercake

Layercake is a small library to generate low-poly terrain. The terrain is divided into patches with a triangular base. Patches are defined by their three vertices and can be generated and replaced independently from each other.

Two patches of terrain

This tutorial walks you through the concepts behind Layercake and its implementation. This is still work-in-progress.

Tutorial

Gradient noise

1. Gradient noise

An introduction to gradient noise functions. Covers the generation of curves, noise textures, and noise volumes. Includes an overview of Layercake’s implementation.

The Blueprint

2. The blueprint

The blueprint is a helper construction that is used by Layercake to build its triangular patches of terrain. The focus of this chapter lies on the blueprint’s influence weights that help with generating seamless patches of terrain.

Seamless heightmaps

3. Seamless heightmaps

This chapter describes how to use the gradient noise functions and the blueprint from the previous chapters to generate simple seamless heightmaps constructed from triangular patches.

Appendix

Source code

1. Source code

Information on the Git repository, the source code, and its license. Includes a short guide how to set up the project.

Math package

2. The math package

Information on Layercake’s rudimentary math package and its design.