blob: 7ed6c836528bdabb36e6afb2eb17c4e169e95155 (
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
83
84
|
<refentry id="strtodk">
<indexterm id="Indexstrtodk"><primary>strtodk</primary></indexterm>
<refentryinfo><title>Strings:Conversion</title></refentryinfo>
<refmeta>
<refentrytitle>strtodk</refentrytitle>
</refmeta>
<refnamediv>
<refname>strtodk</refname>
<refpurpose>
Converts a string to a float (k-rate).
</refpurpose>
</refnamediv>
<refsect1>
<title>Description</title>
<para> Convert a string to a floating point value at i- or k-rate. It is also possible to pass an strset index or a string p-field from the score instead of a string
argument. If the string cannot be parsed as a floating point or integer number, an init or perf error occurs and the instrument is deactivated.
<note>
<title>Note</title>
<para>If a k-rate index variable is used, it should be
valid at i-time as well.
</para>
</note>
</para>
</refsect1>
<refsect1>
<title>Syntax</title>
<synopsis>kr <command>strtodk</command> Sstr</synopsis>
<synopsis>kr <command>strtodk</command> kndx</synopsis>
</refsect1>
<refsect1>
<title>Performance</title>
<para>
<emphasis>kr</emphasis> -- Value of string as float.
</para>
<para>
<emphasis>Sstr</emphasis> -- String to convert.
</para>
<para>
<emphasis>indx</emphasis> -- index of string set by strset
</para>
</refsect1>
<!--<refsect1>
<title>Examples</title>
<para>
Here is an example of the strtodk opcode. It uses the file <ulink url="examples/strtodk.csd"><citetitle>strtodk.csd</citetitle></ulink>.
<example>
<title>Example of the strtodk 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/strtodk.csd.xml" xmlns:xi="http://www.w3.org/2001/XInclude"/>
</example>
</para>
</refsect1>-->
<refsect1>
<title>Credits</title>
<para>
<simplelist>
<member>Author: Istvan Varga</member>
<member>2005</member>
</simplelist>
</para>
</refsect1>
</refentry>
|