diff --git a/curves.py b/curves.py new file mode 100644 index 0000000..830cea1 --- /dev/null +++ b/curves.py @@ -0,0 +1,45 @@ +from matplotlib import pyplot as plt +import numpy as np + +detune_max = 10 +x = np.linspace(0, 1) +oscillator_level = x**4 +noise_level = 1 - (x**2) +qfactor = np.exp(-x * 10) +detune = (1 - x) * detune_max +subosc_level = 1 - (x - .5)**2 +distortion = (1 - x)**2 + +plt.subplot(421) +plt.plot(x, oscillator_level) +plt.xlabel("x") +plt.ylabel("Oscillator level") + +plt.subplot(422) +plt.plot(x, noise_level) +plt.xlabel("x") +plt.ylabel("Noise level") + +plt.subplot(423) +plt.plot(x, qfactor) +plt.yscale("log") +plt.xlabel("x") +plt.ylabel("Q factor") + +plt.subplot(424) +plt.plot(x, detune) +plt.xlabel("x") +plt.ylabel("Detune") + +plt.subplot(425) +plt.plot(x, subosc_level) +plt.xlabel("x") +plt.ylabel("Subosc level") + +plt.subplot(426) +plt.plot(x, distortion) +plt.xlabel("x") +plt.ylabel("Distortion") + +plt.tight_layout() +plt.show() diff --git a/fm.scd b/fm.scd index 1d23cd5..a9d086a 100644 --- a/fm.scd +++ b/fm.scd @@ -15,10 +15,10 @@ s.waitForBoot { car = SinOsc.ar( (freq * carPartial) + mod, 0, - mul + 1 ); - Out.ar(0, Disintegrator.ar(SinOsc.ar(440), 0.5)); + Out.ar(0, Disintegrator.ar(car, MouseX.kr(0, 1))); }); module.load(s);