summaryrefslogtreecommitdiff
path: root/opcodes/rspline.xml
blob: 683afe844f033fb1c50d075ed425b6c81efcef22 (plain)
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
<refentry id="rspline">
<indexterm id="IndexRspline"><primary>rspline</primary></indexterm>
  <refentryinfo><title>Signal Generators:Linear and Exponential Generators</title></refentryinfo>
  <refmeta>
    <refentrytitle>rspline</refentrytitle>
  </refmeta>

  <refnamediv>
    <refname>rspline</refname>
    <refpurpose>
      Generate random spline curves.
    </refpurpose>
  </refnamediv>

  <refsect1>
    <title>Description</title>
    <para>
      Generate random spline curves.
    </para>
  </refsect1>

  <refsect1>
    <title>Syntax</title>
    <synopsis>ares <command>rspline</command> xrangeMin, xrangeMax, kcpsMin, kcpsMax</synopsis>

    <synopsis>kres <command>rspline</command> krangeMin, krangeMax, kcpsMin, kcpsMax</synopsis>
  </refsect1>

  <refsect1>
    <title>Performance</title>
    <para>
      <emphasis>kres, ares</emphasis> -- Output signal
    </para>

    <para>
      <emphasis>xrangeMin, xrangeMax</emphasis> -- Range of values of random-generated points
    </para>

    <para>
      <emphasis>kcpsMin, kcpsMax</emphasis> -- Range of point-generation rate. Min and max limits are expressed in cps.
    </para>
<!--
    <para>
      <emphasis>xamp</emphasis> - Amplitude factor
    </para>-->

    <para>
      <emphasis>rspline</emphasis> (random-spline-curve generator) is similar to <link linkend="jspline"><citetitle>jspline</citetitle></link> but output range is defined by means of two limit values. Also in this case, real output range could be a bit greater of range values, because of interpolating curves beetween each pair of random-points.
    </para>

    <para>
      At present time generated curves are quite smooth when <emphasis>cpsMin</emphasis> is not too different from <emphasis>cpsMax</emphasis>. When <emphasis>cpsMin-cpsMax</emphasis> interval is big, some little discontinuity could occurr, but it should not be a problem, in most cases. Maybe the algorithm will be improved in next versions.
    </para>

    <para>
      These opcodes are often better than <link linkend="jitter"><citetitle>jitter</citetitle></link> when user wants to <quote>naturalize</quote> or <quote>analogize</quote> digital sounds. They could be used also in algorithmic composition, to generate smooth random melodic lines when used together with <link linkend="samphold"><citetitle>samphold</citetitle></link> opcode.
    </para>

    <para>
      Note that the result is quite different from the one obtained by filtering white noise, and they allow the user to obtain a much more precise control.
    </para>
  </refsect1>

  <refsect1>
    <title>Examples</title>
    <para>
      Here is an example of the rspline opcode. It uses the file <ulink url="examples/rspline.csd"><citetitle>rspline.csd</citetitle></ulink>.
      <example>
        <title>Example of the rspline opcode.</title>
        <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>
          <xi:include href="examples-xml/rspline.csd.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/>
      </example>
    </para>
  </refsect1>

  <refsect1>
    <title>Credits</title>
    <para>Author: &namegabriel;</para>
    <para>New in version 4.15</para>
  </refsect1>
</refentry>