WAAWhiteNoiseNode
A white noise node for Web audio API.
Note : The method used to generate noise is terrible (looping over a random buffer), and so the white noise really isn't one ... but that method is the only way at the moment to generate noise with native audio nodes.
Installation
You can grab the latest browser build from dist/ or install through npm with npm install waawhitenoise
Usage
Create :
var context = noiseNode = context
Connect :
// `WAAWhiteNoiseNode.connect` takes the same arguments as `AudioNode.connect`noiseNode
Start / Stop :
// Start at currentTime = 0.5 secondsnoiseNodestart05// Stop at currentTime = 10 secondsnoiseNode
Build
npm run build
Run the tests
Run npm build.tests
. It will create a waatest
folder in the root of the package. Then open waatest/index.html
in a web browser.