Submit Browse Random
Anonymous Login RSS

SuperCollider Code

All (1643) Code (228) Doc (514) Help (194) Quark (697) Plugin (10) SCDoc ↗ Forum ↗ Google ↗
  1. Sieve1 Doc

    ... initially allocated buffer length -1. { Sieve1.ar(LocalBuf.newFrom([10]++({0.75.rand}!10)),MouseX.kr(2,100))*0.2}.play { Sieve1.ar(LocalBuf.newFrom([88]++({[0.1.rand,0.5.rand].wchoose([0.8,0.2])}!88)),MouseX.kr(1,100))*0.2}.play b = Buffer. ...

  2. SparseArray Doc

    ... b = SparseArray.reduceArray(a, 10); }.bench ) // accessing: { 1000.do{ a[a.size.rand] == 60.rand } }.bench { 1000.do{ b[b.size.rand] == 60.rand } }.bench // setting: { 1000.do{ a[a.size.rand] = 60.rand } }.bench { 1000.do{ b[b.size.rand] = ...

  3. Pen Doc

    ... unc = { Pen.translate(100, 100); 10.do{ // set the Color Pen.color = Color.red(rrand(0.0, 1), rrand(0.0, 0.5)); Pen.addArc((100.rand)@(100.rand), rrand(10, 100), 2pi.rand, pi); Pen.perform([\stroke, \fill].choose); } }; w.refresh; ) ⧉ ✔ Pen ...

  4. Control Doc

    ... nes, control, numsines; numsines = 20; control = Control.names(\array).kr(Array.rand(numsines, 400.0, 1000.0)); sines = Mix(SinOsc.ar(control, 0, numsines.reciprocal)) ; Out.ar(out, sines ! 2); }).add ) b = Synth(\help_Control_Sines); b.set ...

  5. 043-pendulum-render Doc

    ... 0.01); //dim,grav,maxvel,damp //--objects { var loc= RedVector2D[width, height].rand; RedPendulum(world, loc, nil, 0, 4.0.rand, 5.rrand(80)) //world,loc,vel,acc,mass,size .theta_(2pi.rand).angularVel_(0); }.dup(n); //--loop w.draw{ Pen.widt ...

  6. HLayoutView Doc

    ... ll(q, { |i| Slider(h, Rect(0, 0, 20, 75)).value_(i / q) }); h.background_(Color.rand); w.front ) ⧉ ✔ Stretching the layout view; Slider height fills the View automatically: ( q = 8; w = Window.new; h = HLayoutView(w, Rect(0, 0, 300, 300)); ...

  7. 046-pendulum5 Doc

    ... av,maxvel,damp //--objects ypos= 10; while({ypos<(height-10)}, { var size= 50.0.rand; //pendulum size var loc= RedVector2D[width.rand, ypos+size]; var vel= RedVector2D[0.5, 0].rand; var obj= RedPendulum(world, loc, vel, 0, size, size) //wor ...

  8. StaticText Doc

    ... 0, 300, 150)).front; a = StaticText(w, Rect(45, 10, 200, 20)).background_(Color.rand); a.string = " Current Frequency "; Button.new(w, Rect(45, 70, 200, 20)).states_([["close", Color.black, Color.rand]]).action_({ w.close }); s.waitForBoot( ...

  9. Array2D Doc

    ... ve . rows . with ( aarray ) Examples // "a" is an array-of-arrays a = { { 100.0.rand }.dup(100) }.dup(100); // "b" is an equivalent Array2D, made using the "fromArray" class method b = Array2D.fromArray(100, 100, a.flat); // Accessing a[15] ...

  10. 13 Doc

    ... // 最初はCombフィルターで次がAllpassフィルター(パラメータは同じ)。両者を比較せよ。 ( { CombN.ar( SinOsc.ar(500.rrand(1000), 0, 0.2) * Line.kr(1, 0, 0.1), 0.3, 0.25, 6 ) }.scope; ) // 前の例とそんなに大きな違いは無い ( { AllpassN.ar( SinOsc.ar(500.rrand(1000), 0, 0.2) * Line.kr(1, 0, 0.1) ...

prev 1 2 3 4 5 6 7 8 9 10 next

SuperCollider home doc forum wiki git legacy help book

contact | by vividsnow