| 1 | <refentry id="GEN23"> |
| 2 | <indexterm id="IndexGEN23"><primary>GEN23</primary></indexterm> |
| 3 | <refmeta> |
| 4 | <refentrytitle>GEN23</refentrytitle> |
| 5 | </refmeta> |
| 6 | |
| 7 | <refnamediv> |
| 8 | <refname>GEN23</refname> |
| 9 | <refpurpose> |
| 10 | Reads numeric values from a text file. |
| 11 | </refpurpose> |
| 12 | </refnamediv> |
| 13 | |
| 14 | <refsect1> |
| 15 | <title>Description</title> |
| 16 | <para> |
| 17 | This subroutine reads numeric values from an external ASCII file. |
| 18 | </para> |
| 19 | </refsect1> |
| 20 | |
| 21 | <refsect1> |
| 22 | <title>Syntax</title> |
| 23 | <synopsis><command>f</command> # time size -23 "filename.txt"</synopsis> |
| 24 | </refsect1> |
| 25 | |
| 26 | <refsect1> |
| 27 | <title>Initialization</title> |
| 28 | <para> |
| 29 | <emphasis>"filename.txt"</emphasis> -- numeric values contained in "filename.txt" (which indicates the complete pathname of the character file to be read), can be separated by spaces, tabs, newline characters or commas. |
| 30 | </para> |
| 31 | |
| 32 | <para> |
| 33 | <emphasis>size</emphasis> -- number of points in the table. Must be a power of 2 , power of 2 + 1, or zero. If <emphasis>size</emphasis> = 0, table size is determined by the number of numeric values in <emphasis>filename.txt</emphasis>. (New in Csound version 3.57) |
| 34 | </para> |
| 35 | |
| 36 | <note> |
| 37 | <title>Note</title> |
| 38 | <para> |
| 39 | All characters following ';', '#' (comment) or '<' (XML |
| 40 | tag from version 6.04) are ignored until next line (numbers too). |
| 41 | </para> |
| 42 | </note> |
| 43 | </refsect1> |
| 44 | |
| 45 | <refsect1> |
| 46 | <title>Examples</title> |
| 47 | <para> |
| 48 | Here is an example of the GEN23 generator. It uses the file <ulink url="examples/gen23.csd"><citetitle>gen23.csd</citetitle></ulink> and <ulink url="examples/spectrum.txt"> <citetitle>spectrum.txt</citetitle></ulink>. |
| 49 | <example> |
| 50 | <title>Example of the GEN23 generator.</title> |
| 51 | <para>See the sections <link linkend="UsingRealTime"><citetitle>Real-time Audio</citetitle></link> and <link linkend="CommandFlags"><citetitle>Command Line Flags</citetitle></link> for more information on using command line flags.</para> |
| 52 | <xi:include href="examples-xml/gen23.csd.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/> |
| 53 | </example> |
| 54 | <textobject> |
| 55 | <phrase>This is the diagram of the waveform of the GEN23 routine, as used in the example:</phrase> |
| 56 | </textobject> |
| 57 | |
| 58 | <mediaobject> |
| 59 | <imageobject> |
| 60 | <imagedata fileref="images/gen23.png" format="PNG"/> |
| 61 | </imageobject> |
| 62 | |
| 63 | <textobject> |
| 64 | <phrase>f 2 0 128 -23 "spectrum.txt" - not normalized</phrase> |
| 65 | </textobject> |
| 66 | |
| 67 | <caption> |
| 68 | <para>f 2 0 128 -23 "spectrum.txt" - not normalized</para> |
| 69 | </caption> |
| 70 | </mediaobject> |
| 71 | |
| 72 | </para> |
| 73 | </refsect1> |
| 74 | <refsect1> |
| 75 | <title>Credits</title> |
| 76 | <para> |
| 77 | <simplelist> |
| 78 | <member>Author: &namegabriel;</member> |
| 79 | <member>Italy</member> |
| 80 | <member>February, 1998</member> |
| 81 | </simplelist> |
| 82 | </para> |
| 83 | |
| 84 | <para>New in Csound version 3.47. Comments starting with '#' are |
| 85 | ignored from Csound version 5.12.</para> |
| 86 | </refsect1> |
| 87 | </refentry> |