aboutsummaryrefslogtreecommitdiff
path: root/pd/doc/2.control.examples/08.depthfirst.pd
blob: 8820d226720e8b9e50e6347d793cfaaf4a582bd8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#N canvas 144 162 632 551 12;
#X msg 64 51 1;
#X obj 89 150 + 1;
#X obj 209 187 print x1;
#X obj 64 209 print x3;
#X obj 114 122 print x2;
#X obj 209 100 + 1;
#X obj 209 129 + 1;
#X obj 209 158 + 1;
#X obj 64 80 t f f f f;
#X obj 89 179 print x2;
#X text 34 13 In Pd \, message passing is depth first \, so that in
this patch:;
#X text 104 51 <-- click here;
#X text 17 243 ... you get "x1" first \, notwidthstanding the fact
that "x2" and "x3" appear to be closer to the source. This means that
you shouldn't do this:;
#X msg 76 304 1;
#X text 116 304 <-- maybe you shouldn't click here;
#X obj 115 334 + 1;
#X obj 76 333 f;
#X floatatom 76 365 0 0 0;
#X text 377 520 updated for Pd version 0.34;
#X text 35 393 ... because the "depth" is infinite. The counters you've
seen always have the message chain terminated somewhere in a cold inlet:
;
#X msg 75 453 1;
#X obj 114 483 + 1;
#X obj 75 482 f;
#X floatatom 75 514 0 0 0;
#X text 115 453 <-- better;
#X connect 0 0 8 0;
#X connect 1 0 9 0;
#X connect 5 0 6 0;
#X connect 6 0 7 0;
#X connect 7 0 2 0;
#X connect 8 0 3 0;
#X connect 8 1 1 0;
#X connect 8 2 4 0;
#X connect 8 3 5 0;
#X connect 13 0 16 0;
#X connect 15 0 16 0;
#X connect 16 0 17 0;
#X connect 16 0 15 0;
#X connect 20 0 22 0;
#X connect 21 0 22 1;
#X connect 22 0 23 0;
#X connect 22 0 21 0;