Skip to content

Commit

Permalink
BeatBlox Previous Version (#61)
Browse files Browse the repository at this point in the history
Embedded Will's API to extension.
  • Loading branch information
ebiwonjumit authored Mar 24, 2024
1 parent be92860 commit 7d23f07
Show file tree
Hide file tree
Showing 2 changed files with 5,384 additions and 2 deletions.
5 changes: 3 additions & 2 deletions extensions/BeatBlox/index.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
(function () {
const script = document.createElement('script');
const devRootScript = 'http://localhost:9090/extensions/BeatBlox/webAudioAPI.js';
const releaseRootScript = 'https://extensions.netsblox.org/extensions/BeatBlox/webAudioAPI.js';
script.type = 'module';
script.src = 'https://hedgecrw.github.io/WebAudioAPI/lib/webAudioAPI.js';
script.src = window.origin.includes('localhost') ? devRootScript : releaseRootScript;
script.async = false;
script.onload = () => {
let lastRecordedClip = null;
let currentDeviceType = null;
let appliedEffects = [];

const audioAPI = new window.WebAudioAPI();
const I32_MAX = 2147483647;
const SCHEDULING_WINDOW = 0.02; // seconds
Expand Down
Loading

0 comments on commit 7d23f07

Please sign in to comment.