rename setSound to registerSound

This commit is contained in:
Felix Roos 2023-03-09 21:32:40 +01:00
parent ff1e6714c6
commit 6f5d096e6d
4 changed files with 10 additions and 11 deletions

View file

@ -1,10 +1,10 @@
import { fromMidi, toMidi } from '@strudel.cycles/core';
import { setSound } from './webaudio.mjs';
import { registerSound } from './webaudio.mjs';
import { getOscillator, gainNode, getEnvelope } from './helpers.mjs';
export function registerSynthSounds() {
['sine', 'square', 'triangle', 'sawtooth'].forEach((wave) => {
setSound(
registerSound(
wave,
(t, value, onended) => {
// destructure adsr here, because the default should be different for synths and samples