Sophie

Sophie

distrib > Mageia > 5 > x86_64 > media > core-release > by-pkgid > b707d9a4ee443103660a75ccb6e51334 > files > 2066

csound-doc-5.19.01-10.mga5.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>jitter2</title>
    <link rel="stylesheet" type="text/css" href="csound.css" />
    <meta name="generator" content="DocBook XSL Stylesheets V1.76.1" />
    <link rel="home" href="index.html" title="The Canonical Csound Reference Manual" />
    <link rel="up" href="OpcodesTop.html" title="Orchestra Opcodes and Operators" />
    <link rel="prev" href="jitter.html" title="jitter" />
    <link rel="next" href="joystick.html" title="joystick" />
  </head>
  <body>
    <div class="navheader">
      <table width="100%" summary="Navigation header">
        <tr>
          <th colspan="3" align="center">jitter2</th>
        </tr>
        <tr>
          <td width="20%" align="left"><a accesskey="p" href="jitter.html">Prev</a> </td>
          <th width="60%" align="center">Orchestra Opcodes and Operators</th>
          <td width="20%" align="right"> <a accesskey="n" href="joystick.html">Next</a></td>
        </tr>
      </table>
      <hr />
    </div>
    <div class="refentry" title="jitter2">
      <a id="jitter2"></a>
      <div class="titlepage"></div>
      <a id="IndexJitter2" class="indexterm"></a>
      <div class="refnamediv">
        <h2>
          <span class="refentrytitle">jitter2</span>
        </h2>
        <p>jitter2 — 
      Generates a segmented line with user-controllable random segments.
          </p>
      </div>
      <div class="refsect1" title="Description">
        <a id="idp27892896"></a>
        <h2>Description</h2>
        <p>
      Generates a segmented line with user-controllable random segments.
    </p>
      </div>
      <div class="refsect1" title="Syntax">
        <a id="idp27893672"></a>
        <h2>Syntax</h2>
        <pre class="synopsis">kout <span class="command"><strong>jitter2</strong></span> ktotamp, kamp1, kcps1, kamp2, kcps2, kamp3, kcps3</pre>
      </div>
      <div class="refsect1" title="Performance">
        <a id="idp27901960"></a>
        <h2>Performance</h2>
        <p>
      <span class="emphasis"><em>ktotamp</em></span> -- Resulting amplitude of jitter2
    </p>
        <p>
      <span class="emphasis"><em>kamp1</em></span> -- Amplitude of the first jitter component
    </p>
        <p>
      <span class="emphasis"><em>kcps1</em></span> -- Speed of random variation of the first jitter component (expressed in cps)
    </p>
        <p>
      <span class="emphasis"><em>kamp2</em></span> -- Amplitude of the second jitter component
    </p>
        <p>
      <span class="emphasis"><em>kcps2</em></span> -- Speed of random variation of the second jitter component (expressed in cps)
    </p>
        <p>
      <span class="emphasis"><em>kamp3</em></span> -- Amplitude of the third jitter component
    </p>
        <p>
      <span class="emphasis"><em>kcps3</em></span> -- Speed of random variation of the third jitter component (expressed in cps)
    </p>
        <p>
      <span class="emphasis"><em>jitter2</em></span> also generates a segmented line such as <a class="link" href="jitter.html" title="jitter"><em class="citetitle">jitter</em></a>, but in this case the result is similar to the sum of three <span class="emphasis"><em>randi</em></span> opcodes, each one with a different amplitude and frequency value (see <a class="link" href="randi.html" title="randi"><em class="citetitle">randi</em></a> for more details), that can be varied at k-rate. Different effects can be obtained by varying the input arguments.
    </p>
        <p>
      <span class="emphasis"><em>jitter2</em></span> can be used to make more natural and <span class="quote">“<span class="quote">analog-sounding</span>”</span> some static, dull sound. For best results, it is suggested to keep its amplitude moderate.
    </p>
      </div>
      <div class="refsect1" title="Examples">
        <a id="idp28008168"></a>
        <h2>Examples</h2>
        <p>
      Here is an example of the jitter2 opcode. It uses the file <a class="ulink" href="examples/jitter2.csd" target="_top"><em class="citetitle">jitter2.csd</em></a>.

      </p>
        <div class="example">
          <a id="idp28009152"></a>
          <p class="title">
            <strong>Example 383. Example of the jitter2 opcode.</strong>
          </p>
          <div class="example-contents">
            <p>See the sections <a class="link" href="UsingRealTime.html" title="Real-Time Audio"><em class="citetitle">Real-time Audio</em></a> and <a class="link" href="CommandFlags.html" title="Csound command line"><em class="citetitle">Command Line Flags</em></a> for more information on using command line flags.</p>
            <pre class="programlisting">
