#N canvas 521 50 540 694 12;
#N canvas 0 0 450 300 (subpatch) 0;
#X array adsr-output 44100 float 0;
#X coords 0 1.02 44100 -1.02 200 130 1;
#X restore 162 381 graph;
#X text 174 517 ------ 1 second ------;
#X obj 58 128 r trigger;
#X obj 75 219 tabwrite~ adsr-output;
#X obj 89 191 r graphit;
#X msg 250 99 bang;
#X obj 261 132 del 500;
#X msg 250 198 \; pd dsp 1 \; trigger 1 \; graphit bang;
#X msg 249 268 \; pd dsp 1 \; trigger 0 \; graphit bang;
#X msg 261 157 \; trigger 0;
#X text 365 501 -1;
#X text 367 376 1;
#X text 48 41 This patch introduces a simple "adsr" abstraction we'll
use frequently. You can click on the "adsr" object to see what's inside.
;
#X text 53 557 The active ingredient of the ADSR envelope generator
is a single line~ which gets passed messages to make the attack and
release behavior. You can retrigger the ADSR envelope generator all
you wish without having to wait for attacks or releases to finish;
#X text 113 11 ENVELOPE GENERATOR ABSTRACTION;
#X obj 58 154 adsr 1 100 200 50 300;
#X text 293 663 updated for Pd version 0.37;
#X obj 75 251 osc~ 440;
#X obj 57 276 *~;
#X obj 41 315 output~;
#X text 292 97 <= attack and delayed release;
#X text 349 217 <= attack only;
#X text 352 292 <= release only;
#X connect 2 0 15 0;
#X connect 4 0 3 0;
#X connect 5 0 7 0;
#X connect 5 0 6 0;
#X connect 6 0 9 0;
#X connect 15 0 3 0;
#X connect 15 0 18 0;
#X connect 17 0 18 1;
#X connect 18 0 19 0;
#X connect 18 0 19 1;
