Debian Codegraph @

opcodes/printk2.xml

raw symbols SCIP
1
2 <refentry id="printk2">
3 <indexterm id="IndexPrintk2"><primary>printk2</primary></indexterm>
4 <refentryinfo><title>Signal I/O:Printing and Display</title></refentryinfo>
5 <refmeta>
6 <refentrytitle>printk2</refentrytitle>
7 </refmeta>
8
9 <refnamediv>
10 <refname>printk2</refname>
11 <refpurpose>
12 Prints a new value every time a control variable changes.
13 </refpurpose>
14 </refnamediv>
15
16 <refsect1>
17 <title>Description</title>
18 <para>
19 Prints a new value every time a control variable changes.
20 </para>
21 </refsect1>
22
23 <refsect1>
24 <title>Syntax</title>
25 <synopsis><command>printk2</command> kvar [, inumspaces] [, inamed]</synopsis>
26 </refsect1>
27
28 <refsect1>
29 <title>Initialization</title>
30 <para>
31 <emphasis>inumspaces</emphasis> (optional, default=0) -- number
32 of space characters printed before the value of
33 <emphasis>kvar</emphasis>.
34 </para>
35 <para>
36 <emphasis>inamed</emphasis> (optional, default=0) -- if non zero
37 print the name of the <emphasis>kvar</emphasis> as well as the value.
38 </para>
39 </refsect1>
40
41 <refsect1>
42 <title>Performance</title>
43 <para>
44 <emphasis>kvar</emphasis> -- signal to be printed
45 </para>
46
47 <para>
48 Derived from Robin Whittle's <emphasis>printk</emphasis>, prints a new value of <emphasis>kvar</emphasis> each time <emphasis>kvar</emphasis> changes. Useful for monitoring MIDI control changes when using sliders.
49 </para>
50
51 <warning>
52 <para>
53 <emphasis>WARNING!</emphasis> Do not use this opcode with normal, continuously variant k-signals, because it can hang the computer, as the rate of printing is too fast.
54 </para>
55 </warning>
56 </refsect1>
57
58 <refsect1>
59 <title>Examples</title>
60
61 <para>
62 Here is an example of the printk2 opcode. It uses the file <ulink url="examples/printk2.csd"><citetitle>printk2.csd</citetitle></ulink>.
63 <example>
64 <title>Example of the printk2 opcode.</title>
65 <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>
66 <xi:include href="examples-xml/printk2.csd.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/>
67 </example>
68
69 Its output should include lines like these:
70 <screen>
71 i1 0.00000
72 i1 3.00000
73 i1 1.00000
74 i1 3.00000
75 i1 1.00000
76 i1 2.00000
77 i1 3.00000
78 .....
79 </screen>
80 </para>
81 </refsect1>
82
83 <refsect1>
84 <title>See also</title>
85 <para><link linkend="SigioPdisplay"><citetitle>Printing and Display</citetitle></link></para>
86 </refsect1>
87
88 <refsect1>
89 <title>Credits</title>
90 <para>
91 <simplelist>
92 <member>Author: &namegabriel;</member>
93 <member>Italy</member>
94 <member>1998</member>
95 </simplelist>
96 </para>
97 <para>New in Csound version 3.48</para>
98 <para>named option new in 6.11</para>
99 </refsect1>
100 </refentry>