Attached has the basics of mode 0. It's a very good idea you got, great fun to play with.
mvh /Steffen Leve Poulsen
Atte André Jensen skrev:
Steffen Leve Poulsen wrote:
OK I havent tried your external. Can you describe it's functionality.
[legato] transforms output from [notein] inlet 1: note inlet 2: velocity inlet 3: mode: 0: last note hit priority (default) 1: low note priority 2: high note priority
outlet 1: note outlet 2: velocity (non re-triggered) outlet 3: velocity (re-triggered)
Notice: outlets only output values when they actually change. FOr instance if two notes are played legato, the socond note will not make outlet 2 (velocity) transmit a new value for velocity.
Example: Play (and hold) note 1, note 1 will sound. Play (and hold) note 2, note 2 will sound. Release note 2, note 1 will sound. This works for unlimited depth (actually 200) and any combination of press/release order. This description is valid for mode 0. So basically: when more than one note is pressed, the latest one pressed will sound.
#N canvas 556 21 365 683 10; #X obj 60 57 notein; #X obj 60 283 phasor~; #X obj 60 254 mtof; #X obj 60 365 *~; #X obj 78 483 dbtorms; #X obj 81 459 hsl 128 15 0 100 0 0 empty empty empty -2 -8 0 10 -262144 -1 -1 9500 1; #X obj 61 311 -~ 0.5; #X obj 58 532 dac~; #X obj 105 313 adsr 1 5 500 50 500; #X obj 189 85 table memo-$0 12346; #X obj 59 507 *~ 0.1; #N canvas 257 64 437 609 legato 0; #X obj 93 28 inlet; #X obj 180 39 inlet; #X obj 221 164 f; #X obj 180 61 select 0; #X obj 175 126 - 1; #X msg 223 97 1; #X obj 191 164 +; #X obj 118 292 tabwrite memo-$0; #X obj 93 260 t b f; #X obj 93 355 tabread memo-$0; #X obj 93 334 f; #X obj 242 385 outlet; #X obj 93 385 outlet; #X obj 191 195 moses 1; #X obj 191 241 t f f f; #X obj 242 355 change; #X obj 134 247 0; #X obj 93 63 stripnote; #X obj 157 95 t b b b; #X obj 303 390 outlet; #X obj 242 326 f; #X connect 0 0 17 0; #X connect 1 0 3 0; #X connect 1 0 17 1; #X connect 2 0 6 1; #X connect 3 0 18 0; #X connect 3 1 5 0; #X connect 4 0 6 0; #X connect 5 0 6 0; #X connect 6 0 2 0; #X connect 6 0 13 0; #X connect 8 0 10 0; #X connect 8 1 7 0; #X connect 9 0 12 0; #X connect 10 0 9 0; #X connect 13 0 20 0; #X connect 13 1 14 0; #X connect 14 0 10 1; #X connect 14 1 7 1; #X connect 14 2 20 0; #X connect 15 0 11 0; #X connect 16 0 7 0; #X connect 17 0 8 0; #X connect 18 0 10 0; #X connect 18 1 4 0; #X connect 18 2 16 0; #X connect 20 0 15 0; #X connect 20 0 19 0; #X restore 60 85 pd legato mode 0; #X connect 0 0 11 0; #X connect 0 1 11 1; #X connect 1 0 6 0; #X connect 2 0 1 0; #X connect 3 0 10 0; #X connect 4 0 10 1; #X connect 5 0 4 0; #X connect 6 0 3 0; #X connect 8 0 3 1; #X connect 10 0 7 0; #X connect 10 0 7 1; #X connect 11 0 2 0; #X connect 11 1 8 0;