wahsp

A haskell binding of the Web Audio API ala blank-canvas

https://github.com/nshaheed/WebAudioHs/

Latest on Hackage:0.2@rev:1

This package is not currently in any snapshots. If you're interested in using it, we recommend adding it to Stackage Nightly. Doing so will make builds more reliable, and allow stackage.org to host generated Haddocks.

BSD-3-Clause licensed by Nicholas Shaheed
Maintained by [email protected]

wahsp (Web Audio HaSkell Protocol) is a binding for Haskell to the Web Audio API ala blank-canvas. Audio sources, effects, etc. can be combined, manipulated, and otherwise controlled using haskell and are then rendered in the the browser (see the above link for browser compatibility).

Example:

module Main where
import Web.Audio

main :: IO ()
main
main = do
  webAudio 3000 $ \doc -> do
  send doc $ do
    osc1  <- createOscillator 200 0 Sine
    gain1 <- createGain 0.5

    connect $ osc1 .|. gain1 .||. eCtx

    start osc1