Skip to content

Instantly share code, notes, and snippets.

@zeffii
Forked from anonymous/sammmm2.ck
Created December 2, 2013 18:26
Show Gist options
  • Save zeffii/7754066 to your computer and use it in GitHub Desktop.
Save zeffii/7754066 to your computer and use it in GitHub Desktop.
dac => Mix2 regulator => WvOut2 w => blackhole;
regulator.gain(1.0);
"woooot_samples2.wav" => w.wavFilename;
1 => w.record;
"sqr" => string voiceType;
Osc voiceOsc[1];
if (voiceType == "saw") {new SawOsc @=> voiceOsc[0];}
else if (voiceType == "sin") {new SinOsc @=> voiceOsc[0];}
else if (voiceType == "sqr") {new SqrOsc @=> voiceOsc[0];}
voiceOsc[0].gain(0.5);
voiceOsc[0] => Pan2 dpan => dac;
for(0 => int i; i<20; i++){
1.0 - (1.0/20.0*i) => regulator.gain;
((((i%2)*2)-1)*0.9) => dpan.pan;
0.2::second => now;
}
0 => w.record;
w.closeFile();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment