Check out the documentation to learn more about using and extending Aurora.
DemoWe have written several decoders using Aurora.js, whose demos you can find here and whose source code can be found on our Github page.
AuthorsAurora.js was written by @jensnockert and @devongovett of Audiocogs.
UsageYou can use Aurora.js both in the browser, as well as in Node.js. In the browser, you can either download a prebuilt release or use browserify to build it into your own app bundle (see below for Node.js usage - it's the same for browserify).
<script src="aurora.js"></script> <script src="mp3.js"></script> <!-- more codecs here -->
To use Aurora.js in Node.js or a browserify build, you can install it from
Then, require the module and codecs you need:
npm install av
var AV = require('av'); require('mp3'); // more codecs here...
For much more detailed information on how to use Aurora.js, check out the documentation.
BuildingWe use browserify to build Aurora.js. To build Aurora.js for the browser yourself, use the following commands:
This will place a built
npm install make browser
aurora.jsfile, as well as a source map in the
By itself, Aurora will play LPCM, uLaw and aLaw files in a number of containers. Be sure to add additional codec support by including some of our other decoders:
If you want to build Aurora without the default codecs, you can use the "browserslim" profile:
This can help shave off approx. 30 KB from the joined file, or 20 KB when minified.