What Is Csound?

Csound is a computer programming language designed specifically for audio synthesis and sound composition. It was initially developed by Barry Vercoe at MIT in 1984–85. The underlying code for Csound is written in the popular C programming language, hence the name—but you don’t have to know C in order to use Csound. (If you’re entirely new to the idea of computer programming, you should expect to learn some new concepts and processes.)

Vercoe’s work was based on the earlier Music-N audio programming languages developed by Max Mathews at Bell Labs, starting with Music-1 in 1957. As such, Csound is perhaps the oldest music programming language still in use. Today, the lead developer for Csound is John ffitch, who has recently retired from his position at the University of Bath in England. Many other developers from around the world actively contribute to Csound, expanding and refining its capabilities on an ongoing basis.

Until the early 1990s, general-purpose computers were too slow to generate complex audio in real time. For a few years prior to that, computers had been able to “stream” previously recorded audio files from their hard drives and send them to an output device (a digital-to-analog converter) so the audio could be listened to, but the mathematical processes required to synthesize new audio signals were too complex for computers’ CPUs to attempt them. Special hardware (such as the FM chip in the Yamaha DX7 synthesizer) was required for real-time digital sound synthesis.

For this reason, Csound began as a rendering program. It generated audio files and stored them on the hard drive. Many minutes might be needed to produce only a few seconds of sound. To hear the music you had created, you would play back the previously stored file. Today, thanks to massive increases in computer power, Csound is often used to generate sound, and also to process incoming audio streams, in real time. Messages sent to Csound over MIDI and OSC can be used for control of real-time performances.

However, Csound retains its original form as a text-based programming language, so understanding its origins is useful. As programming languages go, it’s fairly straightforward. Csound code is quite easy both to write and to read once you understand a few simple conventions. Nonetheless, in order to use it you’ll need to be willing to write (and debug) your own code.

Csound code consists of two discrete elements—an orchestra, which contains user-defined instruments, and a score, which is a list of events that “play” the instruments in the score. Details on how these elements are assembled and work together will be found throughout this book, as well as in The Canonical Csound Reference Manual; see the sections of the manual called “Syntax of the Orchestra” and “The Standard Numeric Score.”

Using this simple orchestra/score paradigm, you can both design your own sounds (as instruments) and compose music (in the form of a score). If you’re familiar with conventional DAW software, you can think of Csound as being roughly equivalent to a virtual rack of software instruments (the orchestra), coupled with a sequencer (the score). However, both of these components are capable of far more sophisticated operation than what you’ll find in a typical commercial DAW, even a very good one. Comparing a Csound score to a MIDI event list is like comparing a Lamborghini sports car to a Vespa motor scooter.

Lest anyone be misled, I should make it clear that the word “score” means something quite different in Csound from what orchestral musicians mean when they use the term. Csound is not compatible in any way with conventional music notation. Unless translated into MIDI data by a scanning and notation system such as Avid Sibelius, a notated score can’t be used as an input for Csound. Nor will Csound generate a musician-readable score as output.

Included in the Csound distribution are several non-real-time sound analysis tools, which can be used to analyze sampled (recorded) digital sound. The data generated by these tools can then be used to resynthesize the recorded sounds, with or without complex alterations. (See “Analysis and Resynthesis” in Chapter 7.)

For the most part, Csound is backward-compatible. Music written for the very earliest versions, such as Richard Boulanger’s “Trapped in Convert” (ported to Csound in 1986 and included in the Examples directory of CsoundQt) can still be compiled and played on the current version, because Csound’s older features are never removed (though some are deprecated).

Csound is open-source software. This means that if you know how to program using the C language, you can download the source code for Csound, modify it in whatever way you like, and compile your modified version. This is, in fact, how Csound evolves: An active community of developers makes changes, which are then uploaded to the Csound source code in the Source-Forge repository. At semi-regular intervals, the source code is compiled by Csound’s developer team, bundled with other components in installer programs, and made available to ordinary users. Most Csound users, especially if their operating system is Windows or Mac OS, use these pre-compiled binary versions rather than building (compiling) their own. A higher percentage of Csound users in the Linux community prefer to compile Csound directly from the source code rather than downloading a pre-compiled version.

Compiling Csound yourself from the source code is beyond the scope of this book, though Linux users will find a few tips in Chapter 2. If you want to try it, you’ll probably find yourself asking for help on the Csound email list. (See the “Resources” section at the end of this chapter to learn how to join this list.) One advantage of compiling the code yourself is that you’ll be able to take immediate advantage of any bug fixes that have been incorporated since the most recent official release version.

The current version of Csound at this writing is 5.13.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
52.15.129.90