aboutsummaryrefslogtreecommitdiff
path: root/client.py
diff options
context:
space:
mode:
authorGraham Northup <grissess@nexusg.org>2018-09-25 18:47:35 -0400
committerGraham Northup <grissess@nexusg.org>2018-09-25 18:47:35 -0400
commit5afaac2cda949243a98849f6bf7c217a61fbc8e3 (patch)
tree8da97e49f9b3f6286f8966ec9c9d77d8fae9a1d9 /client.py
parentec177bb81a2a6ab54e05118066364281ebccc318 (diff)
fixed crasher
Diffstat (limited to 'client.py')
-rw-r--r--client.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/client.py b/client.py
index 2c21a9e..1420152 100644
--- a/client.py
+++ b/client.py
@@ -604,13 +604,13 @@ while True:
midi += (random.random() * 2 - 1) * options.chorus
freq = 440.0 * 2 ** ((midi - 69) / 12)
FREQS[voice] = freq
- CUR_PERIODS[voice] = 0.0
amp = pkt.as_float(3)
if options.clamp:
amp = max(min(amp, 1.0), 0.0)
AMPS[voice] = MAX * amp
EXPIRATIONS[voice] = time.time() + dur
if not (pkt.data[5] & PLF.SAMEPHASE):
+ CUR_PERIODS[voice] = 0.0
PHASES[voice] = 0.0
vrgb = [int(i*255) for i in colorsys.hls_to_rgb(float(voice) / STREAMS * 2.0 / 3.0, 0.5, 1.0)]
frgb = rgb_for_freq_amp(pkt.data[2], pkt.as_float(3))