mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2024-12-22 17:27:38 +00:00
Don't crazily initialise HeightMapFilter...??
This commit is contained in:
parent
3e85369765
commit
05bd84b504
@ -56,14 +56,9 @@ public interface HeightMap {
|
||||
layers
|
||||
);
|
||||
if (smooth) {
|
||||
try {
|
||||
HeightMapFilter filter = (HeightMapFilter) HeightMapFilter.class.getConstructors()[0].newInstance(GaussianKernel.class
|
||||
.getConstructors()[0].newInstance(5, 1));
|
||||
int diameter = 2 * size + 1;
|
||||
data[1] = filter.filter(data[1], diameter, diameter);
|
||||
} catch (IllegalAccessException | InvocationTargetException | InstantiationException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
HeightMapFilter filter = new HeightMapFilter(new GaussianKernel(5, 1));
|
||||
int diameter = 2 * size + 1;
|
||||
data[1] = filter.filter(data[1], diameter, diameter);
|
||||
}
|
||||
if (layers) {
|
||||
heightMap.applyLayers(data[1]);
|
||||
|
Loading…
Reference in New Issue
Block a user