adding public in soundevents

This commit is contained in:
2023-08-31 20:56:09 +02:00
parent 01f56276bf
commit f82f2735fa

View File

@ -23,61 +23,63 @@ export class SoundEvent extends AudibleEvent {
// ZZFX Sound Parameters // ZZFX Sound Parameters
// ================================================================================ // ================================================================================
volume = (value: number) => this.updateValue("volume", value); public volume = (value: number) => this.updateValue("volume", value);
vol = this.volume; public vol = this.volume;
zrand = (value: number) => this.updateValue("zrand", value); public zrand = (value: number) => this.updateValue("zrand", value);
curve = (value: number) => this.updateValue("curve", value); public curve = (value: number) => this.updateValue("curve", value);
slide = (value: number) => this.updateValue("slide", value); public slide = (value: number) => this.updateValue("slide", value);
sld = this.slide; public sld = this.slide;
deltaSlide = (value: number) => this.updateValue("deltaSlide", value); public deltaSlide = (value: number) => this.updateValue("deltaSlide", value);
dslide = this.deltaSlide; public dslide = this.deltaSlide;
pitchJump = (value: number) => this.updateValue("pitchJump", value); public pitchJump = (value: number) => this.updateValue("pitchJump", value);
pj = this.pitchJump; public pj = this.pitchJump;
pitchJumpTime = (value: number) => this.updateValue("pitchJumpTime", value); public pitchJumpTime = (value: number) =>
pjt = this.pitchJumpTime; this.updateValue("pitchJumpTime", value);
lfo = (value: number) => this.updateValue("lfo", value); public pjt = this.pitchJumpTime;
noise = (value: number) => this.updateValue("noise", value); public lfo = (value: number) => this.updateValue("lfo", value);
zmod = (value: number) => this.updateValue("zmod", value); public noise = (value: number) => this.updateValue("noise", value);
zcrush = (value: number) => this.updateValue("zcrush", value); public zmod = (value: number) => this.updateValue("zmod", value);
zdelay = (value: number) => this.updateValue("zdelay", value); public zcrush = (value: number) => this.updateValue("zcrush", value);
sustainVolume = (value: number) => this.updateValue("sustainVolume", value); public zdelay = (value: number) => this.updateValue("zdelay", value);
decay = (value: number) => this.updateValue("decay", value); public sustainVolume = (value: number) =>
dec = this.decay; this.updateValue("sustainVolume", value);
tremolo = (value: number) => this.updateValue("tremolo", value); public decay = (value: number) => this.updateValue("decay", value);
duration = (value: number) => this.updateValue("duration", value); public dec = this.decay;
zzfx = (value: number[]) => this.updateValue("zzfx", value); public tremolo = (value: number) => this.updateValue("tremolo", value);
public duration = (value: number) => this.updateValue("duration", value);
public zzfx = (value: number[]) => this.updateValue("zzfx", value);
// ================================================================================ // ================================================================================
// Basic Audio Engine Parameters // Basic Audio Engine Parameters
// ================================================================================ // ================================================================================
fmi = (value: number) => this.updateValue("fmi", value); public fmi = (value: number) => this.updateValue("fmi", value);
fmh = (value: number) => this.updateValue("fmh", value); public fmh = (value: number) => this.updateValue("fmh", value);
fmenv = (value: "lin" | "exp") => this.updateValue("fmenv", value); public fmenv = (value: "lin" | "exp") => this.updateValue("fmenv", value);
fmattack = (value: number) => this.updateValue("fmattack", value); public fmattack = (value: number) => this.updateValue("fmattack", value);
fmatk = this.fmattack; public fmatk = this.fmattack;
fmdecay = (value: number) => this.updateValue("fmdecay", value); public fmdecay = (value: number) => this.updateValue("fmdecay", value);
fmdec = this.fmdecay; public fmdec = this.fmdecay;
fmsustain = (value: number) => this.updateValue("fmsustain", value); public fmsustain = (value: number) => this.updateValue("fmsustain", value);
fmsus = this.fmsustain; public fmsus = this.fmsustain;
fmrelease = (value: number) => this.updateValue("fmrelease", value); public fmrelease = (value: number) => this.updateValue("fmrelease", value);
fmrel = this.fmrelease; public fmrel = this.fmrelease;
fmvelocity = (value: number) => this.updateValue("fmvelocity", value); public fmvelocity = (value: number) => this.updateValue("fmvelocity", value);
fmvel = this.fmvelocity; public fmvel = this.fmvelocity;
fmwave = (value: "sine" | "triangle" | "sawtooth" | "square") => public fmwave = (value: "sine" | "triangle" | "sawtooth" | "square") =>
this.updateValue("fmwave", value); this.updateValue("fmwave", value);
fmw = this.fmwave; public fmw = this.fmwave;
attack = (value: number) => this.updateValue("attack", value); public attack = (value: number) => this.updateValue("attack", value);
atk = this.attack; public atk = this.attack;
release = (value: number) => this.updateValue("release", value); public release = (value: number) => this.updateValue("release", value);
rel = this.release; public rel = this.release;
sustain = (value: number) => this.updateValue("sustain", value); public sustain = (value: number) => this.updateValue("sustain", value);
sus = this.sustain; public sus = this.sustain;
unit = (value: number) => this.updateValue("unit", value); public unit = (value: number) => this.updateValue("unit", value);
u = this.unit; public u = this.unit;
freq = (value: number) => this.updateValue("freq", value); public freq = (value: number) => this.updateValue("freq", value);
f = this.freq; public f = this.freq;
fm = (value: number | string) => { public fm = (value: number | string) => {
if (typeof value === "number") { if (typeof value === "number") {
this.values["fmi"] = value; this.values["fmi"] = value;
} else { } else {
@ -87,51 +89,52 @@ export class SoundEvent extends AudibleEvent {
} }
return this; return this;
}; };
sound = (value: string) => this.updateValue("s", value); public sound = (value: string) => this.updateValue("s", value);
snd = this.sound; public snd = this.sound;
nudge = (value: number) => this.updateValue("nudge", value); public nudge = (value: number) => this.updateValue("nudge", value);
cut = (value: number) => this.updateValue("cut", value); public cut = (value: number) => this.updateValue("cut", value);
loop = (value: number) => this.updateValue("loop", value); public loop = (value: number) => this.updateValue("loop", value);
clip = (value: number) => this.updateValue("clip", value); public clip = (value: number) => this.updateValue("clip", value);
n = (value: number) => this.updateValue("n", value); public n = (value: number) => this.updateValue("n", value);
note = (value: number) => this.updateValue("note", value); public note = (value: number) => this.updateValue("note", value);
speed = (value: number) => this.updateValue("speed", value); public speed = (value: number) => this.updateValue("speed", value);
spd = this.speed; public spd = this.speed;
begin = (value: number) => this.updateValue("begin", value); public begin = (value: number) => this.updateValue("begin", value);
end = (value: number) => this.updateValue("end", value); public end = (value: number) => this.updateValue("end", value);
gain = (value: number) => this.updateValue("gain", value); public gain = (value: number) => this.updateValue("gain", value);
cutoff = (value: number) => this.updateValue("cutoff", value); public cutoff = (value: number) => this.updateValue("cutoff", value);
lpf = this.cutoff; public lpf = this.cutoff;
resonance = (value: number) => this.updateValue("resonance", value); public resonance = (value: number) => this.updateValue("resonance", value);
lpq = this.resonance; public lpq = this.resonance;
hcutoff = (value: number) => this.updateValue("hcutoff", value); public hcutoff = (value: number) => this.updateValue("hcutoff", value);
hpf = this.hcutoff; public hpf = this.hcutoff;
hresonance = (value: number) => this.updateValue("hresonance", value); public hresonance = (value: number) => this.updateValue("hresonance", value);
hpq = this.hresonance; public hpq = this.hresonance;
bandf = (value: number) => this.updateValue("bandf", value); public bandf = (value: number) => this.updateValue("bandf", value);
bpf = this.bandf; public bpf = this.bandf;
bandq = (value: number) => this.updateValue("bandq", value); public bandq = (value: number) => this.updateValue("bandq", value);
bpq = this.bandq; public bpq = this.bandq;
coarse = (value: number) => this.updateValue("coarse", value); public coarse = (value: number) => this.updateValue("coarse", value);
crush = (value: number) => this.updateValue("crush", value); public crush = (value: number) => this.updateValue("crush", value);
shape = (value: number) => this.updateValue("shape", value); public shape = (value: number) => this.updateValue("shape", value);
pan = (value: number) => this.updateValue("pan", value); public pan = (value: number) => this.updateValue("pan", value);
vowel = (value: number) => this.updateValue("vowel", value); public vowel = (value: number) => this.updateValue("vowel", value);
vow = this.vowel; public vow = this.vowel;
delay = (value: number) => this.updateValue("delay", value); public delay = (value: number) => this.updateValue("delay", value);
del = this.delay; public del = this.delay;
delayfeedback = (value: number) => this.updateValue("delayfeedback", value); public delayfeedback = (value: number) =>
delayfb = this.delayfeedback; this.updateValue("delayfeedback", value);
delaytime = (value: number) => this.updateValue("delaytime", value); public delayfb = this.delayfeedback;
delayt = this.delaytime; public delaytime = (value: number) => this.updateValue("delaytime", value);
orbit = (value: number) => this.updateValue("orbit", value); public delayt = this.delaytime;
o = this.orbit; public orbit = (value: number) => this.updateValue("orbit", value);
room = (value: number) => this.updateValue("room", value); public o = this.orbit;
rm = this.room; public room = (value: number) => this.updateValue("room", value);
size = (value: number) => this.updateValue("size", value); public rm = this.room;
sz = this.size; public size = (value: number) => this.updateValue("size", value);
velocity = (value: number) => this.updateValue("velocity", value); public sz = this.size;
vel = this.velocity; public velocity = (value: number) => this.updateValue("velocity", value);
public vel = this.velocity;
update = (): void => { update = (): void => {
const [note, _] = noteFromPc( const [note, _] = noteFromPc(