mirror of
https://codeberg.org/uzu/strudel
synced 2026-09-05 06:57:35 -04:00
Updates
This commit is contained in:
File diff suppressed because one or more lines are too long
@@ -1 +0,0 @@
|
||||
import{U as a}from"./index.06de1df0.js";export{a as loadWebDirt};
|
||||
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
||||
import{W as a,G as b}from"./index.4c53df7b.js";export{a as WebMidi,b as enableWebMidi};
|
||||
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
||||
import{U as a}from"./index.4c53df7b.js";export{a as loadWebDirt};
|
||||
@@ -1,4 +1,4 @@
|
||||
var at=Object.defineProperty,it=Object.defineProperties;var ft=Object.getOwnPropertyDescriptors;var M=Object.getOwnPropertySymbols;var Pe=Object.prototype.hasOwnProperty,Oe=Object.prototype.propertyIsEnumerable;var Re=(a,f,r)=>f in a?at(a,f,{enumerable:!0,configurable:!0,writable:!0,value:r}):a[f]=r,H=(a,f)=>{for(var r in f||(f={}))Pe.call(f,r)&&Re(a,r,f[r]);if(M)for(var r of M(f))Oe.call(f,r)&&Re(a,r,f[r]);return a},J=(a,f)=>it(a,ft(f));var qe=(a,f)=>{var r={};for(var $ in a)Pe.call(a,$)&&f.indexOf($)<0&&(r[$]=a[$]);if(a!=null&&M)for(var $ of M(a))f.indexOf($)<0&&Oe.call(a,$)&&(r[$]=a[$]);return r};import{F as ot}from"./index.06de1df0.js";function ct(a,f){function r(){this.constructor=a}r.prototype=f.prototype,a.prototype=new r}function D(a,f,r,$){var l=Error.call(this,a);return Object.setPrototypeOf&&Object.setPrototypeOf(l,D.prototype),l.expected=f,l.found=r,l.location=$,l.name="SyntaxError",l}ct(D,Error);function K(a,f,r){return r=r||" ",a.length>f?a:(f-=a.length,r+=r.repeat(f),a+r.slice(0,f))}D.prototype.format=function(a){var f="Error: "+this.message;if(this.location){var r=null,$;for($=0;$<a.length;$++)if(a[$].source===this.location.source){r=a[$].text.split(/\r\n|\n|\r/g);break}var l=this.location.start,_=this.location.source+":"+l.line+":"+l.column;if(r){var A=this.location.end,w=K("",l.line.toString().length," "),E=r[l.line-1],d=l.line===A.line?A.column:E.length+1,h=d-l.column||1;f+=`
|
||||
var at=Object.defineProperty,it=Object.defineProperties;var ft=Object.getOwnPropertyDescriptors;var M=Object.getOwnPropertySymbols;var Pe=Object.prototype.hasOwnProperty,Oe=Object.prototype.propertyIsEnumerable;var Re=(a,f,r)=>f in a?at(a,f,{enumerable:!0,configurable:!0,writable:!0,value:r}):a[f]=r,H=(a,f)=>{for(var r in f||(f={}))Pe.call(f,r)&&Re(a,r,f[r]);if(M)for(var r of M(f))Oe.call(f,r)&&Re(a,r,f[r]);return a},J=(a,f)=>it(a,ft(f));var qe=(a,f)=>{var r={};for(var $ in a)Pe.call(a,$)&&f.indexOf($)<0&&(r[$]=a[$]);if(a!=null&&M)for(var $ of M(a))f.indexOf($)<0&&Oe.call(a,$)&&(r[$]=a[$]);return r};import{F as ot}from"./index.4c53df7b.js";function ct(a,f){function r(){this.constructor=a}r.prototype=f.prototype,a.prototype=new r}function D(a,f,r,$){var l=Error.call(this,a);return Object.setPrototypeOf&&Object.setPrototypeOf(l,D.prototype),l.expected=f,l.found=r,l.location=$,l.name="SyntaxError",l}ct(D,Error);function K(a,f,r){return r=r||" ",a.length>f?a:(f-=a.length,r+=r.repeat(f),a+r.slice(0,f))}D.prototype.format=function(a){var f="Error: "+this.message;if(this.location){var r=null,$;for($=0;$<a.length;$++)if(a[$].source===this.location.source){r=a[$].text.split(/\r\n|\n|\r/g);break}var l=this.location.start,_=this.location.source+":"+l.line+":"+l.column;if(r){var A=this.location.end,w=K("",l.line.toString().length," "),E=r[l.line-1],d=l.line===A.line?A.column:E.length+1,h=d-l.column||1;f+=`
|
||||
--> `+_+`
|
||||
`+w+` |
|
||||
`+l.line+" | "+E+`
|
||||
@@ -1 +1 @@
|
||||
import{T as e,o as n,a as o,x as t,u as h,y as l,d as p,f as r,g as m,t as y,w as u,k as c,l as d,m as g,b as i,c as f,n as w,q as b,r as k,j as x,h as D,p as v,e as T,s as j,i as q,v as C}from"./index.06de1df0.js";export{e as Tone,n as adsr,o as amsynth,t as backgroundImage,h as cleanupDraw,l as cleanupUi,p as duosynth,r as fmsynth,m as getDefaultSynth,y as getDrawContext,u as hideHeader,c as highpass,d as lowpass,g as membrane,i as metal,f as monosynth,w as noise,b as osc,k as out,x as piano,D as players,v as pluck,T as polysynth,j as sampler,q as synth,C as vol};
|
||||
import{T as e,o as n,a as o,x as t,u as h,y as l,d as p,f as r,g as m,t as y,w as u,k as c,l as d,m as g,b as i,c as f,n as w,q as b,r as k,j as x,h as D,p as v,e as T,s as j,i as q,v as C}from"./index.4c53df7b.js";export{e as Tone,n as adsr,o as amsynth,t as backgroundImage,h as cleanupDraw,l as cleanupUi,p as duosynth,r as fmsynth,m as getDefaultSynth,y as getDrawContext,u as hideHeader,c as highpass,d as lowpass,g as membrane,i as metal,f as monosynth,w as noise,b as osc,k as out,x as piano,D as players,v as pluck,T as polysynth,j as sampler,q as synth,C as vol};
|
||||
@@ -1 +0,0 @@
|
||||
import{W as a,G as b}from"./index.06de1df0.js";export{a as WebMidi,b as enableWebMidi};
|
||||
File diff suppressed because one or more lines are too long
@@ -1 +1 @@
|
||||
var h=Object.defineProperty;var p=(e,t,s)=>t in e?h(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s;var l=(e,t,s)=>(p(e,typeof t!="symbol"?t+"":t,s),s);import{S as f,I as u}from"./index.06de1df0.js";import{J as v,K as L,M,R as T,L as B,N as I,Q as y,O as R}from"./index.06de1df0.js";const d=e=>"("+e+")();",g=e=>URL.createObjectURL(new Blob([d(e)],{type:"text/javascript"})),w=e=>new Worker(g(e));class k{constructor(t,s,i=this.interval){l(this,"worker");l(this,"audioContext");l(this,"interval",.2);l(this,"lastEnd",0);this.audioContext=t,this.interval=i,this.worker=w(()=>{let o,a=null;const n=()=>{a&&(clearInterval(a),a=null)},r=()=>{if(n(),!o)throw new Error("no interval set! call worker.postMessage({interval}) before starting.");a=setInterval(()=>postMessage("tick"),o*1e3)};self.onmessage=function(c){c.data=="start"?r():c.data.interval?(o=c.data.interval,a&&r()):c.data=="stop"&&n()}}),this.worker.postMessage({interval:i}),this.worker.onmessage=o=>{if(o.data==="tick"){const a=this.lastEnd||this.audioContext.currentTime,n=this.audioContext.currentTime+this.interval;this.lastEnd=n,s(a,n)}}}start(){console.log("start..."),this.audioContext.resume(),this.worker.postMessage("start")}stop(){console.log("stop..."),this.worker.postMessage("stop")}}class b{constructor({audioContext:t,interval:s=.2,onEvent:i,latency:o=.2}){l(this,"worker");l(this,"pattern");this.worker=new k(t,(a,n)=>{this.pattern.query(new f(new u(a+o,n+o))).forEach(r=>{!r.part.begin.equals(r.whole.begin)||(r.context.onTrigger&&r.context.onTrigger(r.whole.begin,r,t.currentTime,1),i&&(i==null||i(r)))})},s)}start(){if(!this.pattern)throw new Error("Scheduler: no pattern set! call .setPattern first.");this.worker.start()}stop(){this.worker.stop()}setPattern(t){this.pattern=t}}export{k as ClockWorker,b as Scheduler,v as getAudioContext,L as getCachedBuffer,M as getLoadedBuffer,T as getLoadedSamples,B as loadBuffer,I as loadGithubSamples,y as resetLoadedSamples,R as samples};
|
||||
var h=Object.defineProperty;var p=(e,t,s)=>t in e?h(e,t,{enumerable:!0,configurable:!0,writable:!0,value:s}):e[t]=s;var l=(e,t,s)=>(p(e,typeof t!="symbol"?t+"":t,s),s);import{S as f,I as u}from"./index.4c53df7b.js";import{J as v,K as L,M,R as T,L as B,N as I,Q as y,O as R}from"./index.4c53df7b.js";const d=e=>"("+e+")();",g=e=>URL.createObjectURL(new Blob([d(e)],{type:"text/javascript"})),w=e=>new Worker(g(e));class k{constructor(t,s,i=this.interval){l(this,"worker");l(this,"audioContext");l(this,"interval",.2);l(this,"lastEnd",0);this.audioContext=t,this.interval=i,this.worker=w(()=>{let o,a=null;const n=()=>{a&&(clearInterval(a),a=null)},r=()=>{if(n(),!o)throw new Error("no interval set! call worker.postMessage({interval}) before starting.");a=setInterval(()=>postMessage("tick"),o*1e3)};self.onmessage=function(c){c.data=="start"?r():c.data.interval?(o=c.data.interval,a&&r()):c.data=="stop"&&n()}}),this.worker.postMessage({interval:i}),this.worker.onmessage=o=>{if(o.data==="tick"){const a=this.lastEnd||this.audioContext.currentTime,n=this.audioContext.currentTime+this.interval;this.lastEnd=n,s(a,n)}}}start(){console.log("start..."),this.audioContext.resume(),this.worker.postMessage("start")}stop(){console.log("stop..."),this.worker.postMessage("stop")}}class b{constructor({audioContext:t,interval:s=.2,onEvent:i,latency:o=.2}){l(this,"worker");l(this,"pattern");this.worker=new k(t,(a,n)=>{this.pattern.query(new f(new u(a+o,n+o))).forEach(r=>{!r.part.begin.equals(r.whole.begin)||(r.context.onTrigger&&r.context.onTrigger(r.whole.begin,r,t.currentTime,1),i&&(i==null||i(r)))})},s)}start(){if(!this.pattern)throw new Error("Scheduler: no pattern set! call .setPattern first.");this.worker.start()}stop(){this.worker.stop()}setPattern(t){this.pattern=t}}export{k as ClockWorker,b as Scheduler,v as getAudioContext,L as getCachedBuffer,M as getLoadedBuffer,T as getLoadedSamples,B as loadBuffer,I as loadGithubSamples,y as resetLoadedSamples,R as samples};
|
||||
File diff suppressed because one or more lines are too long
@@ -1 +1 @@
|
||||
var d=Object.defineProperty,m=Object.defineProperties;var x=Object.getOwnPropertyDescriptors;var f=Object.getOwnPropertySymbols;var p=Object.prototype.hasOwnProperty,T=Object.prototype.propertyIsEnumerable;var u=(r,e,t)=>e in r?d(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,v=(r,e)=>{for(var t in e||(e={}))p.call(e,t)&&u(r,t,e[t]);if(f)for(var t of f(e))T.call(e,t)&&u(r,t,e[t]);return r},w=(r,e)=>m(r,x(e));import{P as W}from"./index.06de1df0.js";var n,b=!1;async function $(r=38400){if(!b){if(b=!0,n)return n;if("serial"in navigator){const e=await navigator.serial.requestPort();await e.open({baudRate:r});const t=new TextEncoderStream;t.readable.pipeTo(e.writable);const s=t.writable.getWriter();n=function(i){s.write(i)}}else throw"Webserial is not available in this browser."}}const j=.1;W.prototype.serial=function(...r){return this._withHap(e=>{n||$(...r);const t=(s,i,g)=>{var o="";if(typeof i.value=="object")if("action"in i.value){o+=i.value.action+"(";var c=!0;for(const[a,l]of Object.entries(i.value))a!=="action"&&(c?c=!1:o+=",",o+=`${a}:${l}`);o+=")"}else for(const[a,l]of Object.entries(i.value))o+=`${a}:${l};`;else o=i.value;const y=(s-g+j)*1e3;window.setTimeout(n,y,o)};return e.setContext(w(v({},e.context),{onTrigger:t}))})};export{$ as getWriter};
|
||||
var d=Object.defineProperty,m=Object.defineProperties;var x=Object.getOwnPropertyDescriptors;var f=Object.getOwnPropertySymbols;var p=Object.prototype.hasOwnProperty,T=Object.prototype.propertyIsEnumerable;var u=(r,e,t)=>e in r?d(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t,v=(r,e)=>{for(var t in e||(e={}))p.call(e,t)&&u(r,t,e[t]);if(f)for(var t of f(e))T.call(e,t)&&u(r,t,e[t]);return r},w=(r,e)=>m(r,x(e));import{P as W}from"./index.4c53df7b.js";var n,b=!1;async function $(r=38400){if(!b){if(b=!0,n)return n;if("serial"in navigator){const e=await navigator.serial.requestPort();await e.open({baudRate:r});const t=new TextEncoderStream;t.readable.pipeTo(e.writable);const s=t.writable.getWriter();n=function(i){s.write(i)}}else throw"Webserial is not available in this browser."}}const j=.1;W.prototype.serial=function(...r){return this._withHap(e=>{n||$(...r);const t=(s,i,g)=>{var o="";if(typeof i.value=="object")if("action"in i.value){o+=i.value.action+"(";var c=!0;for(const[a,l]of Object.entries(i.value))a!=="action"&&(c?c=!1:o+=",",o+=`${a}:${l}`);o+=")"}else for(const[a,l]of Object.entries(i.value))o+=`${a}:${l};`;else o=i.value;const y=(s-g+j)*1e3;window.setTimeout(n,y,o)};return e.setContext(w(v({},e.context),{onTrigger:t}))})};export{$ as getWriter};
|
||||
+2
-2
@@ -9,8 +9,8 @@
|
||||
<!-- TODO: add manifest images -->
|
||||
<!-- <link rel="manifest" href="%PUBLIC_URL%/manifest.json" /> -->
|
||||
<title>Strudel REPL</title>
|
||||
<script type="module" crossorigin src="/assets/index.06de1df0.js"></script>
|
||||
<link rel="stylesheet" href="/assets/index.45c51cb5.css">
|
||||
<script type="module" crossorigin src="/assets/index.4c53df7b.js"></script>
|
||||
<link rel="stylesheet" href="/assets/index.2c734ac1.css">
|
||||
</head>
|
||||
<body>
|
||||
<noscript>You need to enable JavaScript to run this app.</noscript>
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user