Bug fixed for unix error "readlink /proc/self/fd/0" on MacOS.
[Faustine.git] / interpreter / preprocessor / faust-0.9.47mr3 / examples / faust-stk / pd-patches / midi-in.pd
1 #N canvas 555 193 650 564 10;
2 #X obj 331 8 notein;
3 #X obj 336 353 pack f f f;
4 #X obj 394 292 / 127;
5 #X obj 336 384 outlet;
6 #X obj 16 92 ctlin 123;
7 #X obj 154 92 inlet;
8 #X obj 204 200 list split 3;
9 #X obj 204 242 makenote;
10 #X obj 204 269 pack f f;
11 #X obj 336 322 poly \$1 1;
12 #X obj 50 27 tgl 15 0 \$0-led-1 \$0-led-1 empty 0 -6 0 8 -262144 -1
13 -1 0 1;
14 #X obj 67 27 tgl 15 0 \$0-led-2 \$0-led-2 empty 0 -6 0 8 -262144 -1
15 -1 0 1;
16 #X obj 84 27 tgl 15 0 \$0-led-3 \$0-led-3 empty 0 -6 0 8 -262144 -1
17 -1 0 1;
18 #X obj 101 27 tgl 15 0 \$0-led-4 \$0-led-4 empty 0 -6 0 8 -262144 -1
19 -1 0 1;
20 #X obj 260 385 s \$0-leds;
21 #X obj 471 291 unpack f f f;
22 #X obj 550 323 > 0;
23 #X obj 471 262 r \$0-leds;
24 #X obj 471 358 makefilename \$0-led-%d;
25 #X obj 471 385 pack s f;
26 #X msg 471 413 \; \$1 \$2;
27 #X text 470 234 LED logic;
28 #X obj 118 27 tgl 15 0 \$0-led-5 \$0-led-5 empty 0 -6 0 8 -262144 -1
29 -1 0 1;
30 #X obj 135 27 tgl 15 0 \$0-led-6 \$0-led-6 empty 0 -6 0 8 -262144 -1
31 -1 0 1;
32 #X obj 152 27 tgl 15 0 \$0-led-7 \$0-led-7 empty 0 -6 0 8 -262144 -1
33 -1 0 1;
34 #X obj 169 27 tgl 15 0 \$0-led-8 \$0-led-8 empty 0 -6 0 8 -262144 -1
35 -1 0 1;
36 #X obj 217 3 tgl 15 0 \$0-toggle \$0-toggle empty 0 -6 0 8 -262144
37 -1 -1 1 1;
38 #X obj 154 124 spigot;
39 #X obj 244 8 r \$0-toggle;
40 #X obj 336 190 spigot;
41 #X msg 400 83 stop;
42 #X obj 540 456 loadbang;
43 #X obj 244 56 sel 0;
44 #X obj 197 3 bng 15 250 50 0 \$0-notes-off \$0-notes-off empty 0 -6
45 0 8 -262144 -1 -1;
46 #X obj 540 503 s \$0-toggle;
47 #X msg 540 479 1;
48 #X obj 16 265 s \$0-notes-off;
49 #X obj 400 9 r \$0-notes-off;
50 #X msg 244 85 bang;
51 #X obj 401 384 outlet;
52 #X obj 161 3 nbx 2 14 0 16 0 0 \$0-chan \$0-chan empty -15 6 0 10 -262144
53 -1 -1 0 256;
54 #X obj 521 9 r \$0-chan;
55 #X obj 274 134 expr $f1 && (($f2==$f3) || ($f3==0));
56 #X obj 318 83 t f b;
57 #X obj 154 164 route stop note;
58 #X text 18 420 MIDI input logic. Handles MIDI note-on/off messages
59 and the all-notes off controller. Velocity values are normalized to
60 the 0-1 range. MIDI input can be restricted to one MIDI channel. Through
61 the inlet \, you can also pass in MIDI style messages \, either note/velocity
62 or note/velocity/duration (use a "stop" message to emulate all-notes-off).
63 Other (control) messages are simply passed through to the second outlet.
64 The creation argument sets the number of voices (8 voices max).;
65 #X obj 16 307 loadbang;
66 #X obj 16 328 f \$2;
67 #X obj 16 349 s \$0-chan;
68 #X connect 0 0 43 0;
69 #X connect 0 1 2 0;
70 #X connect 0 2 42 1;
71 #X connect 1 0 3 0;
72 #X connect 1 0 14 0;
73 #X connect 2 0 9 1;
74 #X connect 4 0 36 0;
75 #X connect 5 0 27 0;
76 #X connect 6 0 7 0;
77 #X connect 6 2 9 0;
78 #X connect 7 0 8 0;
79 #X connect 7 1 8 1;
80 #X connect 8 0 9 0;
81 #X connect 9 0 1 0;
82 #X connect 9 1 1 1;
83 #X connect 9 2 1 2;
84 #X connect 15 0 18 0;
85 #X connect 15 2 16 0;
86 #X connect 16 0 19 1;
87 #X connect 17 0 15 0;
88 #X connect 18 0 19 0;
89 #X connect 19 0 20 0;
90 #X connect 27 0 44 0;
91 #X connect 28 0 27 1;
92 #X connect 28 0 32 0;
93 #X connect 28 0 42 0;
94 #X connect 29 0 9 0;
95 #X connect 30 0 9 0;
96 #X connect 31 0 35 0;
97 #X connect 32 0 38 0;
98 #X connect 35 0 34 0;
99 #X connect 37 0 30 0;
100 #X connect 38 0 36 0;
101 #X connect 41 0 42 2;
102 #X connect 41 0 30 0;
103 #X connect 42 0 29 1;
104 #X connect 43 0 29 0;
105 #X connect 43 1 42 0;
106 #X connect 44 0 36 0;
107 #X connect 44 1 6 0;
108 #X connect 44 2 39 0;
109 #X connect 46 0 47 0;
110 #X connect 47 0 48 0;
111 #X coords 0 -1 1 1 235 45 1 0 0;