Debian Codegraph @

opcodes/ctrl14.xml

raw symbols SCIP
1
2 <refentry id="ctrl14">
3 <indexterm id="IndexCtrl14"><primary>ctrl14</primary></indexterm>
4 <refentryinfo><title>Real-time MIDI:Input</title></refentryinfo>
5 <refmeta>
6 <refentrytitle>ctrl14</refentrytitle>
7 </refmeta>
8
9
10
11 <refnamediv>
12 <refname>ctrl14</refname>
13
14 <refpurpose>
15 Allows a floating-point 14-bit MIDI signal scaled with a minimum and a maximum range.
16 </refpurpose>
17 </refnamediv>
18
19 <refsect1>
20 <title>Description</title>
21 <para>
22 Allows a floating-point 14-bit MIDI signal scaled with a minimum and a maximum range.
23 </para>
24 </refsect1>
25
26 <refsect1>
27 <title>Syntax</title>
28 <synopsis>idest <command>ctrl14</command> ichan, ictlno1, ictlno2, imin, imax [, ifn]</synopsis>
29
30 <synopsis>kdest <command>ctrl14</command> ichan, ictlno1, ictlno2, kmin, kmax [, ifn]</synopsis>
31 </refsect1>
32
33 <refsect1>
34 <title>Initialization</title>
35 <para>
36 <emphasis>idest</emphasis> -- output signal
37 </para>
38
39 <para>
40 <emphasis>ichan</emphasis> -- MIDI channel number (1-16)
41 </para>
42
43 <para>
44 <emphasis>ictln1o</emphasis> -- most-significant byte controller number (0-127)
45 </para>
46
47 <para>
48 <emphasis>ictlno2</emphasis> -- least-significant byte controller number (0-127)
49 </para>
50
51 <para>
52 <emphasis>imin</emphasis> -- user-defined minimum floating-point value of output
53 </para>
54
55 <para>
56 <emphasis>imax</emphasis> -- user-defined maximum floating-point value of output
57 </para>
58
59 <para>
60 <emphasis>ifn</emphasis> (optional) -- table to be read when indexing is required. Table must be normalized. Output is scaled according to <emphasis>imax</emphasis> and <emphasis>imin</emphasis> val.
61 </para>
62 </refsect1>
63
64 <refsect1>
65 <title>Performance</title>
66 <para>
67 <emphasis>kdest</emphasis> -- output signal
68 </para>
69
70 <para>
71 <emphasis>kmin</emphasis> -- user-defined minimum floating-point value of output
72 </para>
73
74 <para>
75 <emphasis>kmax</emphasis> -- user-defined maximum floating-point value of output
76 </para>
77
78 <para>
79 <emphasis>ctrl14</emphasis> (i- and k-rate 14 bit MIDI control) allows a floating-point 14-bit MIDI signal scaled with a minimum and a maximum range. The minimum and maximum values can be varied at k-rate. It can use optional interpolated table indexing. It requires two MIDI controllers as input.
80 </para>
81
82 <para>
83 <emphasis>ctrl14</emphasis> differs from <link linkend="midic14"><citetitle>midic14</citetitle></link> because it can be included in score-oriented instruments without Csound crashes. It needs the additional parameter <emphasis>ichan</emphasis> containing the MIDI channel of the controller. MIDI channel is the same for all the controllers used in a single <emphasis>ctrl14</emphasis> opcode.
84 </para>
85 </refsect1>
86
87 <refsect1>
88 <title>Examples</title>
89 <para>
90 Here is an example of the ctrl14 opcode. It uses the file <ulink url="examples/ctrl14.csd"><citetitle>ctrl14.csd</citetitle></ulink>.
91
92 <example>
93 <title>Example of the ctrl14 opcode.</title>
94 <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>
95 <xi:include href="examples-xml/ctrl14.csd.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/>
96 </example>
97 </para>
98 </refsect1>
99
100 <refsect1>
101 <title>See also</title>
102 <para><link linkend="MidiInput"><citetitle>MIDI input and Initialization</citetitle></link></para>
103 </refsect1>
104
105 <refsect1>
106 <title>Credits</title>
107 <para>
108 <simplelist>
109 <member>Author: &namegabriel;</member>
110 <member>Italy</member>
111 </simplelist>
112 </para>
113
114 <para>New in Csound version 3.47</para>
115 <para>Thanks goes to &namerasmus; for pointing out the correct MIDI channel and controller number ranges.</para>
116 </refsect1>
117 </refentry>