Skip to content

Instantly share code, notes, and snippets.

@caubry
Last active January 3, 2016 08:39
Show Gist options
  • Save caubry/8437106 to your computer and use it in GitHub Desktop.
Save caubry/8437106 to your computer and use it in GitHub Desktop.
var setup = function() {
var soundRequest = new XMLHttpRequest();
soundRequest.open("GET", "/media/audio/gamedev/bg_menu.ogg", true);
soundRequest.responseType = "arraybuffer";
soundRequest.onload = function () {
try {
//
}
catch(e) {
console.warn('Web Audio API is not supported in this browser');
}
};
soundRequest.send();
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment