The Alternative Csound Reference Manual
Barry Vercoe
MIT Media Lab
Other Contributors
Edited by
John ffitch
Jean Piché
Peter Nix
Richard Boulanger
Rasmus Ekman
David Boothe
Kevin Conder
Copyright © 1986, 1992 Massachusetts Institute of Technology
Table of Contents
Preface
Preface to the Csound Manual
Copyright Notice
Acknowledgements
Why is this called the
Alternative
Csound Reference Manual?
What is the scope of the Alternative Csound Reference Manual?
Where is the documentation for the CsoundAV project?
I.
Overview
1.
Introduction
Where to Get Public Csound and the Csound Manual
How to Install Csound
The Csound Mailing List
2.
The Csound Command
Order of Precedence
Description
Command-line Flags
Unified File Format for Orchestras and Scores
Score File Preprocessing
3.
Syntax of the Orchestra
Directories and Files
Nomenclature
Orchestra Statement Types
Constants and Variables
Expressions
Orchestra Header Statements
Instrument Block Statements
Variable Initialization
4.
Instrument Control
Clock Control
Conditional Values
Duration Control Statements
Introduction to FLTK Widgets and GUI controllers
Instrument Invocation
Macros
Program Flow Control
Real-time Performance Control
Reinitialization
Sensing and Control
Sub-instrument Control
Time Reading
5.
Function Table Control
Table Queries
Read/Write Operations
Table Selection
6.
Mathematical Operations
Amplitude Converters
Arithmetic and Logic Operations
Mathematical Functions
Opcode Equivalents of Functions
Random Functions
Trigonometric Functions
7.
MIDI Support
Controller Input
Converters
Event Extenders
Generic Input and Output
Note-on/Note-off
MIDI Message Output
Real-time Messages
Slider Banks
8.
Pitch Converters
Functions
Tuning Opcodes
9.
Signal Generators
Additive Synthesis/Resynthesis
Basic Oscillators
Dynamic Spectrum Oscillators
FM Synthesis
Granular Synthesis
Linear and Exponential Generators
Linear Predictive Coding (LPC) Resynthesis
Models and Emulations
Phasors
Random (Noise) Generators
Sample Playback
Scanned Synthesis
Short-time Fourier Transform (STFT) Resynthesis
Table Access
Wave Terrain Synthesis
Waveguide Physical Modeling
10.
Signal Input and Output
File Input and Output
Input
Output
Printing and Display
Sound File Queries
11.
Signal Modifiers
Amplitude Modifiers
Convolution and Morphing
Delay
Envelope Modifiers
Panning and Spatialization
Reverberation
Sample Level Operators
Signal Limiters
Special Effects
Specialized Filters
Standard Filters
Waveguides
12.
Spectral Processing
Non-standard Spectral Processing
Tools for Real-time Spectral Processing
13.
Zak Patch System
14.
The Standard Numeric Score
Preprocessing of Standard Scores
Next-P and Previous-P Symbols
Ramping
Score Macros
Multiple File Score
Evaluation of Expressions
Score Statements
Sine/Cosine Generators
Line/Exponential Segment Generators
File Access GEN Routines
Numeric Value Access GEN Routines
Window Function GEN Routines
Random Function GEN Routines
Waveshaping GEN Routines
Amplitude Scaling GEN Routines
Mixing GEN Routines
II.
Reference
15.
Orchestra Opcodes and Operators
!=
-- Determines if one value is not equal to another.
#define
-- Defines a macro.
#include
-- Includes an external file for processing.
#undef
-- Un-defines a macro.
$NAME
-- Calls a defined macro.
%
-- Modulus operator.
&&
-- Logical AND operator.
>
-- Determines if one value is greater than another.
>=
-- Determines if one value is greater than or equal to another.
<
-- Determines if one value is less than another.
<=
-- Determines if one value is less than or equal to another.
*
-- Multiplication operator.
+
-- Addition operator
-
-- Subtraction operator.
/
-- Division operator.
=
-- Performs a simple assignment.
==
-- Compares two values for equality.
ˆ
--
"Power of"
operator.
||
-- Logical OR operator.
0dbfs
-- Sets the value of 0 decibels using full scale amplitude.
a
-- Converts a k-rate parameter to an a-rate value with interpolation.
abetarand
-- Deprecated.
abexprnd
-- Deprecated.
abs
-- Returns an absolute value.
acauchy
-- Deprecated.
active
-- Returns the number of active instances of an instrument.
adsr
-- Calculates the classical ADSR envelope using linear segments.
adsyn
-- Output is an additive set of individually controlled sinusoids, using an oscillator bank.
adsynt
-- Performs additive synthesis with an arbitrary number of partials, not necessarily harmonic.
aexprand
-- Deprecated.
aftouch
-- Get the current after-touch value for this channel.
agauss
-- Deprecated.
agogobel
-- Deprecated.
alinrand
-- Deprecated.
alpass
-- Reverberates an input signal with a flat frequency response.
ampdb
-- Returns the amplitude equivalent of the decibel value x.
ampdbfs
-- Returns the amplitude equivalent of the decibel value x, which is relative to full scale amplitude.
ampmidi
-- Get the velocity of the current MIDI event.
apcauchy
-- Deprecated.
apoisson
-- Deprecated.
apow
-- Deprecated.
areson
-- A notch filter whose transfer functions are the complements of the reson opcode.
aresonk
-- A notch filter whose transfer functions are the complements of the reson opcode.
atone
-- A notch filter whose transfer functions are the complements of the tone opcode.
atonek
-- A notch filter whose transfer functions are the complements of the tone opcode.
atonex
-- Emulates a stack of filters using the atone opcode.
atrirand
-- Deprecated.
aunirand
-- Deprecated.
aweibull
-- Deprecated.
babo
-- A physical model reverberator.
balance
-- Adjust one audio signal according to the values of another.
bamboo
-- Semi-physical model of a bamboo sound.
bbcutm
-- Generates breakbeat-style cut-ups of a mono audio stream.
bbcuts
-- Generates breakbeat-style cut-ups of a stereo audio stream.
betarand
-- Beta distribution random number generator (positive values only).
bexprnd
-- Exponential distribution random number generator.
biquad
-- A sweepable general purpose biquadratic digital filter.
biquada
-- A sweepable general purpose biquadratic digital filter with a-rate parameters.
birnd
-- Returns a random number in a bi-polar range.
bqrez
-- A second-order multi-mode filter.
butbp
-- Same as the butterbp opcode.
butbr
-- Same as the butterbr opcode.
buthp
-- Same as the butterhp opcode.
butlp
-- Same as the butterlp opcode.
butterbp
-- A band-pass Butterworth filter.
butterbr
-- A band-reject Butterworth filter.
butterhp
-- A high-pass Butterworth filter.
butterlp
-- A low-pass Butterworth filter.
button
-- Sense on-screen controls.
buzz
-- Output is a set of harmonically related sine partials.
cabasa
-- Semi-physical model of a cabasa sound.
cauchy
-- Cauchy distribution random number generator.
cent
-- Calculates a factor to raise/lower a frequency by a given amount of cents.
cggoto
-- Conditionally transfer control on every pass.
chanctrl
-- Get the current value of a MIDI channel controller.
checkbox
-- Sense on-screen controls.
cigoto
-- Conditionally transfer control during the i-time pass.
ckgoto
-- Conditionally transfer control during the p-time passes.
clear
-- Zeroes a list of audio signals.
clfilt
-- Implements low-pass and high-pass filters of different styles.
clip
-- Clips a signal to a predefined limit.
clock
-- Deprecated.
clockoff
-- Stops one of a number of internal clocks.
clockon
-- Starts one of a number of internal clocks.
cngoto
-- Transfers control on every pass when a condition is not true.
comb
-- Reverberates an input signal with a
"colored"
frequency response.
control
-- Configurable slider controls for realtime user input.
convle
-- Same as the convolve opcode.
convolve
-- Convolves a signal and an impulse response.
cos
-- Performs a cosine function.
cosh
-- Performs a hyperbolic cosine function.
cosinv
-- Performs a arccosine function.
cps2pch
-- Converts a pitch-class value into cycles-per-second for equal divisions of the octave.
cpsmidi
-- Get the note number of the current MIDI event, expressed in cycles-per-second.
cpsmidib
-- Get the note number of the current MIDI event and modify it by the current pitch-bend value, express it in cycles-per-second.
cpsoct
-- Converts an octave-point-decimal value to cycles-per-second.
cpspch
-- Converts a pitch-class value to cycles-per-second.
cpstmid
-- Get a MIDI note number (allows customized micro-tuning scales).
cpstun
-- Returns micro-tuning values at k-rate.
cpstuni
-- Returns micro-tuning values at init-rate.
cpsxpch
-- Converts a pitch-class value into cycles-per-second (Hz) for equal divisions of any interval.
cpuprc
-- Control allocation of cpu resources on a per-instrument basis, to optimize realtime output.
cross2
-- Cross synthesis using FFT's.
crunch
-- Semi-physical model of a crunch sound.
ctrl14
-- Allows a floating-point 14-bit MIDI signal scaled with a minimum and a maximum range.
ctrl21
-- Allows a floating-point 21-bit MIDI signal scaled with a minimum and a maximum range.
ctrl7
-- Allows a floating-point 7-bit MIDI signal scaled with a minimum and a maximum range.
ctrlinit
-- Sets the initial values for a set of MIDI controllers.
cuserrnd
-- Continuous USER-defined-distribution RaNDom generator.
dam
-- A dynamic compressor/expander.
db
-- Returns the amplitude equivalent for a given decibel amount.
dbamp
-- Returns the decibel equivalent of the raw amplitude x.
dbfsamp
-- Returns the decibel equivalent of the raw amplitude x, relative to full scale amplitude.
dcblock
-- A DC blocking filter.
dconv
-- A direct convolution opcode.
delay
-- Delays an input signal by some time interval.
delay1
-- Delays an input signal by one sample.
delayr
-- Reads from an automatically established digital delay line.
delayw
-- Writes the audio signal to a digital delay line.
deltap
-- Taps a delay line at variable offset times.
deltap3
-- Taps a delay line at variable offset times, uses cubic interpolation.
deltapi
-- Taps a delay line at variable offset times, uses interpolation.
deltapn
-- Taps a delay line at variable offset times.
deltapx
-- Read to or write from a delay line with interpolation.
deltapxw
-- Mixes the input signal to a delay line.
diff
-- Modify a signal by differentiation.
diskin
-- Reads audio data from an external device or stream and can alter its pitch.
dispfft
-- Displays the Fourier Transform of an audio or control signal.
display
-- Displays the audio or control signals as an amplitude vs. time graph.
distort1
-- Modified hyperbolic tangent distortion.
divz
-- Safely divides two numbers.
downsamp
-- Modify a signal by down-sampling.
dripwater
-- Semi-physical model of a water drop.
dumpk
-- Periodically writes an orchestra control-signal value to an external file.
dumpk2
-- Periodically writes two orchestra control-signal values to an external file.
dumpk3
-- Periodically writes three orchestra control-signal values to an external file.
dumpk4
-- Periodically writes four orchestra control-signal values to an external file.
duserrnd
-- Discrete USER-defined-distribution RaNDom generator.
else
-- Executes a block of code when an "if...then" condition is false.
elseif
-- Defines another "if...then" condition when a "if...then" condition is false.
endif
-- Closes a block of code that begins with an "if...then" statement.
endin
-- Ends the current instrument block.
endop
-- Marks the end of an user-defined opcode block.
envlpx
-- Applies an envelope consisting of 3 segments.
envlpxr
-- The envlpx opcode with a final release segment.
event
-- Generates a score event from an instrument.
exp
-- Returns e raised to the x-th power.
expon
-- Trace an exponential curve between specified points.
exprand
-- Exponential distribution random number generator (positive values only).
expseg
-- Trace a series of exponential segments between specified points.
expsega
-- An exponential segment generator operating at a-rate.
expsegr
-- Trace a series of exponential segments between specified points including a release segment.
filelen
-- Returns the length of a sound file.
filenchnls
-- Returns the number of channels in a sound file.
filepeak
-- Returns the peak absolute value of a sound file.
filesr
-- Returns the sample rate of a sound file.
filter2
-- Performs filtering using a transposed form-II digital filter lattice with no time-varying control.
fin
-- Read signals from a file at a-rate.
fini
-- Read signals from a file at i-rate.
fink
-- Read signals from a file at k-rate.
fiopen
-- Opens a file in a specific mode.
flanger
-- A user controlled flanger.
flashtxt
-- Allows text to be displayed from instruments like sliders
FLbox
-- A FLTK widget that displays text inside of a box.
FLbutBank
-- A FLTK widget opcode that creates a bank of buttons.
FLbutton
-- A FLTK widget opcode that creates a button.
FLcolor
-- A FLTK opcode that sets the primary colors.
FLcolor2
-- A FLTK opcode that sets the secondary (selection) color.
FLcount
-- A FLTK widget opcode that creates a counter.
FLgetsnap
-- Retrieves a previously stored FLTK snapshot.
FLgroup
-- A FLTK container opcode that groups child widgets.
FLgroupEnd
-- Marks the end of a group of FLTK child widgets.
FLhide
-- Hides the target FLTK widget.
FLjoy
-- A FLTK opcode that acts like a joystick.
FLkeyb
-- Experimental, no documentation exists. May be deprecated in future versions.
FLknob
-- A FLTK widget opcode that creates a knob.
FLlabel
-- A FLTK opcode that modifies the appearance of a text label.
FLloadsnap
-- Loads all snapshots into the memory bank of the current orchestra.
FLpack
-- Provides the functionality of compressing and aligning FLTK widgets.
FLpackEnd
-- Marks the end of a group of compressed or aligned FLTK widgets.
FLpanel
-- Creates a window that contains FLTK widgets.
FLpanelEnd
-- Marks the end of a group of FLTK widgets contained inside of a window (panel).
FLprintk
-- A FLTK opcode that prints a k-rate value at specified intervals.
FLprintk2
-- A FLTK opcode that prints a new value every time a control-rate variable changes.
FLroller
-- A FLTK widget that creates a transversal knob.
FLrun
-- Starts the FLTK widget thread.
FLsavesnap
-- Saves all snapshots currently created into a file.
FLscroll
-- A FLTK opcode that adds scroll bars to an area.
FLscrollEnd
-- A FLTK opcode that marks the end of an area with scrollbars.
FLsetAlign
-- Sets the text alignment of a label of a FLTK widget.
FLsetBox
-- Sets the appearance of a box surrounding a FLTK widget.
FLsetColor
-- Sets the primary color of a FLTK widget.
FLsetColor2
-- Sets the secondary (or selection) color of a FLTK widget.
FLsetFont
-- Sets the font type of a FLTK widget.
FLsetPosition
-- Sets the position of a FLTK widget.
FLsetSize
-- Resizes a FLTK widget.
FLsetsnap
-- Stores the current status of all FLTK valuators into a snapshot location.
FLsetText
-- Sets the label of a FLTK widget.
FLsetTextColor
-- Sets the color of the text label of a FLTK widget.
FLsetTextSize
-- Sets the size of the text label of a FLTK widget.
FLsetTextType
-- Sets some font attributes of the text label of a FLTK widget.
FLsetVal_i
-- Sets the value of a FLTK valuator to a number provided by the user.
FLsetVal
-- Sets the value of a FLTK valuator at control-rate.
FLshow
-- Restores the visibility of a previously hidden FLTK widget.
FLslidBnk
-- A FLTK widget containing a bank of horizontal sliders.
FLslider
-- Puts a slider into the corresponding FLTK container.
FLtabs
-- Creates a tabbed FLTK interface.
FLtabsEnd
-- Marks the end of a tabbed FLTK interface.
FLtext
-- A FLTK widget opcode that creates a textbox.
FLupdate
-- Same as the FLrun opcode.
FLvalue
-- Shows the current value of a FLTK valuator.
fmb3
-- Uses FM synthesis to create a Hammond B3 organ sound.
fmbell
-- Uses FM synthesis to create a tublar bell sound.
fmmetal
-- Uses FM synthesis to create a
"Heavy Metal"
sound.
fmpercfl
-- Uses FM synthesis to create a percussive flute sound.
fmrhode
-- Uses FM synthesis to create a Fender Rhodes electric piano sound.
fmvoice
-- FM Singing Voice Synthesis
fmwurlie
-- Uses FM synthesis to create a Wurlitzer electric piano sound.
fof
-- Produces sinusoid bursts useful for formant and granular synthesis.
fof2
-- Produces sinusoid bursts including k-rate incremental indexing with each successive burst.
fog
-- Audio output is a succession of grains derived from data in a stored function table
fold
-- Adds artificial foldover to an audio signal.
follow
-- Envelope follower unit generator.
follow2
-- Another controllable envelope extractor.
foscil
-- A basic frequency modulated oscillator.
foscili
-- Basic frequency modulated oscillator with linear interpolation.
fout
-- Outputs a-rate signals to an arbitrary number of channels.
fouti
-- Outputs i-rate signals of an arbitrary number of channels to a specified file.
foutir
-- Outputs i-rate signals from an arbitrary number of channels to a specified file.
foutk
-- Outputs k-rate signals of an arbitrary number of channels to a specified file.
fprintks
-- Similar to printks but prints to a file.
fprints
-- Similar to prints but prints to a file.
frac
-- Returns the fractional part of a decimal number.
ftchnls
-- Returns the number of channels in a stored function table.
ftgen
-- Generate a score function table from within the orchestra.
ftlen
-- Returns the size of a stored function table.
ftload
-- Load a set of previously-allocated tables from a file.
ftloadk
-- Load a set of previously-allocated tables from a file.
ftlptim
-- Returns the loop segment start-time of a stored function table number.
ftmorf
-- Morphs between multiple ftables as specified in a list.
ftsave
-- Save a set of previously-allocated tables to a file.
ftsavek
-- Save a set of previously-allocated tables to a file.
ftsr
-- Returns the sampling-rate of a stored function table.
gain
-- Adjusts the amplitude audio signal according to a root-mean-square value.
gauss
-- Gaussian distribution random number generator.
gbuzz
-- Output is a set of harmonically related cosine partials.
gogobel
-- Audio output is a tone related to the striking of a cow bell or similar.
goto
-- Transfer control on every pass.
grain
-- Generates granular synthesis textures.
grain2
-- Easy-to-use granular synthesis texture generator.
grain3
-- Generate granular synthesis textures with more user control.
granule
-- A more complex granular synthesis texture generator.
guiro
-- Semi-physical model of a guiro sound.
harmon
-- Analyze an audio input and generate harmonizing voices in synchrony.
hilbert
-- A Hilbert transformer.
hrtfer
-- Creates 3D audio for two speakers.
hsboscil
-- An oscillator which takes tonality and brightness as arguments.
i
-- Returns an init-type equivalent of a k-rate argument.
ibetarand
-- Deprecated.
ibexprnd
-- Deprecated.
icauchy
-- Deprecated.
ictrl14
-- Deprecated.
ictrl21
-- Deprecated.
ictrl7
-- Deprecated.
iexprand
-- Deprecated.
if
-- Branches conditionally at initialization or during performance time.
igauss
-- Deprecated.
igoto
-- Transfer control during the i-time pass.
ihold
-- Creates a held note.
ilinrand
-- Deprecated.
imidic14
-- Deprecated.
imidic21
-- Deprecated.
imidic7
-- Deprecated.
in
-- Reads mono audio data from an external device or stream.
in32
-- Reads a 32-channel audio signal from an external device or stream.
inch
-- Reads from a numbered channel in an external audio signal or stream.
inh
-- Reads six-channel audio data from an external device or stream.
init
-- Puts the value of the i-time expression into a k- or a-rate variable.
initc14
-- Initializes the controllers used to create a 14-bit MIDI value.
initc21
-- Initializes the controllers used to create a 21-bit MIDI value.
initc7
-- Initializes the controller used to create a 7-bit MIDI value.
ink
-- Deprecated.
ino
-- Reads eight-channel audio data from an external device or stream.
inq
-- Reads quad audio data from an external device or stream.
ins
-- Reads stereo audio data from an external device or stream.
instimek
-- Deprecated.
instimes
-- Deprecated.
instr
-- Starts an instrument block.
int
-- Extracts an integer from a decimal number.
integ
-- Modify a signal by integration.
interp
-- Converts a control signal to an audio signal using linear interpolation.
invalue
-- Reads a k-rate signal from a user-defined channel.
inx
-- Reads a 16-channel audio signal from an external device or stream.
inz
-- Reads multi-channel audio samples into a ZAK array from an external device or stream.
ioff
-- Deprecated.
ion
-- Deprecated.
iondur
-- Deprecated.
iondur2
-- Deprecated.
ioutat
-- Deprecated.
ioutc
-- Deprecated.
ioutc14
-- Deprecated.
ioutpat
-- Deprecated.
ioutpb
-- Deprecated.
ioutpc
-- Deprecated.
ipcauchy
-- Deprecated.
ipoisson
-- Deprecated.
ipow
-- Deprecated.
is16b14
-- Deprecated.
is32b14
-- Deprecated.
islider16
-- Deprecated.
islider32
-- Deprecated.
islider64
-- Deprecated.
islider8
-- Deprecated.
itablecopy
-- Deprecated.
itablegpw
-- Deprecated.
itablemix
-- Deprecated.
itablew
-- Deprecated.
itrirand
-- Deprecated.
iunirand
-- Deprecated.
iweibull
-- Deprecated.
jitter
-- Generates a segmented line whose segments are randomly generated.
jitter2
-- Generates a segmented line with user-controllable random segments.
jspline
-- A jitter-spline generator.
kbetarand
-- Deprecated.
kbexprnd
-- Deprecated.
kcauchy
-- Deprecated.
kdump
-- Deprecated.
kdump2
-- Deprecated.
kdump3
-- Deprecated.
kdump4
-- Deprecated.
kexprand
-- Deprecated.
kfilter2
-- Deprecated.
kgauss
-- Deprecated.
kgoto
-- Transfer control during the p-time passes.
klinrand
-- Deprecated.
kon
-- Deprecated.
koutat
-- Deprecated.
koutc
-- Deprecated.
koutc14
-- Deprecated.
koutpat
-- Deprecated.
koutpb
-- Deprecated.
koutpc
-- Deprecated.
kpcauchy
-- Deprecated.
kpoisson
-- Deprecated.
kpow
-- Deprecated.
kr
-- Sets the control rate.
kread
-- Deprecated.
kread2
-- Deprecated.
kread3
-- Deprecated.
kread4
-- Deprecated.
ksmps
-- Sets the number of samples in a control period.
ktableseg
-- Same as the tableseg opcode.
ktrirand
-- Deprecated.
kunirand
-- Deprecated.
kweibull
-- Deprecated.
lfo
-- A low frequency oscillator of various shapes.
limit
-- Sets the lower and upper limits of the value it processes.
line
-- Trace a straight line between specified points.
linen
-- Applies a straight line rise and decay pattern to an input amp signal.
linenr
-- The linen opcode extended with a final release segment.
lineto
-- Generate glissandos starting from a control signal.
linrand
-- Linear distribution random number generator (positive values only).
linseg
-- Trace a series of line segments between specified points.
linsegr
-- Trace a series of line segments between specified points including a release segment.
locsend
-- Distributes the audio signals of a previous
locsig
opcode.
locsig
-- Takes and input signal and distributes between 2 or 4 channels.
log
-- Returns a natural log.
log10
-- Returns a base 10 log.
logbtwo
-- Performs a logarithmic base two calculation.
loopseg
-- Generate control signal consisting of linear segments delimited by two or more specified points.
lorenz
-- Implements the Lorenz system of equations.
loscil
-- Read sampled sound from a table.
loscil3
-- Read sampled sound from a table using cubic interpolation.
lowpass2
-- A resonant lowpass filter.
lowres
-- Another resonant lowpass filter.
lowresx
-- Simulates layers of serially connected resonant lowpass filters.
lpf18
-- A 3-pole sweepable resonant lowpass filter.
lpfreson
-- Modifies the spectrum of an audio signal with time-varying filter coefficients from a control file and frequncy ratio.
lphasor
-- Generates a table index for sample playback
lpinterp
-- Computes a new set of poles from the interpolation between two analysis.
lposcil
-- Read sampled sound from a table with optional looping and high precision.
lposcil3
-- Read sampled sound from a table with high precision and cubic interpolation.
lpread
-- Reads a control file of time-ordered information frames.
lpreson
-- Modifies the spectrum of an audio signal with time-varying filter coefficients from a control file.
lpshold
-- Generate control signal consisting of held segments.
lpslot
-- Selects the slot to be use by further lp opcodes.
mac
-- Multiplies and accumulates a- and k-rate signals.
maca
-- Multiply and accumulate a-rate signals only.
madsr
-- Calculates the classical ADSR envelope using the linsegr mechanism.
mandol
-- An emulation of a mandolin.
marimba
-- Physical model related to the striking of a wooden block.
massign
-- Assigns a MIDI channel number to a Csound instrument.
maxalloc
-- Limits the number of allocations of an instrument.
mclock
-- Sends a MIDI CLOCK message.
mdelay
-- A MIDI delay opcode.
midic14
-- Allows a floating-point 14-bit MIDI signal scaled with a minimum and a maximum range.
midic21
-- Allows a floating-point 21-bit MIDI signal scaled with a minimum and a maximum range.
midic7
-- Allows a floating-point 7-bit MIDI signal scaled with a minimum and a maximum range.
midichannelaftertouch
-- Gets a MIDI channel's aftertouch value.
midichn
-- Returns the MIDI channel number from which the note was activated.
midicontrolchange
-- Gets a MIDI control change value.
midictrl
-- Get the current value (0-127) of a specified MIDI controller.
mididefault
-- Changes values, depending on MIDI activation.
midiin
-- Returns a generic MIDI message received by the MIDI IN port.
midinoteoff
-- Gets a MIDI noteoff value.
midinoteoncps
-- Gets a MIDI note number as a cycles-per-second frequency.
midinoteonkey
-- Gets a MIDI note number value.
midinoteonoct
-- Gets a MIDI note number value as octave-point-decimal value.
midinoteonpch
-- Gets a MIDI note number as a pitch-class value.
midion
-- Plays MIDI notes.
midion2
-- Sends noteon and noteoff messages to the MIDI OUT port.
midiout
-- Sends a generic MIDI message to the MIDI OUT port.
midipitchbend
-- Gets a MIDI pitchbend value.
midipolyaftertouch
-- Gets a MIDI polyphonic aftertouch value.
midiprogramchange
-- Gets a MIDI program change value.
mirror
-- Reflects the signal that exceeds the low and high thresholds.
moog
-- An emulation of a mini-Moog synthesizer.
moogvcf
-- A digital emulation of the Moog diode ladder filter configuration.
moscil
-- Sends a stream of the MIDI notes.
mpulse
-- Generates a set of impulses.
mrtmsg
-- Send system real-time messages to the MIDI OUT port.
multitap
-- Multitap delay line implementation.
mute
-- Mutes/unmutes new instances of a given instrument.
mxadsr
-- Calculates the classical ADSR envelope using the expsegr mechanism.
nchnls
-- Sets the number of channels of audio output.
nestedap
-- Three different nested all-pass filters.
nlfilt
-- A filter with a non-linear effect.
noise
-- A white noise generator with an IIR lowpass filter.
noteoff
-- Send a noteoff message to the MIDI OUT port.
noteon
-- Send a noteon message to the MIDI OUT port.
noteondur
-- Sends a noteon and a noteoff MIDI message both with the same channel, number and velocity.
noteondur2
-- Sends a noteon and a noteoff MIDI message both with the same channel, number and velocity.
notnum
-- Get a note number from a MIDI event.
nreverb
-- A reverberator consisting of 6 parallel comb-lowpass filters.
nrpn
-- Sends a Non-Registered Parameter Number to the MIDI OUT port.
nsamp
-- Returns the number of samples loaded into a stored function table number.
nstrnum
-- Returns the number of a named instrument.
ntrpol
-- Calculates the weighted mean value of two input signals.
octave
-- Calculates a factor to raise/lower a frequency by a given amount of octaves.
octcps
-- Converts a cycles-per-second value to octave-point-decimal.
octmidi
-- Get the note number, in octave-point-decimal units, of the current MIDI event.
octmidib
-- Get the note number of the current MIDI event and modify it by the current pitch-bend value, express it in octave-point-decimal.
octpch
-- Converts a pitch-class value to octave-point-decimal.
opcode
-- Defines the start of user-defined opcode block.
oscbnk
-- Mixes the output of any number of oscillators.
oscil
-- A simple oscillator.
oscil1
-- Accesses table values by incremental sampling.
oscil1i
-- Accesses table values by incremental sampling with linear interpolation.
oscil3
-- A simple oscillator with cubic interpolation.
oscili
-- A simple oscillator with linear interpolation.
oscilikt
-- A linearly interpolated oscillator that allows changing the table number at k-rate.
osciliktp
-- A linearly interpolated oscillator that allows allows phase modulation.
oscilikts
-- A linearly interpolated oscillator with sync status that allows changing the table number at k-rate.
osciln
-- Accesses table values at a user-defined frequency.
oscils
-- A simple, fast sine oscillator
oscilx
-- Same as the osciln opcode.
out
-- Writes mono audio data to an external device or stream.
out32
-- Writes 32-channel audio data to an external device or stream.
outc
-- Writes audio data with an arbitrary number of channels to an external device or stream.
outch
-- Writes multi-channel audio data, with user-controllable channels, to an external device or stream.
outh
-- Writes 6-channel audio data to an external device or stream.
outiat
-- Sends MIDI aftertouch messages at i-rate.
outic
-- Sends MIDI controller output at i-rate.
outic14
-- Sends 14-bit MIDI controller output at i-rate.
outipat
-- Sends polyphonic MIDI aftertouch messages at i-rate.
outipb
-- Sends MIDI pitch-bend messages at i-rate.
outipc
-- Sends MIDI program change messages at i-rate
outk
-- Deprecated.
outkat
-- Sends MIDI aftertouch messages at k-rate.
outkc
-- Sends MIDI controller messages at k-rate.
outkc14
-- Sends 14-bit MIDI controller output at k-rate.
outkpat
-- Sends polyphonic MIDI aftertouch messages at k-rate.
outkpb
-- Sends MIDI pitch-bend messages at k-rate.
outkpc
-- Sends MIDI program change messages at k-rate.
outo
-- Writes 8-channel audio data to an external device or stream.
outq
-- Writes 4-channel audio data to an external device or stream.
outq1
-- Writes samples to quad channel 1 of an external device or stream.
outq2
-- Writes samples to quad channel 2 of an external device or stream.
outq3
-- Writes samples to quad channel 3 of an external device or stream.
outq4
-- Writes samples to quad channel 4 of an external device or stream.
outs
-- Writes stereo audio data to an external device or stream.
outs1
-- Writes samples to stereo channel 1 of an external device or stream.
outs2
-- Writes samples to stereo channel 2 of an external device or stream.
outvalue
-- Sends a k-rate signal to a user-defined channel.
outx
-- Writes 16-channel audio data to an external device or stream.
outz
-- Writes multi-channel audio data from a ZAK array to an external device or stream.
p
-- Show the value in a given p-field.
pan
-- Distribute an audio signal amongst four channels.
pareq
-- Implementation of Zoelzer's parametric equalizer filters.
pcauchy
-- Cauchy distribution random number generator (positive values only).
pchbend
-- Get the current pitch-bend value for this channel.
pchmidi
-- Get the note number of the current MIDI event, expressed in pitch-class units.
pchmidib
-- Get the note number of the current MIDI event and modify it by the current pitch-bend value, express it in pitch-class units.
pchoct
-- Converts an octave-point-decimal value to pitch-class.
peak
-- Maintains the output equal to the highest absolute value received.
peakk
-- Deprecated.
pgmassign
-- Assigns an instrument number to a specified MIDI program.
phaser1
-- First-order allpass filters arranged in a series.
phaser2
-- Second-order allpass filters arranged in a series.
phasor
-- Produce a normalized moving phase value.
phasorbnk
-- Produce an arbitrary number of normalized moving phase values.
pinkish
-- Generates approximate pink noise.
pitch
-- Tracks the pitch of a signal.
pitchamdf
-- Follows the pitch of a signal based on the AMDF method.
planet
-- Simulates a planet orbiting in a binary star system.
pluck
-- Produces a naturally decaying plucked string or drum sound.
poisson
-- Poisson distribution random number generator (positive values only).
polyaft
-- Returns the polyphonic after-touch pressure of the selected note number.
port
-- Applies portamento to a step-valued control signal.
portk
-- Applies portamento to a step-valued control signal.
poscil
-- High precision oscillator.
poscil3
-- High precision oscillator with cubic interpolation.
pow
-- Computes one argument to the power of another argument.
powoftwo
-- Performs a power-of-two calculation.
prealloc
-- Creates space for instruments but does not run them.
print
-- Displays the values init, control, or audio signals.
printk
-- Prints one k-rate value at specified intervals.
printk2
-- Prints a new value every time a control variable changes.
printks
-- Prints at k-rate using a printf() style syntax.
prints
-- Prints at init-time using a printf() style syntax.
product
-- Multiplies any number of a-rate signals.
pset
-- Defines and initializes numeric arrays at orchestra load time.
pvadd
-- Reads from a
pvoc
file and uses the data to perform additive synthesis.
pvbufread
-- Reads from a phase vocoder analysis file and makes the retrieved data available.
pvcross
-- Applies the amplitudes from one phase vocoder analysis file to the data from a second file.
pvinterp
-- Interpolates between the amplitudes and frequencies of two phase vocoder analysis files.
pvoc
-- Implements signal reconstruction using an fft-based phase vocoder.
pvread
-- Reads from a phase vocoder analysis file and returns the frequency and amplitude from a single analysis channel or bin.
pvsadsyn
-- Resynthesize using a fast oscillator-bank.
pvsanal
-- Generate an fsig from a mono audio source ain, using phase vocoder overlap-add analysis.
pvscross
-- Performs cross-synthesis between two source fsigs.
pvsfread
-- Read a selected channel from a PVOC-EX analysis file.
pvsftr
-- Reads amplitude and/or frequency data from function tables.
pvsftw
-- Writes amplitude and/or frequency data to function tables.
pvsinfo
-- Get information from a PVOC-EX formatted source.
pvsmaska
-- Modify amplitudes using a function table, with dynamic scaling.
pvsynth
-- Resynthesise using a FFT overlap-add.
rand
-- Generates a controlled random number series.
randh
-- Generates random numbers and holds them for a period of time.
randi
-- Generates a controlled random number series with interpolation between each new number.
random
-- Generates is a controlled pseudo-random number series between min and max values.
randomh
-- Generates random numbers with a user-defined limit and holds them for a period of time.
randomi
-- Generates a user-controlled random number series with interpolation between each new number.
readclock
-- Reads the value of an internal clock.
readk
-- Periodically reads an orchestra control-signal value from an external file.
readk2
-- Periodically reads two orchestra control-signal values from an external file.
readk3
-- Periodically reads three orchestra control-signal values from an external file.
readk4
-- Periodically reads four orchestra control-signal values from an external file.
reinit
-- Suspends a performance while a special initialization pass is executed.
release
-- Indicates whether a note is in its
"release"
stage.
repluck
-- Physical model of the plucked string.
reson
-- A second-order resonant filter.
resonk
-- A second-order resonant filter.
resonr
-- A bandpass filter with variable frequency response.
resonx
-- Emulates a stack of filters using the reson opcode.
resony
-- A bank of second-order bandpass filters, connected in parallel.
resonz
-- A bandpass filter with variable frequency response.
reverb
-- Reverberates an input signal with a
"natural room"
frequency response.
reverb2
-- Same as the nreverb opcode.
rezzy
-- A resonant low-pass filter.
rigoto
-- Transfers control during a reinit pass.
rireturn
-- Terminates a reinit pass.
rms
-- Determines the root-mean-square amplitude of an audio signal.
rnd
-- Returns a random number in a unipolar range.
rnd31
-- 31-bit bipolar random opcodes with controllable distribution.
rspline
-- Generate random spline curves.
rtclock
-- Read the real time clock from the operating system.
s16b14
-- Creates a bank of 16 different 14-bit MIDI control message numbers.
s32b14
-- Creates a bank of 32 different 14-bit MIDI control message numbers.
samphold
-- Performs a sample-and-hold operation on its input.
sandpaper
-- Semi-physical model of a sandpaper sound.
scanhammer
-- Copies from one table to another with a gain control.
scans
-- Generate audio output using scanned synthesis.
scantable
-- A simpler scanned synthesis implementation.
scanu
-- Compute the waveform and the wavetable for use in scanned synthesis.
schedkwhen
-- Adds a new score event generated by a k-rate trigger.
schedkwhennamed
-- Similar to schedkwhen but uses a named instrument at init-time.
schedule
-- Adds a new score event.
schedwhen
-- Adds a new score event.
seed
-- Sets the global seed value.
sekere
-- Semi-physical model of a sekere sound.
semitone
-- Calculates a factor to raise/lower a frequency by a given amount of semitones.
sense
-- Same as the sensekey opcode.
sensekey
-- Returns the ASCII code of a key that has been pressed.
seqtime
-- Generates a trigger signal according to the values stored in a table.
setctrl
-- Configurable slider controls for realtime user input.
setksmps
-- Sets the local ksmps value in a user-defined opcode block.
sfilist
-- Prints a list of all instruments of a previously loaded SoundFont2 (SF2) file.
sfinstr
-- Plays a SoundFont2 (SF2) sample instrument, generating a stereo sound.
sfinstr3
-- Plays a SoundFont2 (SF2) sample instrument, generating a stereo sound with cubic interpolation.
sfinstr3m
-- Plays a SoundFont2 (SF2) sample instrument, generating a mono sound with cubic interpolation.
sfinstrm
-- Plays a SoundFont2 (SF2) sample instrument, generating a mono sound.
sfload
-- Loads an entire SoundFont2 (SF2) sample file into memory.
sfpassign
-- Assigns all presets of a SoundFont2 (SF2) sample file to a sequence of progressive index numbers.
sfplay
-- Plays a SoundFont2 (SF2) sample preset, generating a stereo sound.
sfplay3
-- Plays a SoundFont2 (SF2) sample preset, generating a stereo sound with cubic interpolation.
sfplay3m
-- Plays a SoundFont2 (SF2) sample preset, generating a mono sound with cubic interpolation.
sfplaym
-- Plays a SoundFont2 (SF2) sample preset, generating a mono sound.
sfplist
-- Prints a list of all presets of a SoundFont2 (SF2) sample file.
sfpreset
-- Assigns an existing preset of a SoundFont2 (SF2) sample file to an index number.
shaker
-- Sounds like the shaking of a maraca or similar gourd instrument.
sin
-- Performs a sine function.
sinh
-- Performs a hyperbolic sine function.
sininv
-- Performs an arcsine function.
sleighbells
-- Semi-physical model of a sleighbell sound.
slider16
-- Creates a bank of 16 different MIDI control message numbers.
slider16f
-- Creates a bank of 16 different MIDI control message numbers, filtered before output.
slider32
-- Creates a bank of 32 different MIDI control message numbers.
slider32f
-- Creates a bank of 32 different MIDI control message numbers, filtered before output.
slider64
-- Creates a bank of 64 different MIDI control message numbers.
slider64f
-- Creates a bank of 64 different MIDI control message numbers, filtered before output.
slider8
-- Creates a bank of 8 different MIDI control message numbers.
slider8f
-- Creates a bank of 8 different MIDI control message numbers, filtered before output.
sndwarp
-- Reads a mono sound sample from a table and applies time-stretching and/or pitch modification.
sndwarpst
-- Reads a stereo sound sample from a table and applies time-stretching and/or pitch modification.
soundin
-- Reads audio data from an external device or stream.
soundout
-- Writes audio output to a disk file.
space
-- Distributes an input signal among 4 channels using cartesian coordinates.
spat3d
-- Positions the input sound in a 3D space and allows moving the sound at k-rate.
spat3di
-- Positions the input sound in a 3D space with the sound source position set at i-time.
spat3dt
-- Can be used to render an impulse response for a 3D space at i-time.
spdist
-- Calculates distance values from xy coordinates.
specaddm
-- Perform a weighted add of two input spectra.
specdiff
-- Finds the positive difference values between consecutive spectral frames.
specdisp
-- Displays the magnitude values of the spectrum.
specfilt
-- Filters each channel of an input spectrum.
spechist
-- Accumulates the values of successive spectral frames.
specptrk
-- Estimates the pitch of the most prominent complex tone in the spectrum.
specscal
-- Scales an input spectral datablock with spectral envelopes.
specsum
-- Sums the magnitudes across all channels of the spectrum.
spectrum
-- Generate a constant-Q, exponentially-spaced DFT.
spsend
-- Generates output signals based on a previously defined
space
opcode.
sqrt
-- Returns a square root value.
sr
-- Sets the audio sampling rate.
stix
-- Semi-physical model of a stick sound.
streson
-- A string resonator with variable fundamental frequency.
strset
-- Allows a string to be linked with a numeric value.
subinstr
-- Creates and runs a numbered instrument instance.
subinstrinit
-- Creates and runs a numbered instrument instance at init-time.
sum
-- Sums any number of a-rate signals.
svfilter
-- A resonant second order filter, with simultaneous lowpass, highpass and bandpass outputs.
table
-- Accesses table values by direct indexing.
table3
-- Accesses table values by direct indexing with cubic interpolation.
tablecopy
-- Simple, fast table copy opcode.
tablegpw
-- Writes a table's guard point.
tablei
-- Accesses table values by direct indexing with linear interpolation.
tableicopy
-- Simple, fast table copy opcode.
tableigpw
-- Writes a table's guard point.
tableikt
-- Provides k-rate control over table numbers.
tableimix
-- Mixes two tables.
tableiw
-- Change the contents of existing function tables.
tablekt
-- Provides k-rate control over table numbers.
tablemix
-- Mixes two tables.
tableng
-- Interrogates a function table for length.
tablera
-- Reads tables in sequential locations.
tableseg
-- Creates a new function table by making linear segments between values in stored function tables.
tablew
-- Change the contents of existing function tables.
tablewa
-- Writes tables in sequential locations.
tablewkt
-- Change the contents of existing function tables.
tablexkt
-- Reads function tables with linear, cubic, or sinc interpolation.
tablexseg
-- Creates a new function table by making exponential segments between values in stored function tables.
tambourine
-- Semi-physical model of a tambourine sound.
tan
-- Performs a tangent function.
tanh
-- Performs a hyperbolic tangent function.
taninv
-- Performs an arctangent function.
taninv2
-- Returns an arctangent.
tbvcf
-- Models some of the filter characteristics of a Roland TB303 voltage-controlled filter.
tempest
-- Estimate the tempo of beat patterns in a control signal.
tempo
-- Apply tempo control to an uninterpreted score.
tempoval
-- Reads the current value of the tempo.
tigoto
-- Transfer control at i-time when a new note is being tied onto a previously held note
timeinstk
-- Read absolute time in k-rate cycles.
timeinsts
-- Read absolute time in seconds.
timek
-- Read absolute time in k-rate cycles.
times
-- Read absolute time in seconds.
timout
-- Conditional branch during p-time depending on elapsed note time.
tival
-- Puts the value of the instrument's internal
"tie-in"
flag into the named i-rate variable.
tlineto
-- Generate glissandos starting from a control signal.
tone
-- A first-order recursive low-pass with variable frequency response.
tonek
-- A first-order recursive low-pass filter with variable frequency response.
tonex
-- Emulates a stack of filters using the tone opcode.
transeg
-- Constructs a user-definable envelope.
trigger
-- Informs when a krate signal crosses a threshold.
trigseq
-- Accepts a trigger signal as input and outputs a group of values.
trirand
-- Linear distribution random number generator.
turnoff
-- Enables an instrument to turn itself off.
turnon
-- Activate an instrument for an indefinite time.
unirand
-- Uniform distribution random number generator (positive values only).
upsamp
-- Modify a signal by up-sampling.
urd
-- A discrete user-defined-distribution random generator that can be used as a function.
valpass
-- Variably reverberates an input signal with a flat frequency response.
vbap16
-- Distributes an audio signal among 16 channels.
vbap16move
-- Distribute an audio signal among 16 channels with moving virtual sources.
vbap4
-- Distributes an audio signal among 4 channels.
vbap4move
-- Distributes an audio signal among 4 channels with moving virtual sources.
vbap8
-- Distributes an audio signal among 8 channels.
vbap8move
-- Distributes an audio signal among 8 channels with moving virtual sources.
vbaplsinit
-- Configures VBAP output according to loudspeaker parameters.
vbapz
-- Writes a multi-channel audio signal to a ZAK array.
vbapzmove
-- Writes a multi-channel audio signal to a ZAK array with moving virtual sources.
vco
-- Implementation of a band limited, analog modeled oscillator.
vco2
-- Implementation of a band-limited oscillator using pre-calculated tables.
vco2ft
-- Returns a table number at k-time for a given oscillator frequency and wavform.
vco2ift
-- Returns a table number at i-time for a given oscillator frequency and wavform.
vco2init
-- Calculates tables for use by vco2 opcode.
vcomb
-- Variably reverberates an input signal with a
"colored"
frequency response.
vdelay
-- An interpolating variable time delay.
vdelay3
-- An variable time delay with cubic interpolation.
vdelayx
-- A variable delay opcode with high quality interpolation.
vdelayxq
-- A 4-channel variable delay opcode with high quality interpolation.
vdelayxs
-- A stereo variable delay opcode with high quality interpolation.
vdelayxw
-- Variable delay opcodes with high quality interpolation.
vdelayxwq
-- Variable delay opcodes with high quality interpolation.
vdelayxws
-- Variable delay opcodes with high quality interpolation.
veloc
-- Get the velocity from a MIDI event.
vibes
-- Physical model related to the striking of a metal block.
vibr
-- Easier-to-use user-controllable vibrato.
vibrato
-- Generates a natural-sounding user-controllable vibrato.
vincr
-- Accumulates audio signals.
vlowres
-- A bank of filters in which the cutoff frequency can be separated under user control.
voice
-- An emulation of a human voice.
vpvoc
-- Implements signal reconstruction using an fft-based phase vocoder and an extra envelope.
waveset
-- A simple time stretch by repeating cycles.
weibull
-- Weibull distribution random number generator (positive values only).
wgbow
-- Creates a tone similar to a bowed string.
wgbowedbar
-- A physical model of a bowed bar.
wgbrass
-- Creates a tone related to a brass instrument.
wgclar
-- Creates a tone similar to a clarinet.
wgflute
-- Creates a tone similar to a flute.
wgpluck
-- A high fidelity simulation of a plucked string.
wgpluck2
-- Physical model of the plucked string.
wguide1
-- A simple waveguide model consisting of one delay-line and one first-order lowpass filter.
wguide2
-- A model of beaten plate consisting of two parallel delay-lines and two first-order lowpass filters.
wrap
-- Wraps-around the signal that exceeds the low and high thresholds.
wterrain
-- A simple wave-terrain synthesis opcode.
xadsr
-- Calculates the classical ADSR envelope.
xin
-- Passes variables from a user-defined opcode block,
xout
-- Retrieves variables from a user-defined opcode block,
xscanmap
-- Allows the position and velocity of a node in a scanned process to be read.
xscansmap
-- Allows the position and velocity of a node in a scanned process to be read.
xscans
-- Fast scanned synthesis waveform and the wavetable generator.
xscanu
-- Compute the waveform and the wavetable for use in scanned synthesis.
xtratim
-- Extend the duration of real-time generated events.
xyin
-- Sense the cursor position in an output window
zacl
-- Clears one or more variables in the za space.
zakinit
-- Establishes zak space.
zamod
-- Modulates one a-rate signal by a second one.
zar
-- Reads from a location in za space at a-rate.
zarg
-- Reads from a location in za space at a-rate, adds some gain.
zaw
-- Writes to a za variable at a-rate without mixing.
zawm
-- Writes to a za variable at a-rate with mixing.
zfilter2
-- Performs filtering using a transposed form-II digital filter lattice with radial pole-shearing and angular pole-warping.
zir
-- Reads from a location in zk space at i-rate.
ziw
-- Writes to a zk variable at i-rate without mixing.
ziwm
-- Writes to a zk variable to an i-rate variable with mixing.
zkcl
-- Clears one or more variables in the zk space.
zkmod
-- Facilitates the modulation of one signal by another.
zkr
-- Reads from a location in zk space at k-rate.
zkw
-- Writes to a zk variable at k-rate without mixing.
zkwm
-- Writes to a zk variable at k-rate with mixing.
16.
Score Statements and GEN Routines
Score Statements
GEN Routines
17.
The Utility Programs
Directories.
Soundfile Formats.
Credits
Analysis File Generation
File Queries
File Conversion
18.
Cscore
Events, Lists, and Operations
Writing a Main Program
More Advanced Examples
Compiling a Cscore Program
19.
Adding your own Cmodules to Csound
Function tables
Additional Space
File Sharing
String arguments
A.
Pitch Conversion
B.
Sound Intensity Values
C.
Formant Values
D.
Window Functions
E.
SoundFont2 File Format
F.
Csound64
G.
Quick Reference
Index
List of Tables
1.
Contributors
3-1.
Types of Variables
15-1.
Pitch and Frequency Values
15-1.
Pitch and Frequency Values
15-1.
Allowable Character Types
15-1.
Pitch and Frequency Values
15-1.
Pitch and Frequency Values
15-1.
Pitch and Frequency Values
A-1.
Pitch Conversion
B-1.
Sound Intensity Values (for a 1000 Hz tone)
C-1.
alto
"a"
C-2.
alto
"e"
C-3.
alto
"i"
C-4.
alto
"o"
C-5.
alto
"u"
C-6.
bass
"a"
C-7.
bass
"e"
C-8.
bass
"i"
C-9.
bass
"o"
C-10.
bass
"u"
C-11.
countertenor
"a"
C-12.
countertenor
"e"
C-13.
countertenor
"i"
C-14.
countertenor
"o"
C-15.
countertenor
"u"
C-16.
soprano
"a"
C-17.
soprano
"e"
C-18.
soprano
"i"
C-19.
soprano
"o"
C-20.
soprano
"u"
C-21.
tenor
"a"
C-22.
tenor
"e"
C-23.
tenor
"i"
C-24.
tenor
"o"
C-25.
tenor
"u"
List of Examples
14-1.
Simple Macro
14-2.
Macros with arguments
15-1.
Example of the != opcode.
15-1.
Simple example of the define macro.
15-2.
Example of the define macro with arguments.
15-1.
Example of the include opcode.
15-1.
An example of the calling a macro.
15-2.
An example of the calling a macro with arguments.
15-1.
Example of the % operator.
15-1.
Example of the > opcode.
15-1.
Example of the >= opcode.
15-1.
Example of the < opcode.
15-1.
Example of the <= opcode.
15-1.
Example of the * operator.
15-1.
Example of the + operator.
15-1.
Example of the - operator.
15-1.
Example of the / operator.
15-1.
Example of the assign opcode.
15-1.
Example of the == opcode.
15-1.
Example of the ˆ operator.
15-1.
Example of the 0dbfs opcode.
15-1.
Example of the a opcode.
15-1.
Example of the abs opcode.
15-1.
Simple example of the active opcode.
15-2.
Example of the active opcode at k-rate.
15-1.
Example of the adsr opcode.
15-1.
Example of the adsyn opcode.
15-1.
Example of the adsynt opcode.
15-1.
Example of the aftouch opcode.
15-1.
Example of the alpass opcode.
15-1.
Example of the ampdb opcode.
15-1.
Example of the ampdbfs opcode.
15-1.
Example of the ampmidi opcode.
15-1.
Example of the areson opcode.
15-1.
Example of the atone opcode.
15-1.
A simple example of the babo opcode.
15-2.
An advanced example of the babo opcode.
15-1.
Example of the balance opcode.
15-1.
Example of the bamboo opcode.
15-1.
A simple example of the bbcutm opcode.
15-2.
First steps- mono and stereo versions
15-3.
Multiple simultaneous synchronised breaks
15-4.
Cutting up any old audio- much more interesting noises than this should be possible!
15-5.
Constant stuttering- faked, not possible since can only stutter in last half bar could make extra stuttering option parameter
15-1.
Example of the betarand opcode.
15-1.
Example of the bexprnd opcode.
15-1.
Example of the biquad opcode.
15-1.
Example of the birnd opcode.
15-1.
Example of the bqrez opcode borrowed from the
"rezzy"
opcode in Kevin Conder's manual.
15-1.
Example of the butterbp opcode.
15-1.
Example of the butterbr opcode.
15-1.
Example of the butterhp opcode.
15-1.
Example of the butterlp opcode.
15-1.
Example of the buzz opcode.
15-1.
Example of the cabasa opcode.
15-1.
Example of the cauchy opcode.
15-1.
Example of the cent opcode.
15-1.
Example of the cggoto opcode.
15-1.
Simple example of the checkbox opcode.
15-1.
Example of the cigoto opcode.
15-1.
Example of the ckgoto opcode.
15-1.
Example of the clfilt opcode as a low-pass filter.
15-2.
Example of the clfilt opcode as a high-pass filter.
15-1.
Example of the clip opcode.
15-1.
Example of the cngoto opcode.
15-1.
Example of the comb opcode.
15-1.
Example of the cos opcode.
15-1.
Example of the cosh opcode.
15-1.
Example of the cosinv opcode.
15-1.
Example of the cps2pch opcode.
15-2.
Example of the cps2pch opcode using a table of frequency multipliers.
15-3.
Example of the cps2pch opcode using a 19ET scale.
15-1.
Example of the cpsmidi opcode.
15-1.
Example of the cpsmidib opcode.
15-1.
Example of the cpsoct opcode.
15-1.
Example of the cpspch opcode.
15-1.
Example of the cpstmid opcode.
15-1.
Example of the cpstun opcode.
15-1.
Example of the cpstuni opcode.
15-1.
Example of the cpsxpch opcode.
15-2.
Example of the cpsxpch opcode using a 10.5 ET scale.
15-3.
Example of the cpsxpch opcode using a Pierce scale centered on middle A.
15-1.
Example of the cpuprc opcode.
15-1.
Example of the cross2 opcode.
15-1.
Example of the crunch opcode.
15-1.
An example of the dam opcode compressing an audio signal.
15-2.
An example of the dam opcode expanding an audio signal.
15-1.
Example of the db opcode.
15-1.
Example of the dbamp opcode.
15-1.
Example of the dbfsamp opcode.
15-1.
Example of the dcblock opcode.
15-1.
Example of the dconv opcode.
15-1.
Example of the delay opcode.
15-1.
Example of the delayw opcode.
15-1.
deltap example #1
15-2.
deltap example #2
15-1.
deltap example #1
15-2.
deltap example #2
15-1.
deltap example #1
15-2.
deltap example #2
15-1.
deltap example #1
15-2.
deltap example #2
15-1.
Example of the diff opcode.
15-1.
Example of the diskin opcode.
15-1.
Example of the dispfft opcode.
15-1.
Example of the display opcode.
15-1.
Example of the distort1 opcode.
15-1.
Example of the divz opcode.
15-1.
Example of the downsamp opcode.
15-1.
Example of the dripwater opcode.
15-1.
Example of the endin opcode.
15-1.
Example of the envlpx opcode.
15-1.
Example of the event opcode.
15-2.
Example of the event opcode using a named instrument.
15-1.
Example of the exp opcode.
15-1.
Example of the expon opcode.
15-1.
Example of the exprand opcode.
15-1.
Example of the expseg opcode.
15-1.
Example of the expsega opcode.
15-1.
Example of the expsegr opcode.
15-1.
Example of the filelen opcode.
15-1.
Example of the filenchnls opcode.
15-1.
Example of the filepeak opcode.
15-1.
Example of the filesr opcode.
15-1.
Example of the flanger opcode.
15-1.
Example of the flashtxt opcode.
15-1.
Example of the FLknob opcode.
15-1.
Example of the fmb3 opcode.
15-1.
Example of the fmbell opcode.
15-1.
Example of the fmmetal opcode.
15-1.
Example of the fmpercfl opcode.
15-1.
Example of the fmrhode opcode.
15-1.
Example of the fmvoice opcode.
15-1.
Example of the fmwurlie opcode.
15-1.
Example of the fof opcode.
15-1.
Example of the fold opcode.
15-1.
Example of the follow opcode.
15-1.
Example of the follow2 opcode.
15-1.
Example of the foscil opcode.
15-1.
Example of the foscili opcode.
15-1.
Example of the fout opcode.
15-2.
Example of the fout opcode with a polyphonic score.
15-1.
Example of the fprintks opcode.
15-1.
Example of the fprints opcode.
15-1.
Example of the frac opcode.
15-1.
Example of the ftchnls opcode.
15-1.
Example of the ftgen opcode.
15-1.
Example of the ftlen opcode.
15-1.
Example of the ftlptim opcode.
15-1.
Example of the ftmorf opcode.
15-1.
Example of the ftsave opcode.
15-1.
Example of the ftsr opcode.
15-1.
Example of the gauss opcode.
15-1.
Example of the gbuzz opcode.
15-1.
Example of the gogobel opcode.
15-1.
Example of the goto opcode.
15-1.
Example of the grain opcode.
15-1.
Example of the grain2 opcode.
15-1.
Example of the grain3 opcode.
15-1.
Example of the granule opcode.
15-1.
Example of the guiro opcode.
15-1.
Example of the harmon opcode.
15-1.
Example of the hilbert opcode implementing frequency shifting.
15-2.
Example of the hilbert opcode sounding like a
"barberpole phaser"
.
15-1.
Example of the hrtfer opcode.
15-1.
Example of the hsboscil opcode.
15-2.
Example of the hsboscil opcode in a MIDI instrument.
15-1.
Example of the if...igoto combination.
15-2.
Example of the if...kgoto combination.
15-3.
Example of the if...then combo.
15-1.
Example of the igoto opcode.
15-1.
Example of the ihold opcode.
15-1.
Example of the instr opcode.
15-1.
Example of the int opcode.
15-1.
Example of the integ opcode.
15-1.
iskip=0, imode=0
15-2.
iskip=1, imode=0
15-3.
iskip=0, imode=1
15-4.
Example of the interp opcode.
15-1.
Example of the jitter opcode.
15-1.
Example of the jitter2 opcode.
15-1.
Example of the kgoto opcode.
15-1.
Example of the lfo opcode.
15-1.
Example of the line opcode.
15-1.
Example of the linrand opcode.
15-1.
Example of the linseg opcode.
15-1.
Example of the linsegr opcode.
15-1.
Example of the log opcode.
15-1.
Example of the log10 opcode.
15-1.
Example of the logbtwo opcode.
15-1.
Example of the loopseg opcode.
15-1.
Example of the lorenz opcode.
15-1.
Example of the loscil opcode.
15-1.
Example of the loscil3 opcode.
15-1.
Example of the lowpass2 opcode.
15-1.
Example of the lowres opcode.
15-1.
Example of the lowresx opcode.
15-1.
Example of the lpf18 opcode.
15-1.
Example of the lpshold opcode.
15-1.
Example of the madsr opcode.
15-1.
Example of the mandol opcode.
15-1.
Example of the marimba opcode.
15-1.
Example of the maxalloc opcode.
15-1.
Example of the midichannelaftertouch opcode.
15-1.
Example of the midichn opcode.
15-2.
An advanced example of the midichn opcode.
15-1.
Example of the midinoteoff opcode.
15-1.
Example of the midinoteoncps opcode.
15-1.
Example of the midinoteonkey opcode.
15-1.
Example of the midinoteonoct opcode.
15-1.
Example of the midinoteonpch opcode.
15-1.
Example of the midipitchbend opcode.
15-1.
Example of the moog opcode.
15-1.
Example of the moogvcf opcode.
15-1.
Example of the mpulse opcode.
15-1.
Example of the mute opcode.
15-1.
Example of the nestedap opcode.
15-1.
Example of the noise opcode.
15-1.
Example of the notnum opcode.
15-1.
Simple example of the nreverb opcode.
15-2.
An example of the nreverb opcode using an ftable for filter constants.
15-1.
Example of the nsamp opcode.
15-1.
Example of the octave opcode.
15-1.
Example of the octcps opcode.
15-1.
Example of the octmidi opcode.
15-1.
Example of the octmidib opcode.
15-1.
Example of the octpch opcode.
15-1.
Example of a user-defined opcode.
15-1.
Example of the oscbnk opcode.
15-1.
Example of the oscil opcode.
15-1.
Example of the oscil3 opcode.
15-1.
Example of the oscili opcode.
15-1.
Example of the oscilikt opcode.
15-1.
Example of the osciliktp opcode.
15-1.
Example of the oscilikts opcode.
15-1.
Example of the oscils opcode.
15-1.
Example of the p opcode.
15-1.
Example of the pareq opcode.
15-1.
Example of the pcauchy opcode.
15-1.
Example of the pchbend opcode.
15-1.
Example of the pchmidi opcode.
15-1.
Example of the pchmidib pchmidib.
15-1.
Example of the pchoct opcode.
15-1.
Example of the peak opcode.
15-1.
Example of the pgmassign opcode.
15-2.
Example of the pgmassign opcode that will ignore program change events.
15-3.
An advanced example of the pgmassign opcode.
15-1.
Example of the phaser1 opcode.
15-1.
Example of the phaser2 opcode.
15-1.
Example of the phasor opcode.
15-1.
Example of the phasorbnk opcode.
15-1.
Example of the pinkish opcode.
15-1.
Example of the pitch opcode.
15-1.
Example of the pitchamdf opcode.
15-1.
Example of the planet opcode.
15-1.
Example of the pluck opcode.
15-1.
Example of the poisson opcode.
15-1.
Example of the polyaft opcode.
15-1.
Example of the poscil opcode.
15-1.
Example of the poscil3 opcode.
15-1.
Example of the pow opcode.
15-1.
Example of the powoftwo opcode.
15-1.
Example of the prealloc opcode.
15-1.
Example of the print opcode.
15-1.
Example of the printk opcode.
15-1.
Example of the printk2 opcode.
15-1.
Example of the printks opcode.
15-1.
Example of the prints opcode.
15-1.
Example (using score-supplied f-table, assuming fsig fftsize = 1024)
15-1.
Example of the rand opcode.
15-1.
Example of the randh opcode.
15-1.
Example of the randi opcode.
15-1.
Example of the random opcode.
15-1.
Example of the randomh opcode.
15-1.
Example of the randomi opcode.
15-1.
Example of the readclock opcode.
15-1.
Example of the reinit opcode.
15-1.
Example of the repluck opcode.
15-1.
Example of the reson opcode.
15-1.
Example of the resonr and resonz opcodes.
15-1.
Example of the resony opcode.
15-1.
Example of the reverb opcode.
15-1.
Example of the rezzy opcode.
15-1.
Example of the rireturn opcode.
15-1.
Example of the rnd opcode.
15-1.
An example of the rnd31 opcode at a-rate.
15-2.
An example of the rnd31 opcode at k-rate.
15-3.
An example of the rnd31 opcode that uses the number 7 as a seed value.
15-4.
An example of the rnd31 opcode that uses the current time as a seed value.
15-1.
Example of the rtclock opcode.
15-1.
Example of the sandpaper opcode.
15-1.
Example of the scans opcode.
15-1.
Example of the scantable opcode.
15-1.
Example of the schedkwhen opcode.
15-1.
Example of the schedule opcode.
15-1.
Example of the schedwhen opcode.
15-1.
Example of the sekere opcode.
15-1.
Example of the semitone opcode.
15-1.
Example of the sensekey opcode.
15-1.
Example of the seqtime opcode.
15-1.
Example of the setctrl opcode.
15-1.
Example of the shaker opcode.
15-1.
Example of the sin opcode.
15-1.
Example of the sinh opcode.
15-1.
Example of the sininv opcode.
15-1.
Example of the sleighbells opcode.
15-1.
Example of the sndwarp opcode.
15-1.
Example of the soundin opcode.
15-1.
Stereo example of the spat3d opcode.
15-2.
UHJ example of the spat3d opcode.
15-3.
Quadrophonic example of the spat3d opcode.
15-1.
Example of the sqrt opcode.
15-1.
Example of the stix opcode.
15-1.
Example of the streson opcode.
15-1.
Example of the subinstr opcode.
15-2.
Example of the subinstr opcode using a named instrument.
15-1.
Example of the svfilter opcode.
15-1.
Example of the table opcode.
15-1.
Example of the tableng opcode.
15-1.
Example of the tambourine opcode.
15-1.
Example of the tan opcode.
15-1.
Example of the tanh opcode.
15-1.
Example of the taninv opcode.
15-1.
Example of the taninv2 opcode.
15-1.
Example of the tbvcf opcode.
15-1.
Example of the tempest opcode.
15-1.
Example of the tempo opcode.
15-1.
Example of the tempoval opcode.
15-1.
Example of the timeinstk opcode.
15-1.
Example of the timeinsts opcode.
15-1.
Example of the timek opcode.
15-1.
Example of the times opcode.
15-1.
Example of the trigger opcode.
15-1.
Example of the trirand opcode.
15-1.
Example of the turnoff opcode.
15-1.
Example of the unirand opcode.
15-1.
2-D panning example with stationary virtual sources
15-1.
2-D panning example with stationary virtual sources
15-1.
2-D panning example with stationary virtual sources
15-1.
2-D panning example with stationary virtual sources
15-1.
2-D panning example with stationary virtual sources
15-1.
2-D panning example with stationary virtual sources
15-1.
2-D panning example with stationary virtual sources
15-1.
2-D panning example with stationary virtual sources
15-1.
2-D panning example with stationary virtual sources
15-1.
Example of the vco opcode.
15-1.
Example of the vco2 opcode.
15-1.
Example of the veloc opcode.
15-1.
Example of the vibes opcode.
15-1.
Example of the vibr opcode.
15-1.
Example of the vibrato opcode.
15-1.
Example of the vlowres opcode.
15-1.
Example of the voice opcode.
15-1.
Example of the waveset opcode.
15-1.
Example of the weibull opcode.
15-1.
Example of the wgbow opcode.
15-1.
Example of the wgbowedbar opcode.
15-1.
Example of the wgbrass opcode.
15-1.
Example of the wgclar opcode.
15-1.
Example of the wgflute opcode.
15-1.
An example of the wgpluck opcode.
15-2.
An example of the wgpluck opcode with a shorter, brighter note.
15-1.
Example of the wgpluck2 opcode.
15-1.
Example of the wguide1 opcode.
15-1.
Example of the wterrain opcode.
15-1.
Example of the xyin opcode.
15-1.
Example of the zacl opcode.
15-1.
Example of the zakinit opcode.
15-1.
Example of the zamod opcode.
15-1.
Example of the zar opcode.
15-1.
Example of the zarg opcode.
15-1.
Example of the zaw opcode.
15-1.
Example of the zawm opcode.
15-1.
Example of the zir opcode.
15-1.
Example of the ziw opcode.
15-1.
Example of the ziwm opcode.
15-1.
Example of the zkcl opcode.
15-1.
Example of the zkmod opcode.
15-1.
Example of the zkr opcode.
15-1.
Example of the zkw opcode.
15-1.
Example of the zkwm opcode.
16-1.
A simple example of the GEN01 routine.
16-2.
An example of the GEN01 routine with a computed tablesize.
16-1.
A simple example of the GEN02 routine.
16-1.
A simple example of the GEN03 routine.
16-1.
A simple example of the GEN05 routine.
16-1.
A simple example of the GEN06 routine.
16-1.
A simple example of the GEN07 routine.
16-1.
A simple example of the GEN08 routine.
16-1.
A simple example of the GEN09 routine.
16-2.
A square wave generated by the GEN09 routine.
16-1.
A simple example of the GEN10 routine.
16-1.
A simple example of the GEN11 routine.
16-1.
A simple example of the GEN12 routine.
16-1.
A simple example of the GEN13 routine.
16-1.
A simple example of the GEN14 routine.
16-1.
A simple example of the GEN19 routine.
D-1.
Hamming window function statement
D-2.
Hanning window function statement
D-3.
Bartlett window function statement
D-4.
Blackman window function statement
D-5.
Blackman-Harris window function statement
D-6.
Gaussian window function statement
D-7.
Rectangle window function statement
D-8.
Sync window function statement
Next
Preface