$ sudo install -o redis -g redis -d /var/lib/redis2
$ sudo cp -p /etc/redis/redis.conf /etc/redis/redis2.conf
| public class Perlin { | |
| public int repeat; | |
| public Perlin(int repeat = -1) { | |
| this.repeat = repeat; | |
| } | |
| public double OctavePerlin(double x, double y, double z, int octaves, double persistence) { | |
| double total = 0; |
| // Ported from Stefan Gustavson's java implementation | |
| // http://staffwww.itn.liu.se/~stegu/simplexnoise/simplexnoise.pdf | |
| // Read Stefan's excellent paper for details on how this code works. | |
| // | |
| // Sean McCullough banksean@gmail.com | |
| /** | |
| * You can pass in a random number generator object if you like. | |
| * It is assumed to have a random() method. | |
| */ |