(()=>{"use strict";function e(e,n){if(e.length===n)return e;const r=[];if(e.length>n){const t=Math.round(e.length/n);for(let n=0;n<e.length;n+=t)r.push(e[n])}else{const u=Math.ceil(n/e.length);for(const n of e)r.push(...t(n,u))}return u=r,a=n,i=t(e[e.length-1],n),u.length===a?u:u.length>a?u.slice(0,a):u.concat(i.slice(0,a-u.length));var u,a,i}function n(e,n,t){const r=Math.min(...e),u=Math.max(...e);return e.map(e=>function(e,n,t){return e*(t-n)+n}(function(e,n,t){const r=(e-n)/(t-n);return Number.isNaN(r)?0:r}(e,r,u),n,t))}function t(e,n){return new Array(n).fill(e)}(()=>{if("undefined"!=typeof __webpack_require__){var e=__webpack_require__.u,n=__webpack_require__.e,t={},r={};__webpack_require__.u=function(n){return e(n)+(t.hasOwnProperty(n)?"?"+t[n]:"")},__webpack_require__.e=function(u){return n(u).catch(function(n){var a=r.hasOwnProperty(u)?r[u]:3;if(a<1){var i=e(u);throw n.message="Loading chunk "+u+" failed after 3 retries.\n("+i+")",n.request=i,n}return new Promise(function(e){setTimeout(function(){var n=Date.now();t[u]=n,r[u]=a-1,e(__webpack_require__.e(u))},500)})})}}})();t(0,39);const r=self;r.addEventListener("message",async t=>{const{seq:u,data:a}=t.data,i=n(function(n,t){if(n.length===t)return n;let r=[];if(n.length>t){for(;r.length>2*t||0===r.length;){r=[];for(let e=1;e<n.length-1;e+=2){const t=(n[e-1]+n[e+1]+n[e])/3;r.push(t)}n=r}return e(r,t)}return e(n,t)}(a.map(e=>Math.abs(e)),39),0,1);r.postMessage({seq:u,waveform:i})})})();
//# sourceMappingURL=playback.worker.js.map