# GatherHeightmap()

> Gathers the heightmap information into sourceRenderTexture.

## Definition

* **Type:** Method
* **Namespace:** [UnityEngine.TerrainTools](/engine/6000.6/script-reference/unityengine/terraintools.md)
* **Assembly:** UnityEngine.TerrainModule

```csharp
public void GatherHeightmap()
```

### Remarks

This function collects the heightmap data from all Terrain tiles in the PaintContext into `sourceRenderTexture`.

This function is called internally by [TerrainPaintUtility.BeginPaintHeightmap](/engine/6000.6/script-reference/unityengine/terraintools/terrainpaintutility/beginpaintheightmap.md).

Additional Resources: [PaintContext.ScatterHeightmap](/engine/6000.6/script-reference/unityengine/terraintools/paintcontext/scatterheightmap.md).
