diff options
author | Travis CI <zmoelnig@travis-ci.umlaeute.mur.at> | 2015-03-14 20:32:26 +0000 |
---|---|---|
committer | Travis CI <zmoelnig@travis-ci.umlaeute.mur.at> | 2015-03-14 20:32:26 +0000 |
commit | c6030846f5c1e34048774d60ca4c15e804bee839 (patch) | |
tree | fb75f89275a78ea383c0fd64e8fe5b3ae57cc898 /Gem/examples/13.recursion |
Gem linux/amd64
built '' for linux/amd64
Diffstat (limited to 'Gem/examples/13.recursion')
-rw-r--r-- | Gem/examples/13.recursion/01.repetition_is_futile.pd | 61 | ||||
-rw-r--r-- | Gem/examples/13.recursion/02.iteration_is_insufficient.pd | 33 | ||||
-rw-r--r-- | Gem/examples/13.recursion/03.recursive_spiral.pd | 71 | ||||
-rw-r--r-- | Gem/examples/13.recursion/04.binary_tree.pd | 98 | ||||
-rw-r--r-- | Gem/examples/13.recursion/05.n-ary_tree.pd | 81 | ||||
-rw-r--r-- | Gem/examples/13.recursion/06.breaking_symmetry.pd | 384 | ||||
-rw-r--r-- | Gem/examples/13.recursion/README | 23 | ||||
-rw-r--r-- | Gem/examples/13.recursion/nnrepeat-help.pd | 28 | ||||
-rw-r--r-- | Gem/examples/13.recursion/nnrepeat-test.pd | 55 | ||||
-rw-r--r-- | Gem/examples/13.recursion/nnrepeat.pd | 27 | ||||
-rw-r--r-- | Gem/examples/13.recursion/nrepeat-help.pd | 25 | ||||
-rw-r--r-- | Gem/examples/13.recursion/nrepeat-test.pd | 46 | ||||
-rw-r--r-- | Gem/examples/13.recursion/nrepeat.pd | 49 | ||||
-rw-r--r-- | Gem/examples/13.recursion/stack-help.pd | 20 | ||||
-rw-r--r-- | Gem/examples/13.recursion/stack.pd | 38 | ||||
-rw-r--r-- | Gem/examples/13.recursion/xform-gui.pd | 120 |
16 files changed, 1159 insertions, 0 deletions
diff --git a/Gem/examples/13.recursion/01.repetition_is_futile.pd b/Gem/examples/13.recursion/01.repetition_is_futile.pd new file mode 100644 index 0000000..2fe7232 --- /dev/null +++ b/Gem/examples/13.recursion/01.repetition_is_futile.pd @@ -0,0 +1,61 @@ +#N canvas 0 0 602 516 10; +#X obj 14 66 gemwin; +#X obj 14 9 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0 1 +; +#X msg 48 10 create; +#X msg 55 33 destroy; +#X obj 14 93 gemhead; +#X obj 14 123 t a a; +#X obj 59 123 circle; +#X obj 14 153 separator; +#X obj 14 213 scale 0.7; +#X obj 14 173 rotate 45 0 0 1; +#X obj 14 243 t a a; +#X obj 59 243 circle; +#X obj 14 273 separator; +#X obj 14 333 scale 0.7; +#X obj 14 293 rotate 45 0 0 1; +#X obj 14 363 t a a; +#X obj 59 363 circle; +#X obj 14 193 translate 2 0 1 0; +#X obj 14 313 translate 2 0 1 0; +#X obj 14 393 separator; +#X obj 14 453 scale 0.7; +#X obj 14 413 rotate 45 0 0 1; +#X obj 14 433 translate 2 0 1 0; +#X obj 14 483 t a a; +#X obj 59 483 circle; +#X text 170 17 A tutorial on recursion in Gem; +#X text 170 37 (GPL) 2007 Claude Heiland-Allen <claude@mathr.co.uk> +; +#X text 170 77 The simplest and most obvious way of working with Gem +is to create all the objects statically. That is \, the Gem chain (or +tree) is exactly what is visible in the patch.; +#X text 170 127 Say we way we want to make a spiral of circles. Even +with just 4 circles the repetition is painfully obvious \, and if we +wanted more the duplication would be painfully tedious.; +#X text 170 177 There is a powerful way to avoid this pain \, however +\, using recursion.; +#X connect 1 0 0 0; +#X connect 2 0 0 0; +#X connect 3 0 0 0; +#X connect 4 0 5 0; +#X connect 5 0 7 0; +#X connect 5 1 6 0; +#X connect 7 0 9 0; +#X connect 8 0 10 0; +#X connect 9 0 17 0; +#X connect 10 0 12 0; +#X connect 10 1 11 0; +#X connect 12 0 14 0; +#X connect 13 0 15 0; +#X connect 14 0 18 0; +#X connect 15 0 19 0; +#X connect 15 1 16 0; +#X connect 17 0 8 0; +#X connect 18 0 13 0; +#X connect 19 0 21 0; +#X connect 20 0 23 0; +#X connect 21 0 22 0; +#X connect 22 0 20 0; +#X connect 23 1 24 0; diff --git a/Gem/examples/13.recursion/02.iteration_is_insufficient.pd b/Gem/examples/13.recursion/02.iteration_is_insufficient.pd new file mode 100644 index 0000000..fad24c1 --- /dev/null +++ b/Gem/examples/13.recursion/02.iteration_is_insufficient.pd @@ -0,0 +1,33 @@ +#N canvas 0 0 602 259 10; +#X obj 14 66 gemwin; +#X obj 14 9 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0 1 +; +#X msg 48 10 create; +#X msg 55 33 destroy; +#X obj 14 93 gemhead; +#X obj 14 153 t a a; +#X obj 59 153 circle; +#X obj 14 223 scale 0.7; +#X obj 14 183 rotate 45 0 0 1; +#X obj 14 203 translate 2 0 1 0; +#X text 170 17 A tutorial on recursion in Gem; +#X text 170 37 (GPL) 2007 Claude Heiland-Allen <claude@mathr.co.uk> +; +#X text 170 77 A common idiom in Gem is to use the [repeat] object +found in the Zexy library \, to generate multiple copies of the same +object. Let's try using it to make our spiral.; +#X obj 14 123 repeat 64; +#X text 170 127 And indeed \, it works well. But a spiral is a linear +structure \, without branches. Iteration has solved one problem \, +only to present us with another: what if we want a branching structure? +; +#X text 170 187 Recursion is an elegant solution to this problem.; +#X connect 1 0 0 0; +#X connect 2 0 0 0; +#X connect 3 0 0 0; +#X connect 4 0 13 0; +#X connect 5 0 8 0; +#X connect 5 1 6 0; +#X connect 8 0 9 0; +#X connect 9 0 7 0; +#X connect 13 0 5 0; diff --git a/Gem/examples/13.recursion/03.recursive_spiral.pd b/Gem/examples/13.recursion/03.recursive_spiral.pd new file mode 100644 index 0000000..2783fc8 --- /dev/null +++ b/Gem/examples/13.recursion/03.recursive_spiral.pd @@ -0,0 +1,71 @@ +#N canvas 3 2 602 516 10; +#X obj 14 66 gemwin; +#X obj 14 9 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0 1 +; +#X msg 48 10 create; +#X msg 55 33 destroy; +#X obj 14 93 gemhead; +#X obj 14 213 t a a; +#X obj 59 213 circle; +#X obj 14 283 scale 0.7; +#X obj 14 243 rotate 45 0 0 1; +#X obj 14 263 translate 2 0 1 0; +#X text 170 17 A tutorial on recursion in Gem; +#X text 170 37 (GPL) 2007 Claude Heiland-Allen <claude@mathr.co.uk> +; +#X text 170 77 A common idiom in Gem is to use the [repeat] object +found in the Zexy library \, to generate multiple copies of the same +object. Let's try using it to make our spiral.; +#X obj 14 183 separator; +#X obj 24 163 r \$0-recurse; +#X obj 68 133 v \$0-depth; +#X obj 14 113 t a b; +#X obj 68 113 f 16; +#X floatatom 91 96 5 0 0 2 max-depth - -; +#X obj 36 433 s \$0-recurse; +#X obj 14 313 t b a b; +#X obj 99 343 v \$0-depth; +#X obj 99 363 - 1; +#X obj 99 383 max 0; +#X obj 99 403 v \$0-depth; +#X obj 36 413 spigot; +#X obj 14 343 v \$0-depth; +#X obj 14 383 v \$0-depth; +#X obj 14 363 + 1; +#X text 170 127 First \, we need to limit the depth of the recursion +\, to avoid the dreaded "stack overflow" errors from both Pd and OpenGL. +We set the maximum depth before doing anything else in the Gem chain. +; +#X text 170 187 Next \, we draw the circle and set up the transformations +for the recursive call.; +#X text 170 227 Finally \, we check that we are within the allowed +depth \, and recurse (after decrementing the maximum depth).; +#X text 170 267 At first glance \, this recursive solution is much +less elegant than the iterative solution with [repeat] \, and it is +-- for non-branching structures. The power of recursion comes from +the ease with which branching structures can be created.; +#X connect 1 0 0 0; +#X connect 2 0 0 0; +#X connect 3 0 0 0; +#X connect 4 0 16 0; +#X connect 5 0 8 0; +#X connect 5 1 6 0; +#X connect 7 0 20 0; +#X connect 8 0 9 0; +#X connect 9 0 7 0; +#X connect 13 0 5 0; +#X connect 14 0 13 0; +#X connect 16 0 13 0; +#X connect 16 1 17 0; +#X connect 17 0 15 0; +#X connect 18 0 17 1; +#X connect 20 0 26 0; +#X connect 20 1 25 0; +#X connect 20 2 21 0; +#X connect 21 0 22 0; +#X connect 22 0 23 0; +#X connect 23 0 24 0; +#X connect 23 0 25 1; +#X connect 25 0 19 0; +#X connect 26 0 28 0; +#X connect 28 0 27 0; diff --git a/Gem/examples/13.recursion/04.binary_tree.pd b/Gem/examples/13.recursion/04.binary_tree.pd new file mode 100644 index 0000000..ef8f69f --- /dev/null +++ b/Gem/examples/13.recursion/04.binary_tree.pd @@ -0,0 +1,98 @@ +#N canvas 3 2 602 516 10; +#X obj 14 66 gemwin; +#X obj 14 9 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0 1 +; +#X msg 48 10 create; +#X msg 55 33 destroy; +#X obj 14 93 gemhead; +#X text 170 17 A tutorial on recursion in Gem; +#X text 170 37 (GPL) 2007 Claude Heiland-Allen <claude@mathr.co.uk> +; +#X obj 24 163 r \$0-recurse; +#X obj 68 133 v \$0-depth; +#X obj 14 113 t a b; +#X floatatom 91 96 5 0 0 2 max-depth - -; +#X obj 14 253 t a a; +#X obj 59 253 circle; +#X obj 14 223 separator; +#X obj 36 473 s \$0-recurse; +#X obj 14 353 t b a b; +#X obj 99 383 v \$0-depth; +#X obj 99 403 - 1; +#X obj 99 423 max 0; +#X obj 99 443 v \$0-depth; +#X obj 36 453 spigot; +#X obj 14 383 v \$0-depth; +#X obj 14 423 v \$0-depth; +#X obj 14 403 + 1; +#X obj 184 253 t a a; +#X obj 229 253 circle; +#X obj 206 473 s \$0-recurse; +#X obj 184 353 t b a b; +#X obj 269 383 v \$0-depth; +#X obj 269 403 - 1; +#X obj 269 423 max 0; +#X obj 269 443 v \$0-depth; +#X obj 206 453 spigot; +#X obj 184 383 v \$0-depth; +#X obj 184 423 v \$0-depth; +#X obj 184 403 + 1; +#X obj 184 223 separator; +#X obj 14 183 t a a; +#X obj 184 303 translate 1.5 0 1 0; +#X obj 184 323 scale 0.5; +#X obj 14 323 scale 0.5; +#X obj 14 303 translate 1.5 0 1 0; +#X obj 14 283 rotate -30 0 0 1; +#X obj 184 283 rotate 30 0 0 1; +#X obj 68 113 f 4; +#X text 170 77 The simplest recursive branching structure is one that +splits into two at each branch. Essentially what we are creating is +a circle \, plus two transformed copies of the whole structure \, limited +to a maximums depth of recursion.; +#X text 170 137 Be careful not to increase the max-depth too much: +the splitting at each recursion leads to an exponential increase in +the number of circles to be drawn.; +#X connect 1 0 0 0; +#X connect 2 0 0 0; +#X connect 3 0 0 0; +#X connect 4 0 9 0; +#X connect 7 0 37 0; +#X connect 9 0 37 0; +#X connect 9 1 44 0; +#X connect 10 0 44 1; +#X connect 11 0 42 0; +#X connect 11 1 12 0; +#X connect 13 0 11 0; +#X connect 15 0 21 0; +#X connect 15 1 20 0; +#X connect 15 2 16 0; +#X connect 16 0 17 0; +#X connect 17 0 18 0; +#X connect 18 0 19 0; +#X connect 18 0 20 1; +#X connect 20 0 14 0; +#X connect 21 0 23 0; +#X connect 23 0 22 0; +#X connect 24 0 43 0; +#X connect 24 1 25 0; +#X connect 27 0 33 0; +#X connect 27 1 32 0; +#X connect 27 2 28 0; +#X connect 28 0 29 0; +#X connect 29 0 30 0; +#X connect 30 0 31 0; +#X connect 30 0 32 1; +#X connect 32 0 26 0; +#X connect 33 0 35 0; +#X connect 35 0 34 0; +#X connect 36 0 24 0; +#X connect 37 0 13 0; +#X connect 37 1 36 0; +#X connect 38 0 39 0; +#X connect 39 0 27 0; +#X connect 40 0 15 0; +#X connect 41 0 40 0; +#X connect 42 0 41 0; +#X connect 43 0 38 0; +#X connect 44 0 8 0; diff --git a/Gem/examples/13.recursion/05.n-ary_tree.pd b/Gem/examples/13.recursion/05.n-ary_tree.pd new file mode 100644 index 0000000..91d0565 --- /dev/null +++ b/Gem/examples/13.recursion/05.n-ary_tree.pd @@ -0,0 +1,81 @@ +#N canvas 3 2 600 605 10; +#X obj 14 66 gemwin; +#X obj 14 9 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0 1 +; +#X msg 48 10 create; +#X msg 55 33 destroy; +#X obj 14 93 gemhead; +#X text 170 17 A tutorial on recursion in Gem; +#X text 170 37 (GPL) 2007 Claude Heiland-Allen <claude@mathr.co.uk> +; +#X obj 30 159 r \$0-recurse; +#X obj 68 133 v \$0-depth; +#X obj 14 113 t a b; +#X floatatom 84 70 5 0 0 2 max-depth - -; +#X obj 14 187 t a a; +#X obj 60 188 circle; +#X obj 14 325 separator; +#X obj 36 536 s \$0-recurse; +#X obj 14 416 t b a b; +#X obj 99 446 v \$0-depth; +#X obj 99 466 - 1; +#X obj 99 486 max 0; +#X obj 99 506 v \$0-depth; +#X obj 36 516 spigot; +#X obj 14 446 v \$0-depth; +#X obj 14 486 v \$0-depth; +#X obj 14 466 + 1; +#X obj 68 113 f 4; +#X obj 14 346 rotate 0 0 0 1; +#X obj 126 303 * 72; +#X obj 14 366 translate 2 0 1 0; +#X obj 14 386 scale 0.35; +#X obj 14 270 nrepeat 5; +#X obj 119 236 t f f; +#X floatatom 118 196 5 0 0 2 count - -; +#X obj 149 259 swap 360; +#X obj 149 282 /; +#X obj 118 215 clip 1 16; +#X obj 84 89 clip 1 6; +#X text 170 77 Recursion can be combined with iteration to make complex +structures. However \, using the [repeat] from Zexy is no longer enough. +Trying to use it with an external counter leads to re-entrancy bugs +\, because the [repeat] is retriggered before the counter has finished +\, which messes up the counter's internal state. [nrepeat] is a "repeat +with a built in counter" \, which is re-entrancy safe.; +#X connect 1 0 0 0; +#X connect 2 0 0 0; +#X connect 3 0 0 0; +#X connect 4 0 9 0; +#X connect 7 0 11 0; +#X connect 9 0 11 0; +#X connect 9 1 24 0; +#X connect 10 0 35 0; +#X connect 11 0 29 0; +#X connect 11 1 12 0; +#X connect 13 0 25 0; +#X connect 15 0 21 0; +#X connect 15 1 20 0; +#X connect 15 2 16 0; +#X connect 16 0 17 0; +#X connect 17 0 18 0; +#X connect 18 0 19 0; +#X connect 18 0 20 1; +#X connect 20 0 14 0; +#X connect 21 0 23 0; +#X connect 23 0 22 0; +#X connect 24 0 8 0; +#X connect 25 0 27 0; +#X connect 26 0 25 1; +#X connect 27 0 28 0; +#X connect 28 0 15 0; +#X connect 29 0 13 0; +#X connect 29 1 26 0; +#X connect 30 0 29 1; +#X connect 30 1 32 0; +#X connect 31 0 34 0; +#X connect 32 0 33 0; +#X connect 32 1 33 1; +#X connect 33 0 26 1; +#X connect 34 0 30 0; +#X connect 35 0 24 1; diff --git a/Gem/examples/13.recursion/06.breaking_symmetry.pd b/Gem/examples/13.recursion/06.breaking_symmetry.pd new file mode 100644 index 0000000..c409aaf --- /dev/null +++ b/Gem/examples/13.recursion/06.breaking_symmetry.pd @@ -0,0 +1,384 @@ +#N canvas 4 2 673 560 10; +#X obj 14 66 gemwin; +#X obj 14 9 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0 1 +; +#X msg 55 33 destroy; +#X obj 14 92 gemhead; +#X text 220 17 A tutorial on recursion in Gem; +#X text 220 37 (GPL) 2007 Claude Heiland-Allen <claude@mathr.co.uk> +; +#X obj 30 273 r \$0-recurse; +#X obj 14 301 t a a; +#X floatatom 72 360 5 0 0 2 count - -; +#X obj 72 379 clip 1 6; +#N canvas 0 0 368 384 \$0-transformations 0; +#X obj 19 19 inlet; +#X obj 250 19 inlet; +#X obj 19 343 outlet; +#X text 299 20 count; +#X text 72 19 gem; +#X text 74 344 gem; +#X obj 19 44 separator; +#X obj 19 315 scaleXYZ; +#X obj 19 225 translateXYZ; +#X obj 19 135 rotateXYZ; +#X obj 38 74 tabread \$0-rotate-X; +#X obj 57 94 tabread \$0-rotate-Y; +#X obj 77 114 tabread \$0-rotate-Z; +#X obj 45 164 tabread \$0-translate-X; +#X obj 71 184 tabread \$0-translate-Y; +#X obj 98 204 tabread \$0-translate-Z; +#X obj 36 254 tabread \$0-scale-X; +#X obj 53 274 tabread \$0-scale-Y; +#X obj 70 294 tabread \$0-scale-Z; +#X text 135 230 Transform the recursion branch \,; +#X connect 0 0 6 0; +#X connect 1 0 10 0; +#X connect 1 0 11 0; +#X connect 1 0 12 0; +#X connect 1 0 13 0; +#X connect 1 0 14 0; +#X connect 1 0 15 0; +#X connect 1 0 16 0; +#X connect 1 0 17 0; +#X connect 1 0 18 0; +#X connect 6 0 9 0; +#X connect 7 0 2 0; +#X connect 8 0 7 0; +#X connect 9 0 8 0; +#X connect 10 0 9 1; +#X connect 11 0 9 2; +#X connect 12 0 9 3; +#X connect 13 0 8 1; +#X connect 14 0 8 2; +#X connect 15 0 8 3; +#X connect 16 0 7 1; +#X connect 17 0 7 2; +#X connect 18 0 7 3; +#X restore 63 442 pd \$0-transformations; +#N canvas 0 0 679 337 \$0-colourize-and-limit-depth 0; +#X obj 297 19 inlet; +#X obj 293 298 outlet; +#X text 343 299 gem; +#X text 347 21 gem; +#X obj 436 18 inlet; +#X text 487 18 count; +#X obj 352 171 v \$0-depth; +#X obj 352 191 - 1; +#X obj 352 211 max 0; +#X obj 352 231 v \$0-depth; +#X obj 294 246 spigot; +#X obj 264 174 v \$0-depth; +#X obj 264 214 v \$0-depth; +#X obj 264 194 + 1; +#X obj 436 189 v \$0-R; +#X obj 436 229 v \$0-R; +#X obj 486 189 v \$0-G; +#X obj 486 229 v \$0-G; +#X obj 536 229 v \$0-B; +#X obj 536 189 v \$0-B; +#X obj 436 71 tabread \$0-colour-R; +#X obj 486 105 tabread \$0-colour-G; +#X obj 536 128 tabread \$0-colour-B; +#X text 442 248 Transform colours.; +#X text 251 271 Limit recursion depth.; +#X obj 536 209 + 1; +#X obj 486 209 + 1; +#X obj 435 209 + 1; +#X obj 297 52 t b a b; +#X obj 436 167 t b f; +#X obj 486 167 t b f; +#X obj 536 167 t b f; +#X obj 46 18 inlet; +#X text 97 18 count; +#X obj 46 189 v \$0-R; +#X obj 46 229 v \$0-R; +#X obj 96 189 v \$0-G; +#X obj 96 229 v \$0-G; +#X obj 146 229 v \$0-B; +#X obj 146 189 v \$0-B; +#X obj 46 71 tabread \$0-colour-R; +#X obj 96 105 tabread \$0-colour-G; +#X obj 146 128 tabread \$0-colour-B; +#X obj 46 167 t b f; +#X obj 96 167 t b f; +#X obj 146 167 t b f; +#X text 52 252 Untransform colours.; +#X obj 45 209 - 1; +#X obj 96 209 - 1; +#X obj 146 209 - 1; +#X connect 0 0 28 0; +#X connect 4 0 20 0; +#X connect 4 0 21 0; +#X connect 4 0 22 0; +#X connect 6 0 7 0; +#X connect 7 0 8 0; +#X connect 8 0 9 0; +#X connect 8 0 10 1; +#X connect 10 0 1 0; +#X connect 11 0 13 0; +#X connect 13 0 12 0; +#X connect 14 0 27 0; +#X connect 16 0 26 0; +#X connect 19 0 25 0; +#X connect 20 0 29 0; +#X connect 21 0 30 0; +#X connect 22 0 31 0; +#X connect 25 0 18 0; +#X connect 26 0 17 0; +#X connect 27 0 15 0; +#X connect 28 0 11 0; +#X connect 28 1 10 0; +#X connect 28 2 6 0; +#X connect 29 0 14 0; +#X connect 29 1 27 1; +#X connect 30 0 16 0; +#X connect 30 1 26 1; +#X connect 31 0 19 0; +#X connect 31 1 25 1; +#X connect 32 0 40 0; +#X connect 32 0 41 0; +#X connect 32 0 42 0; +#X connect 34 0 47 0; +#X connect 36 0 48 0; +#X connect 39 0 49 0; +#X connect 40 0 43 0; +#X connect 41 0 44 0; +#X connect 42 0 45 0; +#X connect 43 0 34 0; +#X connect 43 1 47 1; +#X connect 44 0 36 0; +#X connect 44 1 48 1; +#X connect 45 0 39 0; +#X connect 45 1 49 1; +#X connect 47 0 35 0; +#X connect 48 0 37 0; +#X connect 49 0 38 0; +#X restore 14 479 pd \$0-colourize-and-limit-depth; +#X obj 14 499 s \$0-recurse; +#X obj 14 223 t a b; +#N canvas 22 26 435 181 \$0-initialize 0; +#X obj 23 20 inlet; +#X text 68 19 bang; +#X obj 23 122 v \$0-depth; +#X obj 23 102 f 4; +#X obj 103 122 v \$0-R; +#X obj 153 122 v \$0-G; +#X obj 203 122 v \$0-B; +#X obj 160 21 inlet; +#X text 205 20 max depth; +#X text 18 146 Initialize the variables: recursion depth and object +colours.; +#X obj 203 98 f 0; +#X obj 153 99 f 0; +#X obj 103 98 f 0; +#X connect 0 0 3 0; +#X connect 0 0 10 0; +#X connect 0 0 11 0; +#X connect 0 0 12 0; +#X connect 3 0 2 0; +#X connect 7 0 3 1; +#X connect 10 0 6 0; +#X connect 11 0 5 0; +#X connect 12 0 4 0; +#X restore 44 243 pd \$0-initialize; +#X floatatom 151 200 5 0 0 2 depth - -; +#N canvas 0 0 340 391 \$0-draw-object 0; +#X obj 23 14 inlet; +#X text 69 13 gem; +#X obj 23 67 t a b b b; +#X obj 23 321 colorRGB; +#X obj 23 358 cube; +#X obj 240 291 inlet; +#X text 286 291 alpha; +#X obj 42 106 v \$0-R; +#X obj 120 104 v \$0-G; +#X obj 198 104 v \$0-B; +#X text 125 76 Normalize the colour range.; +#X obj 23 41 separator; +#X obj 42 253 expr $f1/$f4 \; $f2/$f4 \; $f3/$f4; +#X obj 42 128 expr $f1 \; $f2 \; $f3 \; max(max(max($f1 \, $f2) \, +$f3) \, 1); +#X connect 0 0 11 0; +#X connect 2 0 3 0; +#X connect 2 1 7 0; +#X connect 2 2 8 0; +#X connect 2 3 9 0; +#X connect 3 0 4 0; +#X connect 5 0 3 4; +#X connect 7 0 13 0; +#X connect 8 0 13 1; +#X connect 9 0 13 2; +#X connect 11 0 2 0; +#X connect 12 0 3 1; +#X connect 12 1 3 2; +#X connect 12 2 3 3; +#X connect 13 0 12 0; +#X connect 13 1 12 1; +#X connect 13 2 12 2; +#X connect 13 3 12 3; +#X restore 44 321 pd \$0-draw-object; +#X floatatom 158 279 5 0 0 2 alpha - -; +#X obj 158 299 / 100; +#N canvas 0 0 650 615 \$0-gui 0; +#X obj 11 11 xform-gui 0; +#X obj 167 263 t a; +#X msg 167 293 \$3 \$1 \$2; +#X obj 167 329 unpack f f s; +#X obj 246 355 select cR cG cB rX rY rZ tX tY tZ sX sY sZ; +#X obj 167 576 tabwrite; +#X obj 246 485 symbol \$0-colour-R; +#X obj 270 465 symbol \$0-colour-G; +#X obj 294 445 symbol \$0-colour-B; +#X obj 318 425 symbol \$0-rotate-X; +#X obj 342 405 symbol \$0-rotate-Y; +#X obj 366 385 symbol \$0-rotate-Z; +#X obj 390 485 symbol \$0-translate-X; +#X obj 414 465 symbol \$0-translate-Y; +#X obj 438 445 symbol \$0-translate-Z; +#X obj 462 425 symbol \$0-scale-X; +#X obj 486 405 symbol \$0-scale-Y; +#X obj 510 385 symbol \$0-scale-Z; +#X obj 374 552 list prepend set; +#X obj 374 572 list trim; +#X obj 495 112 inlet; +#X obj 71 11 xform-gui 1; +#X obj 131 11 xform-gui 2; +#X obj 191 11 xform-gui 3; +#X obj 251 11 xform-gui 4; +#X obj 311 11 xform-gui 5; +#X connect 0 0 1 0; +#X connect 1 0 2 0; +#X connect 2 0 3 0; +#X connect 3 0 5 0; +#X connect 3 1 5 1; +#X connect 3 2 4 0; +#X connect 4 0 6 0; +#X connect 4 1 7 0; +#X connect 4 2 8 0; +#X connect 4 3 9 0; +#X connect 4 4 10 0; +#X connect 4 5 11 0; +#X connect 4 6 12 0; +#X connect 4 7 13 0; +#X connect 4 8 14 0; +#X connect 4 9 15 0; +#X connect 4 10 16 0; +#X connect 4 11 17 0; +#X connect 6 0 18 0; +#X connect 7 0 18 0; +#X connect 8 0 18 0; +#X connect 9 0 18 0; +#X connect 10 0 18 0; +#X connect 11 0 18 0; +#X connect 12 0 18 0; +#X connect 13 0 18 0; +#X connect 14 0 18 0; +#X connect 15 0 18 0; +#X connect 16 0 18 0; +#X connect 17 0 18 0; +#X connect 18 0 19 0; +#X connect 19 0 5 0; +#X connect 20 0 0 0; +#X connect 20 0 21 0; +#X connect 20 0 22 0; +#X connect 20 0 23 0; +#X connect 20 0 24 0; +#X connect 20 0 25 0; +#X connect 21 0 1 0; +#X connect 22 0 1 0; +#X connect 23 0 1 0; +#X connect 24 0 1 0; +#X connect 25 0 1 0; +#X coords 0 -1 1 1 362 212 2 10 10; +#X restore 275 286 pd \$0-gui; +#X text 460 263 transformation parameters; +#N canvas 0 0 360 364 \$0-transformation-parameters 0; +#X obj 21 318 table \$0-scale-Z 6; +#X obj 21 298 table \$0-scale-Y 6; +#X obj 21 278 table \$0-scale-X 6; +#X obj 21 208 table \$0-translate-X 6; +#X obj 21 228 table \$0-translate-Y 6; +#X obj 21 248 table \$0-translate-Z 6; +#X obj 21 178 table \$0-rotate-Z 6; +#X obj 21 158 table \$0-rotate-Y 6; +#X obj 21 138 table \$0-rotate-X 6; +#X obj 21 68 table \$0-colour-R 6; +#X obj 21 88 table \$0-colour-G 6; +#X obj 21 108 table \$0-colour-B 6; +#X text 21 29 Tables to store transformation parameters.; +#X restore 418 506 pd \$0-transformation-parameters; +#X obj 14 191 alpha; +#X msg 37 164 auto \$1; +#X obj 38 139 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0 +1; +#N canvas 0 0 471 288 \$0-scene-transformation 0; +#X obj 20 20 inlet; +#X obj 20 42 t a b; +#X obj 20 149 rotateXYZ; +#X obj 50 67 f 0; +#X obj 88 67 + 1; +#X obj 62 98 / 1.618; +#X obj 82 122 / 1.618; +#X obj 20 217 scale 0.05; +#X obj 53 191 inlet; +#X obj 20 252 outlet; +#X text 152 215 Scale the whole scene.; +#X text 158 67 Rotate the whole scene continuously.; +#X connect 0 0 1 0; +#X connect 1 0 2 0; +#X connect 1 1 3 0; +#X connect 2 0 7 0; +#X connect 3 0 4 0; +#X connect 3 0 2 1; +#X connect 3 0 5 0; +#X connect 4 0 3 1; +#X connect 5 0 2 2; +#X connect 5 0 6 0; +#X connect 6 0 2 3; +#X connect 7 0 9 0; +#X connect 8 0 7 1; +#X restore 14 115 pd \$0-scene-transformation; +#X floatatom 158 69 5 0 0 2 scale - -; +#X obj 158 89 / 100; +#X obj 151 221 clip 0 6; +#X text 219 182 Subpatches are used to hide the implementation details +of each part of the patch. Further comments are inside.; +#X obj 275 260 bng 15 250 50 1 empty empty randomize 17 7 0 10 -262144 +-1 -1; +#X obj 14 404 nnrepeat 5; +#X text 220 77 Another new object is necessary for full effect: [nnrepeat] +which outputs the repeat count both before and after the repeated value +\, thus we can do and undo actions before and after \, such as colourizing +the geos according to the transformations. Allowing different parameters +for each transformation means we can create non-symmetric structures +with some sort of self-similarity.; +#X msg 48 13 create; +#X connect 1 0 0 0; +#X connect 2 0 0 0; +#X connect 3 0 25 0; +#X connect 6 0 7 0; +#X connect 7 0 31 0; +#X connect 7 1 16 0; +#X connect 8 0 9 0; +#X connect 9 0 31 1; +#X connect 10 0 11 1; +#X connect 11 0 12 0; +#X connect 13 0 7 0; +#X connect 13 1 14 0; +#X connect 15 0 28 0; +#X connect 17 0 18 0; +#X connect 18 0 16 1; +#X connect 22 0 13 0; +#X connect 23 0 22 0; +#X connect 24 0 23 0; +#X connect 25 0 22 0; +#X connect 26 0 27 0; +#X connect 27 0 25 1; +#X connect 28 0 14 1; +#X connect 30 0 19 0; +#X connect 31 0 11 0; +#X connect 31 1 10 0; +#X connect 31 2 10 1; +#X connect 31 2 11 2; +#X connect 33 0 0 0; diff --git a/Gem/examples/13.recursion/README b/Gem/examples/13.recursion/README new file mode 100644 index 0000000..90b5cf4 --- /dev/null +++ b/Gem/examples/13.recursion/README @@ -0,0 +1,23 @@ +gem-recursion -- a tutorial on using recursion with Gem +Copyright (C) 2007 Claude Heiland-Allen <claude@mathr.co.uk> + + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + + +Requirements: +(*) pd-0.40-2 or greater +(*) Gem for pd +(*) Zexy for pd diff --git a/Gem/examples/13.recursion/nnrepeat-help.pd b/Gem/examples/13.recursion/nnrepeat-help.pd new file mode 100644 index 0000000..b23304e --- /dev/null +++ b/Gem/examples/13.recursion/nnrepeat-help.pd @@ -0,0 +1,28 @@ +#N canvas 0 0 506 325 10; +#X floatatom 87 195 5 0 0 0 - - -; +#X text 94 11 - repeat a message several times with counter; +#X obj 54 273 print repeat; +#X msg 22 110 bang; +#X msg 49 136 1 1 2 3 5 8 13 21 44 fibonacchi; +#X text 63 111 repeat bangs; +#X text 282 138 repeat a list; +#X msg 69 166 set 5; +#X text 117 167 repeat anything; +#X text 127 194 reset the number of repetitions; +#X text 100 220 creation argument initializes the number of repeats +; +#X obj 19 12 nnrepeat 1; +#X obj 22 219 nnrepeat 3; +#X obj 87 250 print n1; +#X obj 22 297 print n2; +#X text 19 44 Similar to [repeat] from Zexy but outputs the repetition +count from the right-hand outlet then outputs the repeated input from +the middle outlet \, then outputs the repetition count again from the +left-hand outlet.; +#X connect 0 0 12 1; +#X connect 3 0 12 0; +#X connect 4 0 12 0; +#X connect 7 0 12 0; +#X connect 12 0 14 0; +#X connect 12 1 2 0; +#X connect 12 2 13 0; diff --git a/Gem/examples/13.recursion/nnrepeat-test.pd b/Gem/examples/13.recursion/nnrepeat-test.pd new file mode 100644 index 0000000..91b5c94 --- /dev/null +++ b/Gem/examples/13.recursion/nnrepeat-test.pd @@ -0,0 +1,55 @@ +#N canvas 0 0 481 517 10; +#X obj 71 95 r \$0-recurse; +#X obj 71 380 s \$0-recurse; +#X obj 140 270 t b a b; +#X obj 224 290 v \$0-depth; +#X obj 224 310 - 1; +#X obj 224 330 max 0; +#X obj 162 350 spigot; +#X obj 224 350 v \$0-depth; +#X obj 185 160 t b f; +#X obj 185 183 v \$0-depth; +#X obj 185 208 pack f f; +#X obj 140 290 v \$0-depth; +#X obj 140 330 v \$0-depth; +#X obj 140 310 + 1; +#X obj 108 50 t a b; +#X msg 108 21 nrepeat test; +#X obj 285 108 v \$0-depth; +#X floatatom 262 77 5 0 0 2 max-depth - -; +#X floatatom 261 38 5 0 0 2 repetitions - -; +#X obj 246 108 f 3; +#X obj 185 235 print ->; +#X obj 98 160 t b f; +#X obj 98 183 v \$0-depth; +#X obj 98 208 pack f f; +#X obj 98 235 print <-; +#X obj 108 135 nnrepeat 2; +#X connect 0 0 25 0; +#X connect 2 0 11 0; +#X connect 2 1 6 0; +#X connect 2 2 3 0; +#X connect 3 0 4 0; +#X connect 4 0 5 0; +#X connect 5 0 6 1; +#X connect 5 0 7 0; +#X connect 6 0 1 0; +#X connect 8 0 9 0; +#X connect 8 1 10 1; +#X connect 9 0 10 0; +#X connect 10 0 20 0; +#X connect 11 0 13 0; +#X connect 13 0 12 0; +#X connect 14 0 25 0; +#X connect 14 1 19 0; +#X connect 15 0 14 0; +#X connect 17 0 19 1; +#X connect 18 0 25 1; +#X connect 19 0 16 0; +#X connect 21 0 22 0; +#X connect 21 1 23 1; +#X connect 22 0 23 0; +#X connect 23 0 24 0; +#X connect 25 0 21 0; +#X connect 25 1 2 0; +#X connect 25 2 8 0; diff --git a/Gem/examples/13.recursion/nnrepeat.pd b/Gem/examples/13.recursion/nnrepeat.pd new file mode 100644 index 0000000..c0e89d1 --- /dev/null +++ b/Gem/examples/13.recursion/nnrepeat.pd @@ -0,0 +1,27 @@ +#N canvas 0 0 400 328 10; +#X obj 61 94 nrepeat \$1; +#X obj 136 21 inlet; +#X text 178 21 count; +#X obj 27 20 inlet; +#X text 68 21 repeatee; +#X obj 88 175 stack; +#X obj 61 136 t b a; +#X obj 126 137 t f f; +#X obj 25 262 outlet; +#X text 75 263 count; +#X obj 132 263 outlet; +#X text 182 264 repeated; +#X obj 256 263 outlet; +#X text 311 265 count; +#X obj 132 209 print nnrepeat-internal-error; +#X text 23 295 nnrepeat.pd (GPL) <claude@mathr.co.uk>; +#X connect 0 0 6 0; +#X connect 0 1 7 0; +#X connect 1 0 0 1; +#X connect 3 0 0 0; +#X connect 5 0 8 0; +#X connect 5 1 14 0; +#X connect 6 0 5 0; +#X connect 6 1 10 0; +#X connect 7 0 12 0; +#X connect 7 1 5 1; diff --git a/Gem/examples/13.recursion/nrepeat-help.pd b/Gem/examples/13.recursion/nrepeat-help.pd new file mode 100644 index 0000000..41f21de --- /dev/null +++ b/Gem/examples/13.recursion/nrepeat-help.pd @@ -0,0 +1,25 @@ +#N canvas 0 0 506 325 10; +#X floatatom 80 196 5 0 0 0 - - -; +#X obj 19 12 nrepeat 1; +#X text 94 11 - repeat a message several times with counter; +#X text 19 44 Similar to [repeat] from Zexy but also outputs the repetition +count from the right-hand outlet before it outputs the repeated input +from the left-hand outlet.; +#X obj 22 219 nrepeat 3; +#X obj 22 273 print repeat; +#X obj 80 249 print n; +#X msg 22 110 bang; +#X msg 49 136 1 1 2 3 5 8 13 21 44 fibonacchi; +#X text 63 111 repeat bangs; +#X text 282 138 repeat a list; +#X msg 69 166 set 5; +#X text 117 167 repeat anything; +#X text 127 194 reset the number of repetitions; +#X text 100 220 creation argument initializes the number of repeats +; +#X connect 0 0 4 1; +#X connect 4 0 5 0; +#X connect 4 1 6 0; +#X connect 7 0 4 0; +#X connect 8 0 4 0; +#X connect 11 0 4 0; diff --git a/Gem/examples/13.recursion/nrepeat-test.pd b/Gem/examples/13.recursion/nrepeat-test.pd new file mode 100644 index 0000000..48348b3 --- /dev/null +++ b/Gem/examples/13.recursion/nrepeat-test.pd @@ -0,0 +1,46 @@ +#N canvas 0 0 481 517 10; +#X obj 71 95 r \$0-recurse; +#X obj 71 380 s \$0-recurse; +#X obj 108 260 t b a b; +#X obj 192 280 v \$0-depth; +#X obj 192 300 - 1; +#X obj 192 320 max 0; +#X obj 130 340 spigot; +#X obj 192 340 v \$0-depth; +#X obj 166 160 t b f; +#X obj 166 183 v \$0-depth; +#X obj 166 208 pack f f; +#X obj 165 239 print nrepeat; +#X obj 108 280 v \$0-depth; +#X obj 108 320 v \$0-depth; +#X obj 108 300 + 1; +#X obj 108 50 t a b; +#X msg 108 21 nrepeat test; +#X obj 285 108 v \$0-depth; +#X floatatom 262 77 5 0 0 2 max-depth - -; +#X floatatom 261 38 5 0 0 2 repetitions - -; +#X obj 246 108 f 3; +#X obj 108 135 nrepeat 2; +#X connect 0 0 21 0; +#X connect 2 0 12 0; +#X connect 2 1 6 0; +#X connect 2 2 3 0; +#X connect 3 0 4 0; +#X connect 4 0 5 0; +#X connect 5 0 6 1; +#X connect 5 0 7 0; +#X connect 6 0 1 0; +#X connect 8 0 9 0; +#X connect 8 1 10 1; +#X connect 9 0 10 0; +#X connect 10 0 11 0; +#X connect 12 0 14 0; +#X connect 14 0 13 0; +#X connect 15 0 21 0; +#X connect 15 1 20 0; +#X connect 16 0 15 0; +#X connect 18 0 20 1; +#X connect 19 0 21 1; +#X connect 20 0 17 0; +#X connect 21 0 2 0; +#X connect 21 1 8 0; diff --git a/Gem/examples/13.recursion/nrepeat.pd b/Gem/examples/13.recursion/nrepeat.pd new file mode 100644 index 0000000..4d26d68 --- /dev/null +++ b/Gem/examples/13.recursion/nrepeat.pd @@ -0,0 +1,49 @@ +#N canvas 0 0 413 451 10; +#X obj 78 26 inlet; +#X obj 78 60 t b a b; +#X obj 131 121 repeat \$1; +#X obj 189 24 inlet; +#X obj 92 239 stack; +#X msg 122 192 0; +#X msg 146 239 0; +#X obj 78 192 t b b; +#X obj 131 142 t a b; +#X obj 161 193 t b b; +#X msg 176 240 1; +#X obj 92 267 list prepend; +#X obj 92 295 route 0 1; +#X text 86 312 nop; +#X obj 121 321 t f f; +#X obj 236 195 + 1; +#X obj 121 361 outlet; +#X obj 10 205 outlet; +#X obj 187 298 print nrepeat-stack-underflow; +#X obj 187 328 print nrepeat-internal-error; +#X text 119 24 repeatee; +#X text 233 23 count; +#X text 8 225 repeated; +#X text 119 381 counter; +#X text 30 419 nrepeat.pd (GPL) <claude@mathr.co.uk>; +#X connect 0 0 1 0; +#X connect 1 0 7 0; +#X connect 1 1 2 0; +#X connect 1 2 5 0; +#X connect 2 0 8 0; +#X connect 3 0 2 1; +#X connect 4 0 11 0; +#X connect 4 1 18 0; +#X connect 5 0 4 1; +#X connect 6 0 11 1; +#X connect 7 0 4 0; +#X connect 7 1 6 0; +#X connect 8 0 17 0; +#X connect 8 1 9 0; +#X connect 9 0 4 0; +#X connect 9 1 10 0; +#X connect 10 0 11 1; +#X connect 11 0 12 0; +#X connect 12 1 14 0; +#X connect 12 2 19 0; +#X connect 14 0 16 0; +#X connect 14 1 15 0; +#X connect 15 0 4 1; diff --git a/Gem/examples/13.recursion/stack-help.pd b/Gem/examples/13.recursion/stack-help.pd new file mode 100644 index 0000000..b891067 --- /dev/null +++ b/Gem/examples/13.recursion/stack-help.pd @@ -0,0 +1,20 @@ +#N canvas 0 0 411 333 10; +#X obj 43 199 stack; +#X obj 43 269 print popped; +#X obj 73 249 print empty; +#X msg 130 163 list foo 2 bar; +#X floatatom 73 108 5 0 0 1 float - -; +#X obj 43 79 bng 15 250 50 0 empty empty pop 17 7 0 10 -262144 -1 -1 +; +#X symbolatom 101 135 10 0 0 1 symbol - -; +#X text 241 164 mixture of stuff; +#X text 13 9 A stack is a "first in \, last out" structure.; +#X text 13 48 Right inlet stores atom(s).; +#X text 13 29 Left inlet unstores the most recently stored atom.; +#X text 11 301 stack-help.pd (GPL) <claude@mathr.co.uk>; +#X connect 0 0 1 0; +#X connect 0 1 2 0; +#X connect 3 0 0 1; +#X connect 4 0 0 1; +#X connect 5 0 0 0; +#X connect 6 0 0 1; diff --git a/Gem/examples/13.recursion/stack.pd b/Gem/examples/13.recursion/stack.pd new file mode 100644 index 0000000..789ea8f --- /dev/null +++ b/Gem/examples/13.recursion/stack.pd @@ -0,0 +1,38 @@ +#N canvas 0 0 351 366 10; +#X obj 25 19 inlet; +#X text 69 18 pop; +#X obj 166 18 inlet; +#X text 213 17 push; +#X obj 25 53 t b b; +#X obj 25 152 list prepend; +#X msg 88 127 0; +#X msg 121 127 1; +#X obj 25 183 route 0 1; +#X obj 25 251 list split 1; +#X obj 25 298 outlet; +#X obj 25 97 list; +#X text 79 298 popped; +#X obj 166 299 outlet; +#X text 220 298 empty; +#X obj 166 47 t b a b; +#X obj 109 217 list prepend; +#X obj 120 182 print stack-internal-error; +#X text 17 330 stack.pd (GPL) <claude@mathr.co.uk>; +#X connect 0 0 4 0; +#X connect 2 0 15 0; +#X connect 4 0 11 0; +#X connect 4 1 6 0; +#X connect 5 0 8 0; +#X connect 6 0 5 1; +#X connect 7 0 5 1; +#X connect 8 0 9 0; +#X connect 8 1 16 0; +#X connect 8 2 17 0; +#X connect 9 0 10 0; +#X connect 9 1 11 1; +#X connect 9 2 13 0; +#X connect 11 0 5 0; +#X connect 15 0 11 0; +#X connect 15 1 16 1; +#X connect 15 2 7 0; +#X connect 16 0 11 1; diff --git a/Gem/examples/13.recursion/xform-gui.pd b/Gem/examples/13.recursion/xform-gui.pd new file mode 100644 index 0000000..efe1e89 --- /dev/null +++ b/Gem/examples/13.recursion/xform-gui.pd @@ -0,0 +1,120 @@ +#N canvas 0 0 476 324 10; +#X obj 340 251 list prepend \$1; +#X obj 340 275 outlet; +#X floatatom 220 13 5 0 0 0 cR - -; +#X floatatom 220 29 5 0 0 0 cG - -; +#X floatatom 220 45 5 0 0 0 cB - -; +#X floatatom 220 66 5 0 0 0 rX - -; +#X floatatom 220 82 5 0 0 0 rY - -; +#X floatatom 220 98 5 0 0 0 rZ - -; +#X floatatom 220 119 5 0 0 0 tX - -; +#X floatatom 220 135 5 0 0 0 tY - -; +#X floatatom 220 151 5 0 0 0 tZ - -; +#X floatatom 220 172 5 0 0 0 sX - -; +#X floatatom 220 188 5 0 0 0 sY - -; +#X floatatom 220 204 5 0 0 0 sZ - -; +#X obj 282 173 / 100; +#X obj 282 193 / 100; +#X obj 282 213 / 100; +#X obj 282 111 / 10; +#X obj 282 131 / 10; +#X obj 282 151 / 10; +#X obj 341 5 list prepend cR; +#X obj 341 65 list prepend rX; +#X obj 341 85 list prepend rY; +#X obj 341 105 list prepend rZ; +#X obj 341 125 list prepend tX; +#X obj 341 145 list prepend tY; +#X obj 341 165 list prepend tZ; +#X obj 341 185 list prepend sX; +#X obj 341 205 list prepend sY; +#X obj 341 225 list prepend sZ; +#X obj 341 25 list prepend cG; +#X obj 341 45 list prepend cB; +#X obj 67 70 random 360; +#X obj 67 90 random 360; +#X obj 67 110 random 360; +#X obj 147 110 - 180; +#X obj 147 90 - 180; +#X obj 147 70 - 180; +#X obj 67 130 random 360; +#X obj 67 150 random 360; +#X obj 67 170 random 360; +#X obj 147 170 - 180; +#X obj 147 150 - 180; +#X obj 147 130 - 180; +#X obj 8 6 inlet; +#X obj 67 10 random 5; +#X obj 67 30 random 5; +#X obj 67 50 random 5; +#X obj 67 190 random 50; +#X obj 67 210 random 50; +#X obj 67 230 random 50; +#X obj 147 190 + 50; +#X obj 147 210 + 50; +#X obj 147 230 + 50; +#X connect 0 0 1 0; +#X connect 2 0 20 0; +#X connect 3 0 30 0; +#X connect 4 0 31 0; +#X connect 5 0 21 0; +#X connect 6 0 22 0; +#X connect 7 0 23 0; +#X connect 8 0 17 0; +#X connect 9 0 18 0; +#X connect 10 0 19 0; +#X connect 11 0 14 0; +#X connect 12 0 15 0; +#X connect 13 0 16 0; +#X connect 14 0 27 0; +#X connect 15 0 28 0; +#X connect 16 0 29 0; +#X connect 17 0 24 0; +#X connect 18 0 25 0; +#X connect 19 0 26 0; +#X connect 20 0 0 0; +#X connect 21 0 0 0; +#X connect 22 0 0 0; +#X connect 23 0 0 0; +#X connect 24 0 0 0; +#X connect 25 0 0 0; +#X connect 26 0 0 0; +#X connect 27 0 0 0; +#X connect 28 0 0 0; +#X connect 29 0 0 0; +#X connect 30 0 0 0; +#X connect 31 0 0 0; +#X connect 32 0 37 0; +#X connect 33 0 36 0; +#X connect 34 0 35 0; +#X connect 35 0 7 0; +#X connect 36 0 6 0; +#X connect 37 0 5 0; +#X connect 38 0 43 0; +#X connect 39 0 42 0; +#X connect 40 0 41 0; +#X connect 41 0 10 0; +#X connect 42 0 9 0; +#X connect 43 0 8 0; +#X connect 44 0 32 0; +#X connect 44 0 33 0; +#X connect 44 0 34 0; +#X connect 44 0 38 0; +#X connect 44 0 39 0; +#X connect 44 0 40 0; +#X connect 44 0 45 0; +#X connect 44 0 46 0; +#X connect 44 0 47 0; +#X connect 44 0 48 0; +#X connect 44 0 49 0; +#X connect 44 0 50 0; +#X connect 45 0 2 0; +#X connect 46 0 3 0; +#X connect 47 0 4 0; +#X connect 48 0 51 0; +#X connect 49 0 52 0; +#X connect 50 0 53 0; +#X connect 51 0 11 0; +#X connect 52 0 12 0; +#X connect 53 0 13 0; +#X coords 0 -1 1 1 60 210 2 200 10; |