A fluent functional 3-dimensional Perlin noise generator based on p5.js Perlin noise implementation
npm i -S perlin-fp
# with yarn
# yarn add perlin-fp
const perlinNoise = require('perlin-fp');
const { getNoiseByCoordinate } = perlinNoise();
const [x, y, z] = [0, 0, 0];
getNoiseByCoordinate(x, y, z);
// -> 0.5324108156492002
getNoiseByCoordinate(x, y, z);
// -> 0.7722926216956694
const perlinNoise = require('perlin-fp');
const { getNoiseByCoordinate } = perlinNoise()
.setSeed(1)
.setOctaves(4)
.setAmpFallOff(0.5);
const [x, y, z] = [0, 0, 0];
getNoiseByCoordinate(x, y, z);
// -> 0.22167705494211987
getNoiseByCoordinate(x, y, z);
// -> 0.22167705494211987