Code Monkey home page Code Monkey logo

webaudio-examples's Introduction

webaudio-examples

Code examples that accompany the MDN Web Audio documentation https://developer.mozilla.org/en-US/docs/Web/API/Web_Audio_API

The "audio-buffer" directory contains a very simple example showing how to use an audio buffer in Web Audio API. Run the demo live.

The "audio-param" directory contains some simple examples showing how to use the methods of the Web Audio API AudioParam interface. For more information, see https://developer.mozilla.org/en-US/docs/Web/API/AudioParam. Run example live.

The "audiocontext-states" directory contains a simple demo of the new Web Audio API AudioContext states, including the states property and the close(), resume() and suspend() methods. See https://developer.mozilla.org/en-US/docs/Web/API/AudioContext for more details. Run the demo live.

The "compressor-example" directory contains a simple demo to show usage of the Web Audio API createDynamicsCompressor() method and DynamicCompressorNode. For more information, see https://developer.mozilla.org/en-US/docs/Web/API/AudioContext/createDynamicsCompressor. Run the example live.

The "create-media-stream-destination" directory contains a simple example showing how Web Audio API AudioContext.createMediaStreamDestination which can be used to output a stream, in this case to a MediaRecorder instance, to output a sinewave to an opus file. Run the demo live.

The "decode-audio-data" directory contains a simple example demonstrating usage of the Web Audio API decodeAudioData() method. For more information, see https://developer.mozilla.org/en-US/docs/Web/API/AudioContext/decodeAudioData. View example live.

The "media-source-buffer" directory contains a simple example demonstrating usage of the Web Audio API AudioContext.createMediaElementSource() method. For more information, see https://developer.mozilla.org/en-US/docs/Web/API/AudioContext/createMediaElementSource or view the demo live.

The "offline-audio-context" directory contains a simple example to show how a Web Audio API OfflineAudioContext object can be used to rapidly process/render audio in the background to create a buffer, which can then be used in any way you please. For more information, see https://developer.mozilla.org/en-US/docs/Web/API/OfflineAudioContext. Run example live.

The "offline-audio-context-promise" directory contains a simple example to show how a Web Audio API OfflineAudioContext object can be used to rapidly process/render audio in the background to create a buffer, which can then be used in any way you please. For more information, see https://developer.mozilla.org/en-US/docs/Web/API/OfflineAudioContext/startRendering(promise). Run the example live.

The "panner-node" directory contains a demo to show basic usage of a Web Audio API PannerNode to control audio spatialisation. See https://developer.mozilla.org/en-US/docs/Web/API/AudioContext/createPanner for more details. Run the example live.

The "script-processor-node" directory contains a simple demo showing how to use the Web Audio API's ScriptProcessorNode to process a loaded audio track, adding a little bit of white noise to each audio sample. For more information see ScriptProcessorNode documentation and the live demo.

The "stereo-panner-node" directory contains a simple example to show how the Web Audio API StereoPannerNode can be used to pan an audio stream. See https://developer.mozilla.org/en-US/docs/Web/API/StereoPannerNode for more details. Run the example live.

The "stream-source-buffer" directory contains a simple example demonstrating usage of the Web Audio API AudioContext.createMediaElementSource() method. For more information, see https://developer.mozilla.org/en-US/docs/Web/API/AudioContext/createMediaStreamSource. View example live.

webaudio-examples's People

Contributors

chrisdavidmills avatar elchi3 avatar jan-ivar avatar kchapelier avatar nbriz avatar teoli2003 avatar

Watchers

James Cloos avatar JanChou 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.