2022-01-01

A first sketch for #jamuary. In a recent video Andrew Huang described 5 techniques for generative and ambient music using modular synths. To improve my SuperCollider skills I’m going to try and recreate some of them.

This sketch generates a random, infinite series of notes from a minor scale, interspesed with rests. Like Andrew, I’ve made it more likely that notes will be chosen from the mid range, with high and low notes less likely. Here’s the SuperCollider code:

(
Pbind(
  \dur, 0.5,
  \scale, Scale.minor,
  \degree, Pwrand(
	list: [
	  Prand([-7, -14]),
	  Prand((0..7)),
	  Prand((7..14)),
	  Rest()
	],
	weights: [15, 50, 5, 30].normalizeSum,
	repeats: inf),
  \pan, Prand(#[-0.5, -0.3, -0.1, 0.1, 0.3, 0.5], inf)
).play
)

Calling .play on a Pbind uses the default synth (a filtered sawtooth). Rather than try and make that sound any more interesting today, I’ve instead modulated its pan and then put it through the Valhalla Delay “MylarBloom” (on 30% wet) preset afterwards in Reaper.

I’m only just learning how to sequence in SuperCollider and the take-away today was to nest Prand sequences inside Pwrand to achieve randomness while allowing some control over which notes play.