( Pbindef("p0".asSymbol, \freq, r.value(82.5, [9/2,11/2,13/2], ~down+(0.05*~ones), 1), \dur, Prand([2,4,6],inf), \sustain, 8, \amp, Pwhite(0.05,0.2,inf), \pan, Pwhite(-1,1,inf), \instrument, \string, \detune, 0.01) )
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
s.boot; // boot server | |
( | |
// SynthDefs | |
SynthDef(\singrain, { |freq = 440, amp = 0.2, sustain = 2, pan=0, out=0| | |
var sig; | |
sig = SinOsc.ar(freq, 0, amp) * EnvGen.kr(Env.perc(0.02, sustain), doneAction: 2); | |
Out.ar(out, Pan2.ar(sig, pan)); | |
}).add; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
s.boot; | |
( | |
// SynthDefs | |
SynthDef(\singrain, { |freq = 440, amp = 0.2, sustain = 2, pan=0, out=0| | |
var sig, env; | |
env = EnvGen.kr(Env.perc(0.02, sustain), doneAction: 2); | |
sig = SinOsc.ar(freq, 0, amp) * env; | |
Out.ar(out, Pan2.ar(sig, pan)); | |
}).add; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
s.boot; | |
( | |
// SynthDefs | |
SynthDef(\singrain, { |freq = 440, amp = 0.2, sustain = 2, pan=0, out=0| | |
var sig, env; | |
env = EnvGen.kr(Env.perc(1, sustain), doneAction: 2); | |
sig = SinOsc.ar(freq, 0, amp) * env; | |
Out.ar(out, Pan2.ar(sig, pan)); | |
}).add; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
s.boot; | |
( | |
SynthDef(\mall,{arg out=0, freq, amp=1, sustain=1, attack=0.01, controlBus=0; | |
var sig1=Array.fill(3,{|n| SinOsc.ar(freq*(n+0.99), 0,0.3)}).sum; | |
var sig2=Array.fill(3,{|n| SinOsc.ar(freq*(n+1.01), 0,0.3)}).sum; | |
var env=EnvGen.kr(Env.perc(attack, sustain), doneAction:2); | |
var controlGate = EnvGen.kr(Env([0,1,1,0], [0, sustain, 0]), doneAction:2); | |
ReplaceOut.kr(controlBus, freq*controlGate); | |
Out.ar(out, (sig1+sig2)*env*amp!2); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
s.boot; | |
( | |
SynthDef(\woodBlock, {|freq = 220, amp = 0.1, sustain = 1, bright = 1, pan = 0, out=0| | |
var partials = [1, 2.572, 4.644, 6.984, 9.723, 12]; | |
var sig = Array.fill(6, {|i| | |
var i_sig = SinOsc.ar(partials[i]*freq, rrand(0,2pi), (1+(bright*((i/5)-1)))/(i**2.5+1)); | |
var i_env = EnvGen.kr(Env.perc(0.06/(i+1), sustain/(i+1), amp/2), doneAction: (i==0).asInt * 2); | |
i_sig*i_env}).sum; | |
Out.ar(out, Pan2.ar(sig, pan)); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
s.boot; | |
( | |
SynthDef(\monoSampleCrusher, {|buffer, amp, offset, dur, pan, out| | |
var sig, env, length, rate; | |
length = BufFrames.kr(buffer); | |
rate = BufRateScale.kr(buffer); | |
sig = PlayBuf.ar(1, buffer, rate, startPos: offset * length, doneAction: 0); | |
env = EnvGen.kr(Env([amp, amp], [dur]), doneAction: 2); | |
Out.ar(out, Pan2.ar(sig*env, pan)); |
/******************************************* DUST TO DUST asStream, 3/14/2015
Proof of Concept for DataCanvas Sonification
- Make synth from Dust UGen
- Get one previous days worth of dust data
- Use routine to step through data at rate of 30min every 4 seconds
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
s.boot; | |
/******************************************* | |
TUNING AND TIMBRE | |
asStream, 11/27/2015 | |
Explores the theory of William Sethares on | |
the relationship between tuning and timbre. | |
See http://sethares.engr.wisc.edu/consemi.html |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
s.boot; //.DISCUSSION | |
( | |
//AS OF 02:45 PM PST SUNDAY... | |
SynthDef(\click, {|freq=2000, amp=0.1, pan=0, rq=0.5, decay=0.1, out=0| | |
var noise = WhiteNoise.ar(amp); | |
var env = EnvGen.kr(Env.perc(0.001, decay), doneAction: 2); | |
var filter = BPF.ar(noise, freq, rq); | |
var sig = env*filter; | |
Out.ar(out, Pan2.ar(sig, pan)); |