Tried out this fractal terrain stuff but it just looks the same i guess?
This commit is contained in:
@ -11,7 +11,7 @@ class PerlinTerrainNode : public TerrainNode
|
||||
public:
|
||||
PerlinTerrainNode(wstring name, wstring seed, float chunkSize, int widthX = 1023, int widthZ = 1023, float waterHeight = 300.0f, int cellSizeX = 10, int cellSizeZ = 10);
|
||||
|
||||
private:
|
||||
protected:
|
||||
// the static perlin permutation array, we could calculate a random one but apparently you can run into sequencing issues and this just seems like the best solution
|
||||
vector<unsigned char> _staticP = { 151,160,137,91,90,15,
|
||||
131,13,201,95,96,53,194,233,7,225,140,36,103,30,69,142,8,99,37,240,21,10,23,
|
||||
@ -45,6 +45,8 @@ private:
|
||||
|
||||
float _chunkSize;
|
||||
|
||||
std::mt19937 _generator;
|
||||
|
||||
float Fade(float t);
|
||||
float Grad(int hash, float x, float y);
|
||||
|
||||
|
Reference in New Issue
Block a user