commit 13e794f44b0bb11f62e0922ce6aadf64a0f1e962 Author: adminoo Date: Wed Feb 26 07:33:14 2025 +0100 initial commit diff --git a/README.md b/README.md new file mode 100644 index 0000000..a4ee02a --- /dev/null +++ b/README.md @@ -0,0 +1,3 @@ +# Scoobidules + +A collection of snippets, patches, classes and hybrid SuperCollider bidules diff --git a/bitcrushing.scd b/bitcrushing.scd new file mode 100644 index 0000000..61fa452 --- /dev/null +++ b/bitcrushing.scd @@ -0,0 +1,4 @@ +// bitcrushing +sig = sig.round(0.12); +// sample rate reduction +sig = Latch.ar(sig, Impulse.ar(SampleRate.ir/10)); \ No newline at end of file diff --git a/choir.scd b/choir.scd new file mode 100644 index 0000000..c7fa5a8 --- /dev/null +++ b/choir.scd @@ -0,0 +1,72 @@ +// create a choir from two formants +( + +// https://en.wikipedia.org/wiki/Formant#cite_note-7 +var formants = [ + [360, 640], // o + [235, 2100], // y + [390, 2300], // e + [585, 1710], // æ + [850, 1610], // a + [750, 940], // ɑ + [820, 1530], // ɶ + [600, 1170], // ʌ + [250, 595], // u + [240, 2400], // i +]; + +SynthDef(\formoo, { + arg formants = #[850, 1610]; + var sig, env; + env = Env.perc(\attack.kr(0), \decay.kr(1)).ar(Done.freeSelf); + sig = 10.collect{ + var octave = [1, 2, 0.5, 1.5]; + // base freq * octave * detuning over time + // sounds like a chorus fx + var voice = Saw.ar(\freq.kr(220) * LFNoise2.kr(3).linlin(-1, 1, 0.99, 1.1) * octave.choose); + // formant * detuning; very high resonance + voice = RLPF.ar( + voice, + formants * + formants.size.collect{ + LFNoise2.kr(3).linlin(-1, 1, 0.98, 1.05) + }, 0.05).sum; + // detune and blur some more + voice = voice + PitchShift.ar(voice, {Rand(0.01, 0.1)}, 0.98) * 0.5; + // a bit of distortion + voice = voice.softclip; + }; + sig = Splay.ar(sig); + // narrowing the spectrum a little more + sig = RLPF.ar( + sig, + \ff.kr(4700) * + LFNoise2.kr(1).linlin(-1, 1, 0.95, 1.05), + \qr.kr(0.9) + ); + sig = sig * env; + sig = sig * \amp.kr(0.25); + sig = Limiter.ar(sig); + Out.ar(\out.kr(0), sig); +}).add; +) + +// example +( +r { + [38 + 3, 38 +5, 38 + 12].do{ + |freq| + Synth(\formoo, + [ + amp: 0.15, + attack: 2, + decay: 5, + freq: freq.midicps, + formants: [850, 1610], + ff: rrand(550, 2660), + qr: 0.5 + ] + ); + } +}.play; +) \ No newline at end of file diff --git a/chorus.scd b/chorus.scd new file mode 100644 index 0000000..1ae3ab0 --- /dev/null +++ b/chorus.scd @@ -0,0 +1,5 @@ +sig = 8.collect({ + var mod = LFTri.kr(ExpRand(0.2, 0.3), Rand(0.0, 2.0)).range(0.001, 0.02); + DelayL.ar(sig, 0.02, mod); +}); +sig = Splay.ar(sig, 0.2); \ No newline at end of file diff --git a/extensions/Track/classes/fadable.sc b/extensions/Track/classes/fadable.sc new file mode 100644 index 0000000..f8f690f --- /dev/null +++ b/extensions/Track/classes/fadable.sc @@ -0,0 +1,36 @@ +// object provides fading ability and levels +Fadable { + var track, level; + fade { + // exponential fading level toward during