Sophie

Sophie

distrib > Fedora > 15 > i386 > by-pkgid > 6ed14ebfd686aa32f7956e552aa2e21d > files > 184

csound-manual-5.13.0-5.fc15.noarch.rpm

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
    <title>GEN20</title>
    <link rel="stylesheet" href="csound.css" type="text/css" />
    <meta name="generator" content="DocBook XSL Stylesheets V1.75.2" />
    <link rel="home" href="index.html" title="The Canonical Csound Reference Manual" />
    <link rel="up" href="ScoregensTop.html" title="Score Statements and GEN Routines" />
    <link rel="prev" href="GEN19.html" title="GEN19" />
    <link rel="next" href="GEN21.html" title="GEN21" />
  </head>
  <body>
    <div class="navheader">
      <table width="100%" summary="Navigation header">
        <tr>
          <th colspan="3" align="center">GEN20</th>
        </tr>
        <tr>
          <td width="20%" align="left"><a accesskey="p" href="GEN19.html">Prev</a> </td>
          <th width="60%" align="center">Score Statements and GEN Routines</th>
          <td width="20%" align="right"> <a accesskey="n" href="GEN21.html">Next</a></td>
        </tr>
      </table>
      <hr />
    </div>
    <div class="refentry" title="GEN20">
      <a id="GEN20"></a>
      <div class="titlepage"></div>
      <a id="IndexGEN20" class="indexterm"></a>
      <div class="refnamediv">
        <h2>
          <span class="refentrytitle">GEN20</span>
        </h2>
        <p>GEN20 — 
      Generates functions of different windows.
    </p>
      </div>
      <div class="refsect1" title="Description">
        <a id="id3739416"></a>
        <h2>Description</h2>
        <p>
      This subroutine generates functions of different windows. These windows are usually used for spectrum analysis or for grain envelopes.
    </p>
      </div>
      <div class="refsect1" title="Syntax">
        <a id="id3739428"></a>
        <h2>Syntax</h2>
        <pre class="synopsis"><span class="command"><strong>f</strong></span> # time size 20 window max [opt]</pre>
      </div>
      <div class="refsect1" title="Initialization">
        <a id="id3739173"></a>
        <h2>Initialization</h2>
        <p>
      <span class="emphasis"><em>size</em></span> -- number of points in the table. Must be a power of 2 ( + 1).
    </p>
        <p>
      <span class="emphasis"><em>window</em></span> -- Type of window to generate:

      </p>
        <div class="itemizedlist">
          <ul class="itemizedlist" type="disc">
            <li class="listitem">
              <p>1 = Hamming</p>
            </li>
            <li class="listitem">
              <p>2 = Hanning</p>
            </li>
            <li class="listitem">
              <p>3 = Bartlett ( triangle)</p>
            </li>
            <li class="listitem">
              <p>4 = Blackman ( 3-term)</p>
            </li>
            <li class="listitem">
              <p>5 = Blackman - Harris ( 4-term)</p>
            </li>
            <li class="listitem">
              <p>6 = Gaussian</p>
            </li>
            <li class="listitem">
              <p>7 = Kaiser</p>
            </li>
            <li class="listitem">
              <p>8 = Rectangle</p>
            </li>
            <li class="listitem">
              <p>9 = Sync</p>
            </li>
          </ul>
        </div>
        <p>
    </p>
        <p>
      <span class="emphasis"><em>max</em></span> -- For negative p4 this will be the absolute 
      value at window peak point. If p4 is positive or p4 is negative
      and p6 is missing the table will be post-rescaled to a maximum
      value of 1. 
    </p>
        <p>
      <span class="emphasis"><em>opt</em></span> -- Optional argument required by the 
      Gaussian window and the Kaiser window.
    </p>
      </div>
      <div class="refsect1" title="Examples">
        <a id="id3740175"></a>
        <h2>Examples</h2>
        <p>
      </p>
        <div class="informalexample">
          <pre class="programlisting">
<span class="stamnt">f</span>       1       0       1024    20      5</pre>
        </div>
        <p>

      This creates a function which contains a 4 - term Blackman - Harris window with maximum value of 1.
    </p>
        <p>
      </p>
        <div class="informalexample">
          <pre class="programlisting">
<span class="stamnt">f</span>       1       0       1024    -20     2       456</pre>
        </div>
        <p>

      This creates a function that contains a Hanning window with a maximum value of 456.
    </p>
        <p>
      </p>
        <div class="informalexample">
          <pre class="programlisting">
<span class="stamnt">f</span>       1       0       1024    -20     1</pre>
        </div>
        <p>

      This creates a function that contains a Hamming window with a maximum value of 1.
    </p>
        <p>
      </p>
        <div class="informalexample">
          <pre class="programlisting">
<span class="stamnt">f</span>       1       0       1024    20      7       1       2</pre>
        </div>
        <p>

      This creates a function that contains a Kaiser window with a maximum value of 1. The extra argument specifies how "open" the window is, for example a value of 0 results in a rectangular window and a value of 10 in a Hamming like window.
    </p>
        <p>
      </p>
        <div class="informalexample">
          <pre class="programlisting">
<span class="stamnt">f</span>       1       0       1024    20      6       1       2</pre>
        </div>
        <p>

      This creates a function that contains a Gaussian window with a
      maximum value of 1.  The extra argument specifies how broad the
      window is, as the standard deviation of the curve; in this
      example the s.d. is 2.  The default value is 1.
    </p>
        <p>
      For diagrams, see <a class="link" href="MiscWindows.html" title="Appendix F. Window Functions"><em class="citetitle">Window Functions</em></a>
    </p>
      </div>
      <div class="refsect1" title="Credits">
        <a id="id3740309"></a>
        <h2>Credits</h2>
        <p>
      </p>
        <table border="0" summary="Simple list" class="simplelist">
          <tr>
            <td>Author: Paris Smaragdis</td>
          </tr>
          <tr>
            <td>MIT, Cambridge</td>
          </tr>
          <tr>
            <td>1995</td>
          </tr>
        </table>
        <p>
    </p>
        <p>
      </p>
        <table border="0" summary="Simple list" class="simplelist">
          <tr>
            <td>Author: John ffitch</td>
          </tr>
          <tr>
            <td>University of Bath/Codemist Ltd.</td>
          </tr>
          <tr>
            <td>Bath, UK</td>
          </tr>
        </table>
        <p>
    </p>
        <p>New in Csound version 3.2</p>
        <p>Optional argument to Gaussian added in 5.10</p>
      </div>
    </div>
    <div class="navfooter">
      <hr />
      <table width="100%" summary="Navigation footer">
        <tr>
          <td width="40%" align="left"><a accesskey="p" href="GEN19.html">Prev</a> </td>
          <td width="20%" align="center">
            <a accesskey="u" href="ScoregensTop.html">Up</a>
          </td>
          <td width="40%" align="right"> <a accesskey="n" href="GEN21.html">Next</a></td>
        </tr>
        <tr>
          <td width="40%" align="left" valign="top">GEN19 </td>
          <td width="20%" align="center">
            <a accesskey="h" href="index.html">Home</a>
          </td>
          <td width="40%" align="right" valign="top"> GEN21</td>
        </tr>
      </table>
    </div>
  </body>
</html>