blob: 697dc1287612c88739702e11b7311791a5cb8565 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
#pragma once
#include "StarLruCache.hpp"
#include "StarPerlin.hpp"
#include "StarTerrainDatabase.hpp"
namespace Star {
struct IslandColumn {
float topLevel;
float bottomLevel;
};
struct IslandSurfaceSelector : TerrainSelector {
static char const* const Name;
IslandSurfaceSelector(Json const& config, TerrainSelectorParameters const& parameters);
float get(int x, int y) const override;
IslandColumn generateColumn(int x) const;
mutable HashLruCache<int, IslandColumn> columnCache;
PerlinF islandHeight;
PerlinF islandDepth;
PerlinF islandDecision;
float islandTaperPoint;
float islandElevation;
float layerBaseHeight;
int worldWidth;
};
}
|