Giter VIP home page Giter VIP logo

fastnoise-wasm's Introduction

FastNoise-wasm

Building

emsdk activate 3.1.19
git clone --recursive https://github.com/grind086/FastNoise-wasm.git
emcc -sEXPORT_NAME=FastNoise -sMODULARIZE=1 --std=c++11 --bind FastNoise/FastNoise.cpp -sWASM=1 -sNO_DYNAMIC_EXECUTION=1 -O0 EMBindings.cpp -o bin/FastNoise.js

API

const FNModule = require('fastnoise-wasm');
const FastNoise = FNModule.FastNoise;

const fastNoise = new FastNoise(1337);

fastNoise.noiseType = FNModule.NoiseType.Perlin;
fastNoise.value2D(1, 1);

FNModule.FastNoise

Constructor

  • new FastNoise(seed)

Properties

  • FastNoise.seed
  • FastNoise.frequency
  • FastNoise.interp
  • FastNoise.noiseType
  • FastNoise.interp
  • FastNoise.fractalOctaves
  • FastNoise.fractalLacunarity
  • FastNoise.fractalGain
  • FastNoise.fractalType
  • FastNoise.cellularDistanceFunction
  • FastNoise.cellularJitter
  • FastNoise.gradientPerturbAmp

Methods

  • FastNoise.value2D(x, y)

  • FastNoise.valueFractal2D(x, y)

  • FastNoise.perlin2D(x, y)

  • FastNoise.perlinFractal2D(x, y)

  • FastNoise.simplex2D(x, y)

  • FastNoise.simplexFractal2D(x, y)

  • FastNoise.cellular2D(x, y)

  • FastNoise.whiteNoise2D(x, y)

  • FastNoise.whiteNoiseInt2D(x, y)

  • FastNoise.cubic2D(x, y)

  • FastNoise.cubicFractal2D(x, y)

  • FastNoise.getNoise2D(x, y)

  • FastNoise.value3D(x, y, z)

  • FastNoise.valueFractal3D(x, y, z)

  • FastNoise.perlin3D(x, y, z)

  • FastNoise.perlinFractal3D(x, y, z)

  • FastNoise.simplex3D(x, y, z)

  • FastNoise.simplexFractal3D(x, y, z)

  • FastNoise.cellular3D(x, y, z)

  • FastNoise.whiteNoise3D(x, y, z)

  • FastNoise.whiteNoiseInt3D(x, y, z)

  • FastNoise.cubic3D(x, y, z)

  • FastNoise.cubicFractal3D(x, y, z)

  • FastNoise.getNoise3D(x, y, z)

  • FastNoise.simplex4D(x, y, z, w)

  • FastNoise.whiteNoise4D(x, y, z, w)

  • FastNoise.whiteNoiseInt4D(x, y, z, w)

TODO

  • GetCellularNoiseLookup
  • SetCellularNoiseLookup
  • GetCellularDistance2Indices
  • SetCellularDistance2Indices
  • GradientPerturb
  • GradientPerturbFractal

fastnoise-wasm's People

Contributors

gfodor avatar grind086 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.