Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
perlin noise generator for node.js
branch: master
Failed to load latest commit information.
README.md update README
index.js initial commit
package.json Release 0.0.1
test.js initial commit

README.md

perlin noise generator for node.js

Usage

var perlin = require('perlin-noise');

var noise = perlin.generatePerlinNoise(480, 480);
// noise is an array with length 480 * 480

Documentation

generatePerlinNoise(width, height, options)

Returns a one-dimensional of length width * height in row-major order. That is, index = y * width + height.

Each value in the array will be between 0 and 1.

  • options (optional)
    • octaveCount - defaults to 4
    • amplitude - defaults to 0.1
    • persistence - defaults to 0.2

generateWhiteNoise(width, height)

Returns a one-dimensional of length width * height in row-major order. That is, index = y * width + height.

Each value in the array will be between 0 and 1.

Something went wrong with that request. Please try again.