Deprecated: Assigning the return value of new by reference is deprecated in /home/project-web/supercollider/htdocs/wp-settings.php on line 472

Deprecated: Assigning the return value of new by reference is deprecated in /home/project-web/supercollider/htdocs/wp-settings.php on line 487

Deprecated: Assigning the return value of new by reference is deprecated in /home/project-web/supercollider/htdocs/wp-settings.php on line 494

Deprecated: Assigning the return value of new by reference is deprecated in /home/project-web/supercollider/htdocs/wp-settings.php on line 530

Strict Standards: Declaration of Walker_Page::start_lvl() should be compatible with Walker::start_lvl(&$output) in /home/project-web/supercollider/htdocs/wp-includes/classes.php on line 594

Strict Standards: Declaration of Walker_Page::end_lvl() should be compatible with Walker::end_lvl(&$output) in /home/project-web/supercollider/htdocs/wp-includes/classes.php on line 594

Strict Standards: Declaration of Walker_Page::start_el() should be compatible with Walker::start_el(&$output) in /home/project-web/supercollider/htdocs/wp-includes/classes.php on line 594

Strict Standards: Declaration of Walker_Page::end_el() should be compatible with Walker::end_el(&$output) in /home/project-web/supercollider/htdocs/wp-includes/classes.php on line 594

Strict Standards: Declaration of Walker_PageDropdown::start_el() should be compatible with Walker::start_el(&$output) in /home/project-web/supercollider/htdocs/wp-includes/classes.php on line 611

Strict Standards: Declaration of Walker_Category::start_lvl() should be compatible with Walker::start_lvl(&$output) in /home/project-web/supercollider/htdocs/wp-includes/classes.php on line 705

Strict Standards: Declaration of Walker_Category::end_lvl() should be compatible with Walker::end_lvl(&$output) in /home/project-web/supercollider/htdocs/wp-includes/classes.php on line 705

Strict Standards: Declaration of Walker_Category::start_el() should be compatible with Walker::start_el(&$output) in /home/project-web/supercollider/htdocs/wp-includes/classes.php on line 705

Strict Standards: Declaration of Walker_Category::end_el() should be compatible with Walker::end_el(&$output) in /home/project-web/supercollider/htdocs/wp-includes/classes.php on line 705

Strict Standards: Declaration of Walker_CategoryDropdown::start_el() should be compatible with Walker::start_el(&$output) in /home/project-web/supercollider/htdocs/wp-includes/classes.php on line 728

Strict Standards: Redefining already defined constructor for class wpdb in /home/project-web/supercollider/htdocs/wp-includes/wp-db.php on line 306

Deprecated: Assigning the return value of new by reference is deprecated in /home/project-web/supercollider/htdocs/wp-includes/cache.php on line 103

Strict Standards: Redefining already defined constructor for class WP_Object_Cache in /home/project-web/supercollider/htdocs/wp-includes/cache.php on line 425

Deprecated: Assigning the return value of new by reference is deprecated in /home/project-web/supercollider/htdocs/wp-includes/query.php on line 21

Deprecated: Assigning the return value of new by reference is deprecated in /home/project-web/supercollider/htdocs/wp-includes/theme.php on line 623

Strict Standards: Redefining already defined constructor for class WP_Dependencies in /home/project-web/supercollider/htdocs/wp-includes/class.wp-dependencies.php on line 15

Strict Standards: Only variables should be assigned by reference in /home/project-web/supercollider/htdocs/wp-includes/post.php on line 218

Strict Standards: Only variables should be assigned by reference in /home/project-web/supercollider/htdocs/wp-includes/query.php on line 751
SuperCollider » Audio/code examples

