diff options
author | Jacob Lee <jacob@unabridgedsoftware.com> | 2021-11-11 13:05:20 -0500 |
---|---|---|
committer | Jacob Lee <jacob@unabridgedsoftware.com> | 2021-11-11 13:05:20 -0500 |
commit | a78f43d5a79e0bbe0d41d60b3527da3cfec7f117 (patch) | |
tree | efb1610b2bb7606f41729add2f9d01c0e3894a4f /klangfarb/main.gd | |
parent | a17829f5412ee0757574b34e34ce78b2975df1fe (diff) |
Implement White/Brown noise. Refactor needed
Diffstat (limited to 'klangfarb/main.gd')
-rw-r--r-- | klangfarb/main.gd | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/klangfarb/main.gd b/klangfarb/main.gd index c1cb6e8..268934f 100644 --- a/klangfarb/main.gd +++ b/klangfarb/main.gd @@ -1,7 +1,7 @@ extends AudioStreamPlayer # control wave form -export(String, "sine", "square", "triangle", "sawtooth") var waveform = "sine" +export(String, "sine", "square", "triangle", "sawtooth", "white_noise", "brown_noise") var waveform = "sine" # controllable frequency interface export(float, 20, 8000, 5) var freq = 440.0 # bending the waveform @@ -50,6 +50,10 @@ func _check_waveform(): synth.triangle() elif waveform == "sawtooth": synth.sawtooth() + elif waveform == "white_noise": + synth.white_noise() + elif waveform == "brown_noise": + synth.brown_noise() func _process(_delta): if self.is_playing(): |