home/ atoms/ sc-pbind-synthdef-integration

Pbind can drive any custom SynthDef by naming it with \instrument; SynthDef argument names become Pbind keys

Once a SynthDef is added to the server, Pbind can sequence events through it using \instrument, "synthDefName". All argument names declared in the SynthDef become valid Pbind keys — custom ones work alongside standard pitch/duration keys. Pitch conversion via \degree/\note/\midinote works provided the SynthDef has an argument named exactly freq. For sustained envelopes (ADSR), the SynthDef must have a gate argument (spelled exactly gate) so Pbind can open/close it at the right moments.

Examples

Pbind(
  \instrument, "mySine",
  \degree, Pwhite(-7, 7),
  \dur, 0.2,
  \amp, 0.3
).play;

Assessment

Write a SynthDef with a custom \brightness argument controlling filter cutoff. Sequence it with Pbind, animating brightness from low to high over 8 events using Pseries.

“Oneoftheb eautiesofcreatingyoursynthsasSynthDefsisthatyoucanusePbindtoplay them.”
corpus · a-gentle-introduction-to-supercollider-bruno-ruviaro · chunk 15