Submit
Browse
Anonymous
Login
RSS
SuperCollider Code
Fork Code: 8-bit synth
name
code content
( SynthDef("AM2", { arg freq = 440, modfreq = 12, amp = 0.5, attack = 0.01, dur = 1, pos = 0; var carrier, modulator, env; modulator = LFSaw.kr(modfreq).range(0, 1); carrier = LFSaw.ar(freq: freq, mul: modulator); env = Env.perc(attackTime: attack, releaseTime: dur - attack, level: amp).kr(2); carrier = carrier * env; Out.ar(0, Pan2.ar(carrier, pos)) }).add; ) //Example Melody ( a=Pbind( \instrument, "AM2", \degree, Pseq([0,1,2,3,4,5,6,7,6,5,4,3,2,1],inf), \amp, 0.70, \dur, 0.125, \modfreq, 12, // add different values ).play; )
code description
use markdown for formating
category tags
comma separated, i.g. "wild, siren" (do not enter default SC class names, please)
ancestor(s)
comma separated identificators, i.g. "1-C,1-1,1-4M,1-x"
Private?
the code will be accessible by direct url and not visible in public activity
signup to submit public code without captcha
comment of change