Warning: mktime(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/project-web/supercollider/htdocs/wp-includes/functions.php on line 41

Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/project-web/supercollider/htdocs/wp-includes/functions.php on line 50

Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/project-web/supercollider/htdocs/wp-includes/functions.php on line 52

Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/project-web/supercollider/htdocs/wp-includes/functions.php on line 54

Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/project-web/supercollider/htdocs/wp-includes/functions.php on line 55

Warning: mktime(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/project-web/supercollider/htdocs/wp-includes/functions.php on line 41

Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/project-web/supercollider/htdocs/wp-includes/functions.php on line 50

Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/project-web/supercollider/htdocs/wp-includes/functions.php on line 52

Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/project-web/supercollider/htdocs/wp-includes/functions.php on line 54

Warning: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone 'UTC' for now, but please set date.timezone to select your timezone. in /home/project-web/supercollider/htdocs/wp-includes/functions.php on line 55

Audio/code examples

User-submitted audio from the SuperCollider Soundcloud group:


And some brief examples with code:


Audio clip: Adobe Flash Player (version 9 or above) is required to play this audio clip. Download the latest version here. You also need to have JavaScript enabled in your browser.

Example #3 from www.audiosynth.com


Audio clip: Adobe Flash Player (version 9 or above) is required to play this audio clip. Download the latest version here. You also need to have JavaScript enabled in your browser.

Some automatic generative beat-slicing, made by running the “cutattack” helpfile from Nick Collins’ BBCut2 library.


Audio clip: Adobe Flash Player (version 9 or above) is required to play this audio clip. Download the latest version here. You also need to have JavaScript enabled in your browser.

A babbling brook by James McCartney 2007.

{
({RHPF.ar(OnePole.ar(BrownNoise.ar, 0.99), LPF.ar(BrownNoise.ar, 14)
* 400 + 500, 0.03, 0.003)}!2)
+ ({RHPF.ar(OnePole.ar(BrownNoise.ar, 0.99), LPF.ar(BrownNoise.ar, 20)
* 800 + 1000, 0.03, 0.005)}!2)
* 4
}.play


Audio clip: Adobe Flash Player (version 9 or above) is required to play this audio clip. Download the latest version here. You also need to have JavaScript enabled in your browser.

This one-liner by Lance Putnam is an example of SuperCollider’s expressive power. It modulates the pitch of a single sine-wave oscillator.

play{SinOsc.ar(OnePole.ar(Mix(
LFSaw.ar([1,0.99],[0,0.6],2000,2000).trunc([400,600])*[1,-1]
),0.98)).dup*0.1}


Audio clip: Adobe Flash Player (version 9 or above) is required to play this audio clip. Download the latest version here. You also need to have JavaScript enabled in your browser.

A quick demo of Fredrik Olofsson’s Atari 2600 plugin. This lovely 8-bit tune is based on an example in the helpfile.

// Simple synth definition using the Atari2600 UGen:
(
SynthDef(\atari2600, {|out= 0, gate= 1, tone0= 5,
tone1= 8, freq0= 10, freq1= 20, amp= 1, pan= 0|
var e, z;
e= EnvGen.kr(Env.asr(0.01, amp, 0.05), gate, doneAction:2);
z= Atari2600.ar(tone0, tone1, freq0, freq1, 15, 15);
Out.ar(out, Pan2.ar(z*e, pan));
}).store
)

// And a pattern to play it:
(
Pbind(
\instrument, \atari2600,
\dur, Pseq([0.25, 0.25, 0.25, 0.45], inf),
\amp, 0.8,
\tone0, Pseq([Pseq([2, 5], 32), Pseq([3, 5], 32)], inf),
\tone1, 14,
\freq0, Pseq([Pbrown(28, 31, 1, 32),
Pbrown(23, 26, 3, 32)], inf),
\freq1, Pseq([Pn(10, 16), Pn(11, 16)], inf)
).play
)


Audio clip: Adobe Flash Player (version 9 or above) is required to play this audio clip. Download the latest version here. You also need to have JavaScript enabled in your browser.

A brief snippet of this generative piece:

// hamburg soft frog loops, by Julian Rohrhuber July 2005
// Published under the Creative Commons licence
// creativecommons.org/licenses/by/2.0/
(
[\kr, \ar].do { |x|
SynthDef(”softfrog_”++x, {
arg out, freq=440, prate=180, pwidth=0.5,
sustain=0.3, amp=0.1;
var env, u;
env = Env.linen(Rand(0.001, 0.003), Rand(0.1, 0.3), 0.01);
freq = freq + LFNoise2.kr(5, 10);
u = SinOsc.ar(
freq,
LFPulse.perform(x,
prate,
0,
Line.kr(pwidth, 0, sustain)
),
amp
);
u = BRF.ar(u, freq, 0.1) * EnvGen.kr(env, doneAction:2);
Out.ar(out, Pan2.ar(u, Rand(-1,1)))
}).store;

};
)

(
var arr, arr2, arr3, arr4, arfill, prob, node1, node2;
var dt = 1/8;
var n = 16;
arfill = { arr = Array.fill(n div: 2, { 180 + 180.5.rand2 }) };
arr2 = Array.fill(n, { rrand(1, pi) });
arr3 = Array.fill(n, { 1300 + 100.rand2 });
arr4 = Array.fill(n, {
if(0.6.coin, { 0.5.rand } , { 0.1.rand }) });
prob = [4,1].normalizeSum;

node1 = NodeProxy.audio(s, 2);
node2 = NodeProxy.audio(s, 2);
node2.source = { RLPF.ar(node1.ar, LFNoise2.kr(3).range(300,
MouseY.kr(300, 10000, 1)), 0.5) };
node2.play;

fork {
inf.do {|i|
if(i % 64 == 0) { arfill.value };
Synth(["softfrog_kr", "softfrog_ar"].wchoose(prob),
[
\out, node1.index,
\freq, arr3 @@ i,
\prate, arr @@ i,
\pwidth, arr2 @@ i,
\amp, arr4 @@ i
]
);
dt.wait;
}
};

CmdPeriod.doOnce { node2.clear; node1.clear };
)


Audio clip: Adobe Flash Player (version 9 or above) is required to play this audio clip. Download the latest version here. You also need to have JavaScript enabled in your browser.

An illustration of granular synthesis, using SuperCollider’s TGrains unit-generator. (The example is based on code in the TGrains helpfile.)

// Boot the server
s.boot;

// Load an audio file
s.sendMsg(\b_allocRead, 10, “sounds/a11wlk01.wav”);

// Now define the granular synth
(
{
var b = 10, trate, dur;
trate = MouseY.kr(2,120,1);
dur = 1.2 / trate;
TGrains.ar(2, Impulse.ar(trate), b,
(1.2 ** WhiteNoise.kr(3).round(1)),
MouseX.kr(0,BufDur.kr(b)),
dur,
WhiteNoise.kr(0.6), 0.1);
}.play;
)

Share and Enjoy:
  • Digg
  • del.icio.us
  • Facebook
  • Google
  • StumbleUpon
  • Technorati
  • Slashdot