diff --git a/src/audio.js b/src/audio.js index b6fc058..814ef27 100644 --- a/src/audio.js +++ b/src/audio.js @@ -34,6 +34,9 @@ class AudioEngine { this.stream = null; // MediaStream when using live input this.mode = 'none'; this.onEnded = null; // callback fired when a (non-looping) track ends + this._videoSrc = null; // persistent source for the playlist video element + this._videoGain = null; + this._videoSrcEl = null; // Smoothed band values and beat state. this.gain = 1.0; // master reactivity multiplier @@ -145,6 +148,28 @@ class AudioEngine { this.mode = 'input'; } + // Play a playlist video track: route the given