<span class="csdtag">&lt;CsoundSynthesizer&gt;</span>
<span class="csdtag">&lt;CsOptions&gt;</span>
<span class="comment">; Select audio/midi flags here according to platform</span>
-odac     <span class="comment">;;;realtime audio out</span>
<span class="comment">;-iadc    ;;;uncomment -iadc if realtime audio input is needed too</span>
<span class="comment">; For Non-realtime ouput leave only the line below:</span>
<span class="comment">; -o jitter2.wav -W ;;; for file output any platform</span>
<span class="csdtag">&lt;/CsOptions&gt;</span>
<span class="csdtag">&lt;CsInstruments&gt;</span>

<span class="ohdr">sr</span> <span class="op">=</span> 44100
<span class="ohdr">ksmps</span> <span class="op">=</span> 32
<span class="ohdr">nchnls</span> <span class="op">=</span> 2
<span class="ohdr">0dbfs</span>  <span class="op">=</span> 1

<span class="oblock">instr</span> 1

ktotamp <span class="opc">init</span> p4
kamp1   <span class="opc">init</span> .5
kcps1   <span class="opc">init</span> 10
kamp2   <span class="opc">init</span> .5
kcps2   <span class="opc">init</span> 2
kamp3   <span class="opc">init</span> .5
kcps3   <span class="opc">init</span> 3

kj2  <span class="opc">jitter2</span> ktotamp, kamp1, kcps1, kamp2, kcps2, kamp3, kcps3
aout <span class="opc">pluck</span> 1, 200<span class="op">+</span>kj2, 1000, 0, 1
aout <span class="opc">dcblock</span> aout
     <span class="opc">outs</span> aout, aout

<span class="oblock">endin</span>
<span class="csdtag">&lt;/CsInstruments&gt;</span>
<span class="csdtag">&lt;CsScore&gt;</span>

<span class="stamnt">i</span> 1 0 15 2	<span class="comment">;a bit jitter</span>
<span class="stamnt">i</span> 1 8 15 10	<span class="comment">;some more</span>
<span class="stamnt">i</span> 1 16 15 20	<span class="comment">;lots more</span>
<span class="stamnt">e</span>
<span class="csdtag">&lt;/CsScore&gt;</span>
<span class="csdtag">&lt;/CsoundSynthesizer&gt;</span>
</pre>
          </div>
        </div>
        <p><br class="example-break" />
    </p>
      </div>
      <div class="refsect1" title="See Also">
        <a id="idp28011464"></a>
        <h2>See Also</h2>
        <p>
      <a class="link" href="jitter.html" title="jitter"><em class="citetitle">jitter</em></a>,
      <a class="link" href="vibr.html" title="vibr"><em class="citetitle">vibr</em></a>,
      <a class="link" href="vibrato.html" title="vibrato"><em class="citetitle">vibrato</em></a>
    </p>
      </div>
      <div class="refsect1" title="Credits">
        <a id="idp28013488"></a>
        <h2>Credits</h2>
        <p>Author: Gabriel Maldonado</p>
        <p>New in Version 4.15</p>
      </div>
    </div>
    <div class="navfooter">
      <hr />
      <table width="100%" summary="Navigation footer">
        <tr>
          <td width="40%" align="left"><a accesskey="p" href="jitter.html">Prev</a> </td>
          <td width="20%" align="center">
            <a accesskey="u" href="OpcodesTop.html">Up</a>
          </td>
          <td width="40%" align="right"> <a accesskey="n" href="joystick.html">Next</a></td>
        </tr>
        <tr>
          <td width="40%" align="left" valign="top">jitter </td>
          <td width="20%" align="center">
            <a accesskey="h" href="index.html">Home</a>
          </td>
          <td width="40%" align="right" valign="top"> joystick</td>
        </tr>
      </table>
    </div>
  </body>
</html>