Beispiel #1
0
        public ClampedSimplexNoise(double[] amplitudes, double[] frequencies, long seed)
        {
            this.amplitudes  = amplitudes;
            this.frequencies = frequencies;
            this.seed        = seed;

            octaves = new SimplexNoiseOctave[amplitudes.Length];

            for (int i = 0; i < octaves.Length; i++)
            {
                octaves[i] = new SimplexNoiseOctave(seed * 65599 + i);
            }
        }
Beispiel #2
0
        public NormalizedSimplexNoise(double[] inputAmplitudes, double[] frequencies, long seed)
        {
            this.frequencies     = frequencies;
            this.inputAmplitudes = inputAmplitudes;

            octaves = new SimplexNoiseOctave[inputAmplitudes.Length];
            for (int i = 0; i < octaves.Length; i++)
            {
                octaves[i] = new SimplexNoiseOctave(seed * 65599 + i);
            }

            CalculateAmplitudes(inputAmplitudes);
        }