TerrainSculptSettings
Settings for TerrainEditUtility.SculptHeights.
Read time 1 minuteLast updated 22 days ago
Definition
- Type: Class
- Namespace: UnityEditor.TerrainTools
- Assembly: UnityEditor
public sealed class TerrainSculptSettings
Remarks
Heights and distances are in meters. Heights are measured above the base of the Terrain, from 0 to TerrainData.size.y.
Constructors
Constructor | Description |
|---|---|
| TerrainSculptSettings(UnityEditor.TerrainTools.TerrainSculptOperation) | Creates settings for an operation, with no falloff and no blend. |
Properties
Property | Description |
|---|---|
| amount | How far to raise or lower for TerrainSculptOperation.Raise and TerrainSculptOperation.Lower. Must be greater than zero for those operations. |
| blendDistance | The distance outside the region over which the change eases back to the untouched ground. Nothing farther than this from the region changes. Cannot be combined with TerrainSculptSettings.falloff, and must not exceed the diagonal of the Terrain. |
| falloff | The fraction of the region, from 0 to 1, over which the change fades at its edge. See TerrainRegion.GetWeight. Cannot be combined with TerrainSculptSettings.blendDistance. |
| flattenReference | For TerrainSculptOperation.Flatten: which height of the region to flatten to. The samples inside the region decide it, without the blend band and regardless of the falloff. TerrainFlattenReference.Mean by default. |
| height | The target height for TerrainSculptOperation.Set. NaN by default. Raise, Lower and Smooth ignore it; Flatten requires it to be NaN, since it takes its height from the region. |
| operation | How to change the heights. |
| smoothRadius | The averaging radius for TerrainSculptOperation.Smooth. 0 uses two heightmap cells. Must not exceed the diagonal of the Terrain. |