This document is about using the GUI of CsoundAV (ex-DirectCsound).
GUI has been introduced starting from version 4.0 of DirectCsound.
Notice that previous versions of CsoundAV were console-based, whereas present version is a true Win32 program. So something has been changed.
The usage of this version should be easier than previous console-based versions.
This document takes it for granted that the reader already knows older versions
of DirectCsound. See the main Csound Manual for more information.
Main Csound Manual can be downloaded at the following urls:
http://hem.passagen.se/rasmuse/Csound.htm (WinHelp format, RECOMMENDED);
There are several ways to start CsoundAV program:
Since methods 3-4-6 are also possible with older console-based versions of Csound, I treat only the methods 1 and 2 in this document.
This is the standard method of starting most windows programs. However, in older versions, this way of running Csound caused an error; in fact, in order to be correctly run, older versions required additional command-line arguments (at least the orchestra and the score file names).
Now things have changed: by double-clicking the program icon a dialog box will be opened, expecting the user to fill empty text-fields:
Button "Set environment directory paths" permits to modify environment variables
(see section 2.7 below).
Notice that not always all fields have to be filled. In realtime sessions "Ouput File" field must be left blank. Using realtime-oriented orchestras with .rto extension, both "Ouput File" and "Sco File" fields can be left blank. Furthermore, when using .csd file, the only field to be filled is "Orc File". This can be obtained very fastly by dragging a .csd file directly towards this dialog box, dropping it and pressing <return>. Also, dragging an .orc file to this window produces the same result. In this last case, however, the user must be sure that the command line flags are those desired.
Notice that file-related text-fields have a "Browse..." button, in order to allow the user to search the complete pathname of the corresponding file by browsing it with a common-dialog-box:
Notice that, if you leave all fields blank, this error message will occur:
indicating that some command-line arguments are needed. However this action doesn't terminate the program, i.e. even after closing this message-box you are still able to operate with CsoundAV, but the program will be in stop state, waiting the user to choose some action in order to start a realtime or deferred-time session.
The second way to start CsoundAV is by dragging a .csd file directly to the program icon, or to a shortcut to it.
When starting CsoundAV in realtime sessions, if provided flags don't specify the AUDIO and/or MIDI port number, new message-boxes can appear, listing currently installed devices and asking the user to select one of them.
In this case the user has to type the MIDI IN port number and press <Return> (or click the "OK" button). For example, to choose the "SB Live! MIDI In [B800]" port the user must type "0" and press <Return>.
CsundAV can be quitted by clicking the "Quit" button, or the X button on the top right of the Main window. Also a keyboard key can be used for quit it. This is the ESC key for the GUI version, and CTRL-C for the console version.
The main window of CsoundAV has a set of command buttons allowing several
To stop a Csound session, just click the "Stop" button. Current session will stop and the button label will be changed into "Start". To restart Csound with the same command line arguments, just click this button again.
Version 4.0 allows to start/pause the hard-disk recording of a realtime session of Csound.
In order to enable recording, user must open a file by filling the corresponding text-field with the name of the file to be created and by clicking the "Open/Close File" check-box (notice that the check-box cannot be checked until the text-field has been filled with the file name).
Then user must start recording by clicking the "Start" button. He can pause recording without stopping realtime session by clicking the "Pause" button. Notice that the "Start" and "Pause" buttons are disabled if the audio file is not already opened (i.e. when the check-box is not checked).
You can close the file without stopping current session of Csound by clicking the "Open/Close File" check-box again.
An audio-file generated by hard-disk recording has no header, even if the extension is .wav or .aif
The "Sleep" check-box allows to enable/disable the corresponding sleep-mode during a realtime session.
Sleep mode raises the priority of current CsoundAV process, in order to reduce sound-interruptions and tics due to interactions with other programs running in parallel with CsoundAV, such as, for example, VMCI. The drawback of using "Sleep" mode is that the buffer lenght must be at least 300 or more, so latency delay is bigger than normal mode.
You can try to switch on/off this feature (and to raise/lower buffer length) during a session, in order to find the best obtainable performance.
By clicking "Suppress Display" button it is possible to suppress console-text-messages of Csound. The label of this button will turn "Enable Display", and, by clicking it again, it is possible to restore console message display.
It is highly recommended to suppress console display during realtime session in order to avoid sound-flow interruptions causing clicks and noise.
The "Restart with new cmd-line args..." button stops current eventually-running session of Csound and displays the command arguments dialog-box which allows the user to fill text-fields and to run Csound with new arguments.
The horizontal slider near the top of console-area allows to modify buffer
length during a realtime session.
This can be used to interactively find the best obtainable buffer length. This feature should be tuned-up together with the "Sleep" check-box to find the optimal configuration for realtime performance of current orchestra .
By pushing the button "Set Environment paths" the following dialog-box will be displayed:
You can set all directory path in corresponding fields. Notice that new environment variables have been added with respect of canonical Csound version. Here is a list of the names of the environment variables and their meaning:
Directories are automatically saved in Windows registry at the end of a session, so user doesn't have to set them all times.
In particular, you have to include OpenGL.h file (provided together with the archives containing executables) in all orchestras using animated graphics. So, such file should be placed in a directory corresponding to INCDIR path.
User can vary output gain by tweaking "Overall Output Gain" slider
2.9 Special command-line flags
Realtime operations in CsoundAV need special command-line flags that are not present in canonical Csound version. You don't have to use the flags of the Canonical, but the CsoundAV ones. Read carefully the Special Command Line Flags section, for details