File: fadecurve-help.pd

package info (click to toggle)
pd-kollabs 2~repack-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, sid
  • size: 824 kB
  • sloc: makefile: 8
file content (91 lines) | stat: -rw-r--r-- 3,132 bytes parent folder | download | duplicates (2)
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
#N canvas 320 22 929 656 10;
#X obj 269 84 vsl 15 128 -3 3 0 0 empty empty empty 0 -9 0 10 -262130
-1 -1 0 1;
#X obj 381 84 vsl 15 128 0 1 0 0 empty empty empty 0 -9 0 10 -262130
-1 -1 0 1;
#X msg 269 242 shape \$1;
#X msg 381 242 weight \$1;
#X floatatom 381 291 7 0 0 1 10...10000 - -;
#X msg 381 312 resolution \$1;
#X text 319 29 creation arguments:;
#X text 449 29 1st: name;
#X floatatom 269 220 5 0 0 1 --inf...inf - -;
#X floatatom 381 220 5 0 0 1 0...1 - -;
#X text 528 188 SHAPE:;
#X text 571 248 abs(shape) >= 2: f(x) = x^abs(shape);
#X text 570 468 2 --> x^2;
#X text 570 488 5 --> x^5;
#X floatatom 64 548 5 0 99 1 0...(N-1) - -;
#X floatatom 64 611 5 0 0 0 - - -;
#X obj 64 589 tabread4 \$0-curve;
#X text 570 408 EXAMPLES:;
#X msg 164 242 quality \$1;
#X floatatom 194 548 5 0 99 1 0...(N-1) - -;
#X floatatom 194 611 5 0 0 0 - - -;
#X obj 194 589 tabread \$0-curve;
#X text 19 29 fadecurve <name> <resolution> <quality>;
#X text 449 66 3rd (optional): init quality:;
#X obj 64 567 + 1;
#X obj 194 567 + 1;
#X text 45 496 The table can also be addressed directly via [tabread].
;
#X text 570 428 -1 --> standard cosine fade;
#X text 571 298 shape < 0: output = 1-f(1-x);
#X text 571 283 shape > 0: output = f(x);
#X text 571 357 0 < abs(shape) < 1 && 1 <abs(shape) < 2;
#X text 571 370 --> linear interpolation;
#X text 571 188 MATHEMATICAL EXPLANATION:;
#X text 570 448 -1.67 --> mix between "cosine" and "1-(1-x)^2";
#X obj 164 220 hradio 15 1 0 4 empty empty 0..1..2 0 -8 0 10 -262144
-1 -1 0;
#X obj 164 364 t b a;
#X text 45 516 (size=N+3 \, N=resolution);
#X text 449 47 2nd (optional): init resolution N (default=100);
#X text 571 208 abs(shape) = 0: f(x) = sin^2(x*pi/2);
#X text 392 539 alternatively set parameters via send/receive:;
#X text 571 328 input: 0 <= x <= 1;
#X text 571 228 abs(shape) = 1: f(x) = 1-cos(x*pi/2);
#X obj 42 416 cnv 15 170 30 empty empty empty 20 12 0 14 -204786 -66577
0;
#X floatatom 50 455 9 0 1 1 0...1 - -;
#X floatatom 50 330 7 0 1 1 0...1 - -;
#X obj 50 389 f;
#X obj 50 422 fadecurve \$0-curve 100 3;
#X obj 119 115 bng 15 250 50 0 empty empty empty 17 7 0 10 -257985
-1 -1;
#X text 107 98 click to see table;
#X msg 119 143 vis;
#X text 302 400 (c)2012 Marian Weger;
#X obj 414 561 s \$0-curve/quality;
#X obj 414 581 s \$0-curve/shape;
#X obj 534 561 s \$0-curve/weight;
#X obj 534 581 s \$0-curve/resolution;
#X obj 414 601 s \$0-curve/vis;
#X obj 534 601 s \$0-curve/loadbang;
#X text 631 67 0: no interpolation;
#X text 631 81 1: linear interpolation;
#X text 631 95 2: tabread4 4-point polynomianl interpolation;
#X text 448 137 If weight=0 \, the abstraction is bypassed.;
#X connect 0 0 8 0;
#X connect 1 0 9 0;
#X connect 2 0 35 0;
#X connect 3 0 35 0;
#X connect 4 0 5 0;
#X connect 5 0 35 0;
#X connect 8 0 2 0;
#X connect 9 0 3 0;
#X connect 14 0 24 0;
#X connect 16 0 15 0;
#X connect 18 0 35 0;
#X connect 19 0 25 0;
#X connect 21 0 20 0;
#X connect 24 0 16 0;
#X connect 25 0 21 0;
#X connect 34 0 18 0;
#X connect 35 0 45 0;
#X connect 35 1 46 1;
#X connect 44 0 45 0;
#X connect 45 0 46 0;
#X connect 46 0 43 0;
#X connect 47 0 49 0;
#X connect 49 0 35 0;