[sc-users] args as integers: outputproxy

Paul vickers northumbria at paulvickers.com
Thu Aug 10 13:09:34 PDT 2006


As we're naming it, perhaps it should be the Cottle-Vickers-houston chime
bell as it's based on the one from Cottle's book! I just changed the number
of partials and the detuning factor! But it does sound nice, doesn't it!

Julian Rohrhuber wrote:
> 
>>it is a really nice example!
>>
>>
>>here is a little smoothing:
>>
>>(
>>SynthDef("bell3", { arg myBellNumber=0, pan=0;
>>  var out,chime, freqSpec, num, burst, totalHarm = 12, klank,
>>    burstEnv, att = 0, seeds, burstLength = MouseY.kr(0.0001, 1);
>>	seeds =  [
>>			0,				// Random bell
>>			1155524954,		// Nice low bell
>>			1155442766,		// Nice clunky bell
>>			1155294420,		// really low bell
>>			1154676704,		// High bell
>>			1155146026		// Mid range
>>	];
>>
>>	RandSeed.kr(myBellNumber, Select.kr(myBellNumber, seeds));
>>
>>	freqSpec = `[
>>		{Rand(1, 30)*(100+Rand(-10.0,10.0))}.dup(totalHarm),
>>		{Rand(0.1, 0.9)}.dup(totalHarm).normalizeSum,
>>		{Rand(1.0, 3.0)}.dup(totalHarm)
>>	];
>>	burstEnv = Env.perc(0, burstLength);
>>	burst = PinkNoise.ar(EnvGen.kr(burstEnv));
>>	klank = Klank.ar(freqSpec, burst);
>>	out = Pan2.ar( // Put in stereo field
>>	  klank * MouseX.kr(0.1, 0.8) ,
>>	  pan);
>>	DetectSilence.ar(out, doneAction:2);
>>	Out.ar(0, out);
>>}).store
>>)
>>
>>Synth(\bell3, [\myBellNumber, 1])
> 
> 
> remember though, that the rand seed is "global". You can choose it with
> RandID.
> Here is a degenerate example:
> 
> // vickers- houston - chimebell
> (
> SynthDef("bell3", { arg out=0, myBellNumber=0, pan=0, amp=0.1;
>   var chime, freqSpec, num, burst, totalHarm = 12, klank,
>     burstEnv, att = 0, seeds, burstLength = MouseY.kr(0.0001, 1);
> 	seeds =  [
> 			0,				// Random bell
> 			1155524954,		// Nice low bell
> 			1155442766,		// Nice clunky bell
> 			1155294420,		// really low bell
> 			1154676704,		// High bell
> 			1155146026		// Mid range
> 	];
> 	//RandID.ir(8); // use generator number 8.
> 	RandSeed.ir(myBellNumber, Select.kr(myBellNumber, seeds));
> 
> 	freqSpec = `[
> 		{Rand(1, 30)*(100+Rand(-10.0,10.0))}.dup(totalHarm),
> 		{Rand(0.1, 0.9)}.dup(totalHarm).normalizeSum,
> 		{Rand(1.0, 3.0)}.dup(totalHarm)
> 	];
> 	burstEnv = Env.perc(0, burstLength, amp);
> 	burst = PinkNoise.ar(EnvGen.kr(burstEnv));
> 	klank = Klank.ar(freqSpec, burst);
> 	klank = Pan2.ar(klank, pan);
> 	klank = klank * Line.kr(1, 0, 0.004, doneAction:2);
> 	DetectSilence.ar(klank, doneAction:2);
> 
> 	Out.ar(out, klank);
> }).store
> )
> 
> Synth(\bell3, [\myBellNumber, 1, \amp, 0.3])
> 
> 
> fork { loop { 0.08.wait; Synth(\bell3, [\myBellNumber, 1, \amp, 0.0]) } };
> 
> { WhiteNoise.ar(0.3) }.play; // the noise is chopped up by determinism
> 
> 
> -- 
> 
> 
> 
> 
> 
> .
> _______________________________________________
> sc-users mailing list
> sc-users at create.ucsb.edu
> http://www.create.ucsb.edu/mailman/listinfo/sc-users
> 
> 

-- 
View this message in context: http://www.nabble.com/args-as-integers%3A-outputproxy-tf2081404.html#a5750539
Sent from the Supercollider - User forum at Nabble.com.



More information about the sc-users mailing list