ADVENIAT REGNUM TUUM (An Advent Meditation) for realtime Csound5 (2008) Arthur B. Hunkins Adveniat regnum tuum. Fiat voluntas tua, sicut in coelo, et in terra. The Lord's Prayer I admit a total disinterest in afterlife options . . . They distract me from what I understand to be the challenge of Jesus about the Kingdom of God . . . the will of God for this earth. On earth, as in heaven. John Dominic Crossan, A Long Way from Tipperary To the One whose coming manifested the Kingdom GENERAL ADVENIAT REGNUM TUUM is a meditative, solo performance piece for computer running Csound5. It exists in 3 versions - all indicated by "Advent" in their file name. The versions differ from one another largely in the number of performance controllers they require, which reflects the number of voices they implement. Advent8.csd comprises 8 voices controlled by 16 or 17 MIDI sliders/rotary pots (sliders are preferred). Advent16.csd allows between 9- 16 voices with 32-33 pots/sliders, while Advent32.csd presents 17-32 voices on 64-65 controllers. All versions can be performed in 2-, 4-, and 8-channel (circular) speaker configurations. Multichannel realizations simply add a "surround" dimension to their stereo counterparts. The quad and 8-channel versions require a *multi-channel* sound card or interface. The 8-speaker/channel placement is as follows: stereo pairs (first pair identified as 1 and 2) beginning on the front plane and progressing to the rear. Each version requires "banks" of 8 sequentially-numbered controllers plus a single additional controller (to regulate overall volume). A "COMPACT" option in each .csd eliminates the need for the extra controller, at the expense of reduced control of the highest pitch. Banks are specified by the number of their first controller; the additional controller is enumerated separately. A parallel set of standalone .exe's is also available - currently (3/08) for Windows only. They were generated by Rory Walsh's Lettuce frontend for Csound5 (http://www.ear.ie/Lettuce.htm). Available along with the .csd versions in a single, large Advent.zip download (which includes this file), their filenames begin with "L" and end with ".exe" instead of ".csd". (For platforms other than Windows, download Advent.zip and run only the .csd files.) Whereas Csound5 must be installed to use the Advent.zip package, another collection, AdventSA.zip, is intended for use *when Csound5 is not installed*. (AdventSA.zip lacks the .csd versions, but includes necessary Csound files.) Ease of use in setup and performance is the chief advantage of the standalone .exe's. See run-time "Instructions" windows for further details. Csound5 is a software sound synthesis program available for all major computer platforms. ADVENIAT REGNUM TUUM specifically requires Csound5.02 or above. Free downloads for various systems are found at: http://csound.sourceforge.net. ADVENIAT REGNUM TUUM does not lend itself to multi-speaker sound diffusion. Minimum duration is 5 minutes. More expansive versions (Advent16 and Advent32) should last longer than Advent8. (There is no specified maximum; the performance file can run for a total of 60 minutes.) GENERAL SETUP You will probably need to edit several flags near the beginning of your performance file. (Do this in any text editor; your .csd is a simple text file. In standalone .exe versions, this all is accomplished in the performance window: open CsOptions, edit the designated values, and observe the output under View Output.) You must insure that the values of -M0 (your MIDI input device #) and -odac0 (your audio output device #) match your system. Simply substitute a high number, such as -M99 and -odac99, for the zeros and run the file. The performance will immediately abort and display a list of valid device numbers on your system. Once you identify the appropriate numbers, go back and insert them in place of the zeros. This composition should work well with any audio driver type; latency is not an issue. If you are having a problem with stuttering or clicks, be sure to close as many programs running in the background as you can. As a last resort, you can try reducing the sample rate (note that not all soundcards and native ASIO drivers in Windows allow lower rates). It is important, due to an extended frequency range, to run this composition at the highest rate possible (hopefully 48000Hz). SPECIFIC SETUP AND PERFORMANCE Performance consists exclusively of manipulating MIDI pots/sliders. Sets of 8 pitches are controlled by two banks of 8 controllers: 8 "basic" controllers (CTRLxA) and 8 "enhanced" controllers (CTRLxB). While pitches are the same for the two banks, timbres are somewhat different: the "basic" sonorities are fairly active, while the "enhanced" are somewhat simpler. When combined, however, they are particularly rich. The user specifies the lowest (base) pitch, as well as a fraction representing how much higher each new frequency is than the one previous. The ratio relating all frequencies is the same; it can range from 1/24 to 7/8. Besides each pair of controllers per pitch, an additional controller regulates overall volume - except with the "compact" option. In this case, overall volume is controlled by the last pot/slider in the highest bank, and the top frequency is governed by a single controller. A combination of "basic" and "enhanced" sonorities, this controller is the last in the *basic* bank - or the highest "basic" note used. Two special controller configurations may be encountered occasionally. (These require adjustment to the defaults either in the performance file itself, or with standalone .exe's, similarly in the performance window.) 1) ALL CONTROLLERS USE THE SAME CHANNEL, BUT NOT #1: Locate the line toward the beginning of the performance file - "#define CHAN #1#" (channel 1 is the default). Change the channel number to the one you need (from 2-16) with a text editor. (This revision is active until you change it again, in .csd versions.) Note that the "#" characters around the channel number must remain. 2) Applies to Advent8 only: EACH CONTROL USES A UNIQUE CHANNEL, BUT WITH (channel volume) CONTROLLER #7: To enable this layout, define CHAN as #0#. All controllers will now be on consecutive channels, starting with channel 1. (In the standalone .exe, simply select a channel number of 0.) A number of other variables are also defined toward the beginning of the performance file (or in the performance window of a standalone .exe). SRATE equals SampleRATE, for which four options are listed - with the highest value (48000) both recommended and default. Select the highest rate at which you get click-free, uninterrupted sound. In standalone .exe's, SRATE is chosen in the CsOptions window. NCHNLS (default = 2) specifies a 2-, 4- or 8-channel/speaker realization. In standalone versions, this value is again selected in the CsOptions window. VOICES applies to Advent16 and 32 only. Not all available voices need be used (unused voices are always at the *top* of the range). The options for Advent16 = 9-16 voices (16 [all] is default); for Advent32 = 17-32 (with 32 the default). Thus the number of voices selectable for ADVENIAT REGNUM TUUM overall ranges from 8 to 32. The actual number selected depends both on available controllers and the performer's preference. COMPACT takes the value 0 (the default) or 1. "1" indicates the "compact" version described above (that does not require the extra controller). CTRLxA specifies the first controller of an 8-controller *basic* bank. (Defaults: CTRL1A = 0, 2A = 8, 3A = 32, 4A = 40.) It pairs with: CTRLxB which indicates the first controller of an 8-controller *enhanced* bank. The bank pairs contain identical pitches. (Defaults: CTRL1B = 16, CTRL2B = 24, CTRL3B = 48, CTRL4B = 56.) MASTCTRL is the separate CC for overall volume. It is not used in a "compact" version. Default is the next value higher than the highest bank member of the selected version. (This = 16, 32 or 64). FREQ represents the "base" pitch. The lowest allowable frequency is 400Hz. (In standalone .exe's, the choice ranges from 400-1000Hz.) FRAC equals the percentage of base frequency added to determine each next higher pitch. The lowest possible is 1/24, and the highest, 7/8 (in some versions, less). The denominator of the fraction must not exceed 24. BRIGHT regulates the brightness or relative strength of higher frequencies. Choices range from 0 (all pitches equal amplitude) to .5 (higher pitches increasingly stronger). In standalone .exe's, this same range is expressed as 0-10. Finally, AMPFAC is a multiplier factor for overall volume (1-10; default 1). Depending on several user settings, overall amplitude per channel can vary over about a 10 to 1 range in a given version (all controls at maximum). The fewer the voices (where number of voices can vary), the lower the brightness and smaller the "frequency fraction", the lower these amplitudes will be. Aim for an average channel max amplitude of 8000-12000 (or perhaps higher). Amplitudes are displayed in the Csound output window whenever Csound is stopped. Look at these numbers, and if they are significantly below the recommended range, increase AMPFAC. (Doing so is not required, but it can audibly lower the background noise level.) All values in standalone versions are set prior to starting Csound. Immediately Csound checks whether certain user settings are valid, and if not, issues USER ERROR messages and exits. Depending on the version, these messages may occur: "Your root frequency (FREQ) is below 400Hz." "Your highest frequency is above the maximum allowed." (The maximum is determined by sample rate, number of voices, FREQ and FRAC.) "Your value for FRAC is greater than .875 (7/8)." "Your value for BRIGHT is above .5." In standalone versions, these messages are only viewable in the View Output window. If you suspect an error, open this window - preferably before running Csound. You'll know something is wrong when you receive an "Inconsistencies in .csnd file" popup window or an ominous Windows abort message. (The latter will freeze Csound and require you to rerun the file.) Prior to running a performance file, be sure to turn all pots/sliders to zero. Only then turn up the 4 or more pots/sliders mentioned below to their initial levels. (The overall volume control, of course, begins at zero.) Maximum level should be set beforehand (in the sound system) to achieve moderate volume (mf - no louder) with all pots/sliders fully on. Performance follows the following general sequence of events (note that these instructions are quite "open"): Note first that the overall volume controller (often MASTCTRL) is only used for the opening and closing fade. It could also function as a total system level, but it is probably best for this to be handled externally and for the framing fades to comprise the full slider (or rotary pot) span. 1) The first segment uses only the set of *basic* pitches. At the initial fadein (slow to moderate speed), a minimum of 4 or up to one-half the total number of voices is present. The initial pitches are representative of the entire pitch range. Soon after the opening, all the voices have entered. Optionally, the piece may *begin* with all or most pitches present, at the same or different amplitudes - but not maximum. As the section progresses, individual pitch controls move toward full on. Duration: at least 2 minutes. 2) The midportion of the piece introduces the *enhanced* pitches alongside the basic pitches. The pairs mix and produce a richer sound. All voices and controllers continue to be used. During at least part of this section, most or all individual controls should be close to maximum. This portion lasts about as long as the first (at least 2 minutes). 3) Gradually the "basic" pitches (controllers) disappear, leaving only the "enhanced" sonorities. The final texture is either full, or gradually reduced to as many voices as opened the piece (or a greater number). (These voices need not be the *same* voices.) The performance ends with a slow general fadeout. This segment is somewhat shorter than the other two. (Minimum duration: 1 minute.) In general, voices may be at any level at any time; they are not just full on or off. Once the piece gets going, and through to (just before) the end, the texture is full and most pitches are sounding to some degree. Levels should be changing constantly - often more than one at a time. Though level changes are active, they are moderate, not drastic. Multiple volume changes are greatly facilitated by sliders (in contrast to rotary pots). In general, sliders are substantially more performer-friendly to this work. (Multiple slider-bank control surfaces could be daisy-chained to perform any of these versions.)