Add octave scripts for examples into track list.
[Faustine.git] / interpretor / preprocessor / faust-0.9.47mr3 / benchmark / tapiir.dsp
1 declare name "tapiir";
2 declare version "1.0";
3 declare author "Grame";
4 declare license "BSD";
5 declare copyright "(c)GRAME 2006";
6
7 //======================================================
8 //
9 // TAPIIR
10 // (from Maarten de Boer's Tapiir)
11 //
12 //======================================================
13
14 import("music.lib");
15
16
17 dsize = 524288;
18
19
20
21 // user interface
22 //---------------
23
24
25 tap(n) = vslider("tap %n", 0,0,1,0.1);
26 in(n) = vslider("input %n", 1,0,1,0.1);
27 gain = vslider("gain", 1,0,1,0.1);
28 del = vslider("delay (sec)", 0, 0, 5, 0.01) * SR;
29
30
31 // bus, mixer and matrix
32 //-----------------------------------------------------------
33
34 //bus(n) = par(i,n,_);
35
36 mixer(taps,lines) = par(i,taps,*(tap(i))),
37 par(i,lines,*(in(i)))
38 :> *(gain);
39
40
41 matrix(taps,lines) = ( bus(lines+taps)
42 <: tgroup("",
43 par(i, taps,
44 hgroup("Tap %i",
45 mixer(taps,lines) : delay(dsize,del))))
46 ) ~ bus(taps);
47
48
49 // tapiir
50 //--------
51
52 tapiir(taps,lines) = vgroup("Tapiir",
53 bus(lines)
54 <: (matrix(taps,lines), bus(lines))
55 <: vgroup( "outputs", par( i, lines, hgroup("output %i", mixer(taps,lines)) ) )
56 );
57
58
59
60 process = tapiir(6,2);
61
62