-
... they result in BinaryOpUGen s or UnaryOpUGen s, through the methods of AbstractFunction . This is a list of some of the common unary and binary operators that are implemented by several classes. See the specific classes for details and oth ...
-
... k = 1; ) // other fixed cycle ~src = 2; p.stop ⧉ ✔ Ex. 8: Proof of concept ( // Function to check an array for repetitions within a maximum test span ~repetitionCheck = { |array, maxTestSpan| maxTestSpan.do { |i| var result = (array.drop(i+ ...
-
... ockUpdate; }); lastTick = timeStamp; } // implement these methods to add custom functionality performFaceChange { //"%: face changed to %".format(this.color, upFace).inform; } performInvisible { // "%: invisible".format(this.color).inform; ...
-
... esetMenu; } initPreview { previewMatrix = ChordtrisMatrix(5, 5, squareSize); // function which is called if the next brick view is refresehed chordtris.nextBrickView.drawFunc = { var chordNameX, chordNameY; Pen.color_(Color.white); Pen.stri ...
-
... ct.keysValuesDo { |key, value| this.perform(key.asSetter, value) } } // utility function unquoteString { |str, pos = 0, delimiter = $", ignoreInParens(false)| var i = str.indexOf(delimiter), j, escaped = false, parenCount = 0; ^if(i.isNil) ...
-
... things you can do to arrays also work with patterns. collect(func) Applies the function to each return value from the pattern. Good for generic transformations. select(func) Preserve values from the output stream that pass the Boolean test ...
-
... t(minIndices, true) }; minIndicesDict.put(indicesQueue.pop, true) }; // yielder function chooses output type yielder = { doSum.if { inval = min.yield; last = min; count = count + 1; }{ last.notNil.if { inval = (min - last).yield; count = co ...
-
... ols to use the server in SuperCollider. To create the resources, Pproto takes a function in which one or more Event objects contain the instructions to create them. These events should use specific event types, described in Pproto's help fi ...
-
... are sent the 'value' message when the Ptpar pattern is started, so you may use functions to specify the times. ( var makePattern, durpat; durpat = Pseq ([ Pgeom (0.05, 1.1, 24), Pgeom (0.5, 0.909, 24) ], 2); makePattern = { arg note, db, p ...
-
... e = [1, 1.5, 3 %/ 5, 8 %/ 5, 1.342]; e.sort; ⧉ ✔ Continued fractions Recursive function to calculate finite continued fractions: f = { | x | if (x == 0) { 1 %/ 1 } { 1 + Rational(1, f.(x-1)) } }; a = 20 collect: f.(_); a.plot; ⧉ ✔ Stern-Br ...