@elemaudio/core
TypeScript icon, indicating that this package has built-in type declarations

3.2.1 • Public • Published

@elemaudio/core

Elementary is a JavaScript/C++ library for building audio applications.

The @elemaudio/core package provides the standard library for composing audio processing nodes, as well as the core graph reconciling and rendering utilities. Often this will be used with one of the provided renderers, @elemaudio/web-renderer or @elemaudio/offline-renderer.

Please see the full documentation at https://www.elementary.audio/

Installation

npm install --save @elemaudio/core

Usage

import { el, Renderer } from '@elemaudio/core';


// Here we're using a default Renderer instance, so it's our responsibility to
// send the instruction batches to the underlying engine
let core = new Renderer((batch) => {
  // Send the instruction batch somewhere: you can set up whatever message
  // passing channel you want!
  console.log(batch);
});

// Now we can write and render audio. How about some binaural beating
// with two detuned sine tones in the left and right channel:
core.render(el.cycle(440), el.cycle(441));

License

MIT

Package Sidebar

Install

npm i @elemaudio/core

Weekly Downloads

1,073

Version

3.2.1

License

MIT

Unpacked Size

162 kB

Total Files

7

Last publish

Collaborators

  • nick-thompson