public class HeightMap
extends java.lang.Object
Currently only used for smoothing (with a GaussianKernel)
.Constructor and Description |
---|
HeightMap(EditSession session,
Region region,
Mask mask)
Constructs the HeightMap.
|
Modifier and Type | Method and Description |
---|---|
int |
apply(int[] data)
Apply a raw heightmap to the region.
|
int |
applyFilter(HeightMapFilter filter,
int iterations)
Apply the filter 'iterations' amount times.
|
public HeightMap(EditSession session, Region region, @Nullable Mask mask)
session
- an edit sessionregion
- the regionpublic int applyFilter(HeightMapFilter filter, int iterations) throws MaxChangedBlocksException
filter
- the filteriterations
- the number of iterationsMaxChangedBlocksException
- if the maximum block change limit is exceededpublic int apply(int[] data) throws MaxChangedBlocksException
data
- the dataMaxChangedBlocksException
- if the maximum block change limit is exceeded