Debian Codegraph @

utility/cs.xml

raw symbols SCIP
1 <refentry id="cs">
2 <refentryinfo><title>Utilities</title></refentryinfo>
3 <refmeta>
4 <refentrytitle>cs</refentrytitle>
5 </refmeta>
6 <refnamediv>
7 <refname>cs</refname>
8 <refpurpose>
9 Starts Csound with a set of options that can be controlled
10 by environment variables, and input and output files
11 determined by the specified filename stem.
12 <indexterm id="IndexCs">
13 <primary>cs</primary>
14 </indexterm>
15 </refpurpose>
16 </refnamediv>
17
18 <refsect1>
19 <title>Description</title>
20 <para>
21 Starts Csound with a set of options that can be controlled
22 by environment variables, and input and output files
23 determined by the specified filename stem.
24 </para>
25 </refsect1>
26
27 <refsect1>
28 <title>Syntax</title>
29 <synopsis><command>cs</command> [-OPTIONS] &lt;name&gt; [CSOUND OPTIONS ... ]</synopsis>
30 </refsect1>
31
32 <refsect1>
33 <title>Initialization</title>
34 <para>
35 Flags:
36 <itemizedlist>
37
38 <listitem>
39 <para>
40 -
41 <emphasis>OPTIONS</emphasis>
42 = OPTIONS is a sequence of alphabetic characters
43 that can be used for selecting the Csound
44 executable to be run, as well as the command
45 line flags (see below). There is a default for
46 the option 'r' (selects real-time output), but
47 it can be overridden.
48 </para>
49 </listitem>
50
51 <listitem>
52 <para>
53 <emphasis>&lt;name&gt;</emphasis>
54 = this is the filename stem for selecting input
55 files; it may contain a path. Files that have
56 .csd, .orc, or .sco extension are searched, and
57 either a CSD or an orc/sco pair that matches
58 &lt;name&gt; the best are selected. MIDI files
59 with a .mid extension are also searched, and if
60 one that matches &lt;name&gt; at least as close
61 as the CSD or orc/sco pair, it is used with the
62 -F flag.
63
64 <note>
65 <title>NOTE</title>
66 <para>
67 The MIDI file is not used if any -M or
68 -F flag is specified by the user - new
69 in version 4.24.0) Unless there is any
70 option (-n or -o) related to audio
71 output, an output file name with the
72 appropriate extension is automatically
73 generated (based on the name of selected
74 input files and format options). The
75 output file is always written to the
76 current directory.
77
78 </para>
79 </note>
80
81 <note>
82 <title>NOTE</title>
83 <para>
84 file name extensions are not case
85 sensitive.
86
87 </para>
88 </note>
89
90 </para>
91 </listitem>
92
93 <listitem>
94 <para>
95 <emphasis>[CSOUND OPTIONS ... ]</emphasis>
96 = any number of additional options for Csound
97 that are simply copied to the final command line
98 to be executed.
99 </para>
100 </listitem>
101 </itemizedlist>
102 </para>
103
104 <para>
105 The command line that is executed is generated from four
106 parts:
107
108 <orderedlist>
109 <listitem>
110 <para>
111 Csound executable (possibly with options). This
112 is exactly one of the following (the last one
113 has the highest precedence):
114
115 <itemizedlist>
116 <listitem>
117 <para>
118 a built-in default
119 </para>
120 </listitem>
121
122 <listitem>
123 <para>
124 the value of the CSOUND environment
125 variable
126 </para>
127 </listitem>
128
129 <listitem>
130 <para>
131 environment variables with a name in
132 the format of CSOUND_x where x is an
133 uppercase letter selected by
134 characters of the -OPTIONS string.
135 Thus, if the -dcba option is used,
136 and the environment variables
137 CSOUND_B and CSOUND_C are defined,
138 the value of CSOUND_B will take
139 effect.
140 </para>
141 </listitem>
142 </itemizedlist>
143 </para>
144 </listitem>
145 <listitem>
146 <para>
147 Any number of option lists, added in the
148 following order:
149 <itemizedlist>
150 <listitem>
151 <para>
152 either some built-in defaults, or
153 the value of the CSFLAGS environment
154 variable if it is defined.
155 </para>
156 </listitem>
157 <listitem>
158 <para>
159 environment variables with a name in
160 the format of CSFLAGS_x where x is
161 an uppercase letter selected by
162 characters of the -OPTIONS string.
163 Thus, if the -dcba option is used,
164 and the environment variables
165 CSFLAGS_A and CSFLAGS_C are defined
166 as '-M 1 -o dac' and '-m231 -H0',
167 respectively, the string '-m231 -H0
168 -M 1 -o dac' will be added.
169 </para>
170 </listitem>
171 </itemizedlist>
172 </para>
173 </listitem>
174 <listitem>
175 <para>
176 The explicit options of [CSOUND OPTIONS ... ].
177 </para>
178 </listitem>
179 <listitem>
180 <para>
181 Any options and file names generated from
182 &lt;name&gt;.
183 </para>
184 </listitem>
185 </orderedlist>
186 <note>
187 <title>NOTE</title>
188 <para>
189 Quoted options that contain spaces are allowed.
190 </para>
191 </note>
192 </para>
193 </refsect1>
194 <refsect1>
195 <title>Examples</title>
196 <para>
197 Assuming the following environment variables:
198
199 <screen>
200 CSOUND = csoundfltk.exe -W
201 CSOUND_D = csound64.exe -J
202 CSOUND_R = csoundfltk.exe -h
203
204 CSFLAGS = -d -m135 -H1 -s
205 CSFLAGS_D = -f
206 CSFLAGS_R = -m0 -H0 -o dac1 -M "MIDI Yoke NT: 1" -b 200 -B 6000</screen>
207
208 And a directory that contains:
209
210 <screen>
211 foo.orc piano.csd
212 foo.sco piano.mid
213 im.csd piano2.mid
214 ImproSculpt2_share.csd foobar.csd</screen>
215
216 The following commands will execute as shown:
217
218 <screen>
219 cs foo => csoundfltk.exe -W -d -m135 -H1 -s -o foo.wav \
220 foo.orc foo.sco
221
222 cs foob => csoundfltk.exe -W -d -m135 -H1 -s \
223 -o foobar.wav foobar.csd
224
225 cs -r imp -i adc => csoundfltk.exe -h -d -m135 -H1 -s -m0 -H0 \
226 -o dac1 -M "MIDI Yoke NT: 1" \
227 -b 200 -B 6000 -i adc \
228 ImproSculpt2_share.csd
229
230 cs -d im => csound64.exe -J -d -m135 -H1 -s -f -o im.sf \
231 im.csd
232
233 cs piano => csoundfltk.exe -W -d -m135 -H1 -s \
234 -F piano.mid -o piano.wav \
235 piano.csd
236
237 cs piano2 => csoundfltk.exe -W -d -m135 -H1 -s \
238 -F piano2.mid -o piano2.wav \
239 piano.csd</screen>
240 </para>
241
242 </refsect1>
243
244 <refsect1>
245 <title>Credits</title>
246 <para>Author: Istvan Varga</para>
247 <para>Jan 2003</para>
248 </refsect1>
249 </refentry>