Debian Codegraph @

preface/toot8XO.xml

raw symbols SCIP
1 <section id="PrefaceToot8">
2 <title>Toot 8</title>
3
4 <para>
5 Now instead of continuing to enhance the same instrument, we will design a totally different one. In it we'll play a soundfile from disk in the orchestra, apply an amplitude envelope to it, and add some reverb. To do this we will employ Csound's <link linkend="soundin"><citetitle>soundin</citetitle></link> and <link linkend="reverb"><citetitle>reverb</citetitle></link> generators. The first is used like this:
6 </para>
7
8 <programlisting>a1 <emphasis role="opc">soundin</emphasis> ifilcod[, iskiptime[, iformat]]</programlisting>
9
10 <para>
11 <link linkend="soundin"><citetitle>soundin</citetitle></link> derives its signal from a pre-existing file. <emphasis>ifilcod</emphasis> is either the filename in double quotes, or an integer suffix (.n) to the name "soundin". Thus the file soundin.5 could be referenced either by the quoted name or by the integer 5. To read from 500ms into this file we might say (i.e. to skip the first 500ms):
12 </para>
13
14 <programlisting>a1 <emphasis role="opc">soundin</emphasis> "soundin.5", .5</programlisting>
15
16 <para>
17 The Csound <link linkend="reverb"><citetitle>reverb</citetitle></link> generator is actually composed of four parallel <link linkend="comb"><citetitle>comb</citetitle></link> filters plus two <link linkend="alpass"><citetitle>alpass</citetitle></link> filters in series. Although we could design a variant of our own using these same primitives, the preset reverb is convenient, and simulates a natural room response via internal parameter values. Only two arguments are required the input (<emphasis>asig</emphasis>) and the reverb time (<emphasis>krvt</emphasis>)
18 </para>
19
20 <programlisting>ar <emphasis role="opc">reverb</emphasis> asig, krvt</programlisting>
21
22 <para>
23 Here's a schematic representation of the instrument.
24 </para>
25 <para>
26 <mediaobject>
27 <imageobject>
28 <imagedata fileref="images/toot08.gif" format="GIF"/>
29 </imageobject>
30 <textobject>
31 <phrase>[TOOT 8 Schematic]</phrase>
32 </textobject>
33 <caption>
34 <para>TOOT 8 Schematic</para>
35 </caption>
36 </mediaobject>
37 </para>
38 <para>
39 The soundfile instrument with artificial envelope and a reverb (included directly) is as follows:
40 </para>
41 <para>
42 <xi:include href="examples-xml/toot8.csd.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/>
43 </para>
44 </section>