FFT Terrain
Terrain shading and player-centred runtime streaming for a procedural FFT landscape.
Terrain Shading & Runtime Optimisation
This chapter develops the FFT-generated height data into a complete terrain system. It focuses on two connected problems: building a material that responds to procedural geometry and maintaining a continuous landscape around the player without generating an unlimited number of terrain meshes.
Terrain Shading Pipeline
Height Mask
The generated elevation data is converted into masks that separate the terrain into height-dependent regions. These masks provide the foundation for assigning and blending different surface treatments.
Vertex Colour
Vertex colour stores additional surface information directly on the procedural mesh, allowing the material to respond to local terrain features and blend layers without relying on a unique texture for every tile.
Final Material
The final Unreal Engine material combines the height mask and vertex colour with world-aligned textures and procedural noise. Height-based blending establishes the main surface regions, while noise introduces smaller variations and reduces visible repetition across adjacent terrain tiles.
The pipeline moves through three stages:
- Generate the height mask from procedural elevation data.
- Encode surface information through vertex colour.
- Assemble the final material using layered, world-aligned blending.
Player-Centred Tiles
The landscape is divided into a bounded set of reusable tiles positioned around the player. The central area represents the currently active terrain, while tiles outside the required range can be recycled for new positions.
This approach allows the visible landscape to follow player movement while avoiding the cost of permanently retaining every generated tile.

Runtime Update Flow
- Detect player movement — check whether the player has crossed the update threshold.
- Determine the tile ring — calculate which surrounding terrain positions are required.
- Generate or reuse tiles — create missing terrain or reposition an available recycled tile.
- Recycle distant tiles — return tiles outside the active region to the reusable pool.
Active Tiles
Tiles within the player-centred region remain visible and continue to form the playable landscape.
Recycled Tiles
Distant tiles are retained as reusable objects, then moved and regenerated when the player requires terrain in a new direction.
Performance Strategy
The runtime system concentrates generation work near the player and reuses existing terrain objects wherever possible. Its performance evaluation is structured around comparing repeated creation with tile reuse, including the cost of generation, updates, and the number of active terrain pieces.
Project Highlights
- Data-Driven Shading: Procedural height and vertex data directly control the terrain’s visual treatment.
- World-Aligned Material: Layered textures remain consistent across separately generated tiles.
- Bounded Tile Set: The landscape expands around the player through reuse instead of unlimited mesh accumulation.
- Clear Runtime Lifecycle: Detection, tile selection, generation, and recycling are handled as distinct update stages.