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
|
<HTML>
<TITLE>F_STATEMENT</TITLE>
<CENTER><P><A NAME="F_STATEMENT"></A>
<HR><B><A HREF="../REFER.html">QUICK-REF</A></B> - <B><A HREF="../TITLE.html"><FONT SIZE=+1>C</FONT>soundManual</A></B>
- <B><A HREF="././NUMSC.html">Top of this section</A></B> - <A HREF="./ramp.html">Previous</A>
- <A HREF="../CONTENTS.html">Contents</A> - <A HREF="../INDEX.html">Index</A>
- <A HREF="./i-stat.html">Next</A>
<HR></P></CENTER>
<H2>F STATEMENT (or FUNCTION TABLE STATEMENT)</H2>
<PRE><TT> <B>f</B> p1 p2 p3 p4 ... </TT>
</PRE>
<P>
<HR></P>
<H4><U>DESCRIPTION</U></H4>
<P>This causes a <B><A HREF="./../Function/GENS.html">GEN</A></B> subroutine
to place values in a stored function table for use by instruments. </P>
<H4><U>PFIELDS </U></H4>
<PRE><TT> p1 Table number (from 1 to 200) by which the stored function will be known.
A negative number requests that the table be destroyed.
p2 Action time of function generation (or destruction) in beats.
p3 Size of function table (i.e. number of points)
Must be a power of 2, or a power-of-2 plus 1 (see below).
Maximum table size is 16777216 (2**24) points.
p4 Number of the GEN routine to be called (<A HREF="./../Function/GENS.html">see GEN ROUTINES</A>).
A negative value will cause rescaling to be omitted.
p5 |
p6 | Parameters whose meaning is determined by the particular GEN routine.
. |
. |</TT>
</PRE>
<H4><U>SPECIAL CONSIDERATIONS </U></H4>
<P>Function tables are arrays of floating-point values. Arrays can be of
any length in powers of 2; space allocation always provides for 2**n points
plus an additional <I>guard point</I>. The guard point value, used during
interpolated lookup, can be automatically set to reflect the table's purpose:
If <I>size</I> is an exact power of 2, the guard point will be a copy of
the first point; this is appropriate for <I>interpolated wrap-around lookup</I>
as in <B><A HREF="./../Generate/oscil.html">oscili</A></B>, etc., and should
even be used for non-interpolating <B><A HREF="./../Generate/oscil.html">oscil</A></B>
for safe consistency. If <I>size</I> is set to 2**n + 1, the guard point
value automatically extends the contour of table values; this is appropriate
for single-scan functions such in <B><A HREF="./../Modifier/linen.html">envlpx</A>,
<A HREF="./../Generate/table.html">oscil1</A>, <A HREF="./../Generate/table.html">oscil1i</A>,</B>
etc. </P>
<P>Table space is allocated in primary memory, along with instrument data
space. The maximum table number has a soft limit of 200; this can be extended
if required. </P>
<P>An existing function table can be removed by an <B>f</B> statement containing
a negative p1 and an appropriate action time. A function table can also
be removed by the generation of another table with the same p1. Functions
are not automatically erased at the end of a score section. </P>
<P>p2 action time is treated in the same way as in <B><A HREF="./i-stat.html">i
statements</A></B> with respect to sorting and modification by <B><A HREF="./t-stat.html">t
statements</A></B>. If an f statement and an <B>i</B> statement have the
same p2, the sorter gives the <B>f</B> statement precedence so that the
function table will be available during note initialization. </P>
<P>An <B>f 0</B> statement (zero p1, positive p2) may be used to create
an action time with no associated action. Such time markers are useful
for padding out a score section <A HREF="./s-stat.html">(see s statement</A>).</P>
<CENTER><P>
<HR><B><A HREF="../REFER.html">QUICK-REF</A></B> - <B><A HREF="../TITLE.html"><FONT SIZE=+1>C</FONT>soundManual</A></B>
- <B><A HREF="././NUMSC.html">Top of this section</A></B> - <A HREF="./ramp.html">Previous</A>
- <A HREF="../CONTENTS.html">Contents</A> - <A HREF="../INDEX.html">Index</A>
- <A HREF="./i-stat.html">Next</A>
<HR></P></CENTER>
<P><CENTER>
<B><I><FONT COLOR="#006600">HTML Csound Manual - <FONT SIZE=-1>©
Jean Piché & Peter J. Nix, 1994-97</FONT></FONT></I></B>
</CENTER>
</HTML>
|