-
... annels: 1, bufnum: 1, rate: rate, startPos: startPos.linlin(1, 10 , 0, BufFrames.kr(buffer)) ); snd = Pan2.ar(snd, panning); Out.ar(0, snd); }).add; ) ) (~granny2= ( SynthDef("granny1", {arg ...
-
... erES = k[\sl][page][1].enIn; freqSig = ({ |zoom, slider| if(zoom != 0) { slider.linlin(0.0,1.0,zoom-0.1,zoom+0.1) } { slider } } <%> zoom <@> freqSliderES) .hold(0.5) .enDebug("freq"); freq = freqSig.enKrUni(lag: 0.1, spec: \freq.asSpec, ke ...
-
... alue_(1) y.value_(2) z = Var(0.5) z.value_(0.4) r = z.nlin(x,y).do(_.postln) */ linlin { |inMin, inMax, outMin, outMax, clip=\minmax| ^{ |inMin, inMax,outMin,outMax,val| val.linlin(inMin, inMax, outMin, outMax, clip) } .lift.(inMin.asFPSign ...
-
... ointCoordX) ? breakPointCoords.size; env.levels = env.levels.insert(insertInd,y.linlin(0,me.bounds.height,maxRange,minRange)); env.times = (insertInd == 1).if { env.times.insert(0,breakPointTime) } { env.times.insert(insertInd - 1,breakPoin ...
-
... ths[i] = [sources[i], freqs].flopWith{ |j, freq| Synth(q.names[j], [\freq, freq.linlin(0.0,1.0,300,2000)]) }; } }; q.stopSynths = { |i| IO{ q.synths[i].do(_.release); q.synths[i] = [] } }; q.setFreq = { |i, freqs| IO{ [q.synths[i], freqs].f ...
-
... // "move mode vis".postln; star = g.main.movevals.collect { |val, i| Polar(val.linlin( 0, 1, 40, 240), i / 9 * 2pi).asPoint + center; }; // star.postln; Pen.color = Color.yellow; Pen.width = 3; star.wrapExtend(10).doAdjacentPairs { |p1, p2 ...
-
... GridSize; } calculateNearestPoint { |mousePos| nearestPoint = Point( mousePos.x.linlin( this.interactionRect.left, this.interactionRect.right, 0, thisGridSize.x ).round(1), mousePos.y.linlin( this.interactionRect.top, this.interactionRect.b ...
-
... arr[index+1] +1 * 300 ), 20, 20)).string_( "x" ).background_(~cols[arr[index+2].linlin(-1, 1, 0, ~cols.size-1)]) // SCStaticText }; w.front; }.defer}) ) // Or if you have OctaveSC you can plot a very nice 3D mesh: o = OctaveSC .new; o.init; ...
-
... r function, create the data at 1/2 buffer size + 1 t = Signal.fill(513, { |i| i.linlin(0.0, 512.0, -1.0, 1.0) }); // linear function t.plot // t.asWavetable will convert it to the official Wavetable format at twice the size b.sendCollection ...
-
... -1, 1 ); scaleValue = { |val, fr, mode = \none| if ( abs(curve) < 0.001 ) { val.linlin( *fr ++ [ -1, 1, mode ] ); } { val.lincurve( *fr ++ [ -1, 1, curve, mode ] ); }; }; switch( clipMode, \clip, { value = scaleValue.value( value, fromRange ...