CONTENTS
Part Ⅰ Introduction
1 Music Programming Systems = 3
1.1 Introduction = 3
1.2 Early Music Programming Languages = 4
1.2.1 MUSIC Ⅳ = 5
1.2.2 MUSIC Ⅴ = 7
1.2.3 MUSIC 360 = 9
1.2.4 MUSIC 11 = 11
1.3 Csound = 12
1.3.1 Csound 5 = 14
1.3.2 Csound 6 = 14
1.3.3 Compatibility and Preservation = 15
1.4 Conclusions = 16
2 Key System Concepts = 17
2.1 Introduction = 17
2.2 General Principles of Operation = 18
2.2.1 CSD Text Files = 18
2.2.2 Using the Numeric Score = 19
2.2.3 Csound Options = 20
2.3 Frontends = 20
2.3.1 The csound Command = 21
2.3.2 Console messages = 22
2.4 Audio Computation, the Sampling Theorem, and Quantisation = 23
2.4.1 Aliasing = 24
2.4.2 Quantisation Precision = 25
2.4.3 Audio Channels = 26
2.5 Control Rate, ksmps and Vectors = 27
2.6 Instruments, Instances, and Events = 29
2.6.1 The Life Cycle of an Instrument = 31
2.6.2 Global Code = 33
2.7 Function Tables = 33
2.7.1 GEN Routines = 33
2.7.2 Normalisation = 34
2.7.3 Precision = 34
2.7.4 Guard Point = 35
2.7.5 Table types = 35
2.8 Audio Input and Output = 35
2.8.1 Audio Buffers = 36
2.8.2 The Audio IO Layers = 36
2.8.3 Real-Time Audio = 38
2.8.4 Offline Audio = 41
2.9 Csound Utilities = 41
2.10 Environment Variables = 43
2.10.1 Configuration File = 43
2.11 The Csound API = 44
2.11.1 A Simple Example = 44
2.11.2 Levels of Functionality = 46
2.12 Conclusions = 49
Part Ⅱ The Language
3 Fundamentals = 53
3.1 Introduction = 53
3.2 Instruments = 54
3.2.1 Statements = 54
3.2.2 Expressions = 55
3.2.3 Comments = 56
3.2.4 Initialisation Pass = 56
3.2.5 Performance Time = 56
3.2.6 Parameters = 58
3.2.7 Global Space Code = 58
3.3 Data Types and Variables = 59
3.3.1 Init-Time Variables = 59
3.3.2 Control-Rate Variables = 61
3.3.3 Audio-Rate Variables = 62
3.3.4 Global Variables = 64
3.4 Opcodes = 65
3.4.1 Structure = 65
3.4.2 Syntax = 66
3.4.3 Functions = 67
3.4.4 Initialisation and Performance = 67
3.5 Fundamental Opcodes = 69
3.5.1 Input and Output = 69
3.5.2 Oscillators = 69
3.5.3 Table Generators = 73
3.5.4 Table Access = 75
3.5.5 Reading Soundfiles = 77
3.5.6 Pitch and Amplitude Converters = 78
3.5.7 Envelope Generators = 80
3.5.8 Randomness = 82
3.6 The Orchestra Preprocessor = 86
3.7 Conclusions = 89
4 Advanced Data Types = 91
4.1 Introduction = 91
4.2 Strings = 91
4.2.1 Usage = 92
4.3 Spectral-Domain Signals = 94
4.3.1 f-sig Variables = 94
4.3.2 w-sig Variables = 96
4.4 Arrays = 97
4.4.1 Initialisation = 97
4.4.2 Setting Values = 98
4.4.3 Reading Values = 99
4.4.4 Performance Time = 99
4.4.5 String and f-sig Arrays = 100
4.4.6 Arithmetic Expressions = 100
4.4.7 Arrays and Function tables = 101
4.4.8 Audio Arrays = 102
4.5 Conclusions = 103
5 Control of Flow and Scheduling = 105
5.1 Introduction = 105
5.2 Program Flow Control = 105
5.2.1 Conditions = 106
5.2.2 Branching = 106
5.2.3 Loops = 111
5.3 Scheduling = 114
5.3.1 Performance-Time Event Generation = 115
5.3.2 Recursion = 116
5.3.3 MIDI Notes = 117
5.3.4 Duration Control = 117
5.3.5 Ties = 118
5.4 Reinitialisation = 120
5.5 Compilation = 122
5.6 Conclusions = 123
6 Signal Graphs and Busses = 125
6.1 Introduction = 125
6.2 Signal Graphs = 126
6.3 Execution Order = 127
6.3.1 Instances = 128
6.3.2 Instruments = 128
6.4 Busses = 129
6.4.1 Global Variables = 129
6.4.2 Tables = 131
6.4.3 Software Bus = 134
6.5 Conclusions = 136
7 User-Defined Opcodes = 139
7.1 Introduction = 139
7.2 Syntax = 140
7.2.1 Arguments = 140
7.3 Instrument State and Parameters = 143
7.4 Local Control Rate = 144
7.5 Recursion = 147
7.6 Subinstruments = 150
7.7 Conclusions = 151
Part Ⅲ Interaction
8 The Numeric Score = 155
8.1 Introduction = 155
8.2 Basic Statements = 156
8.3 Sections = 158
8.4 Preprocessing = 159
8.4.1 Carry = 159
8.4.2 Tempo = 160
8.4.3 Sort = 160
8.4.4 Next-p and Previous-p = 161
8.4.5 Ramping = 161
8.4.6 Expressions = 161
8.4.7 Macros = 162
8.4.8 Include = 163
8.5 Repeated Execution and Loops = 163
8.6 Performance Control = 165
8.6.1 Extract = 166
8.6.2 Orchestra Control of Score Playback = 166
8.6.3 Real-Time Events = 167
8.7 External Score Generators = 167
8.8 Alternatives to the Numeric Score = 169
8.9 Conclusions = 170
9 MIDI Input and Output = 171
9.1 Introduction = 171
9.2 MIDI Messages = 171
9.2.1 Channel Message Types = 172
9.3 The Csound MIDI System = 173
9.3.1 Input = 173
9.3.2 Output = 176
9.3.3 MIDI Backends = 177
9.4 Conclusions = 178
10 Open Sound Control and Networking = 181
10.1 Introduction = 181
10.2 Open Sound Control = 181
10.2.1 The OSC Protocol = 182
10.2.2 Csound Implementation = 182
10.2.3 Inter-application Examples = 185
10.3 Network Opcodes = 191
10.4 Csound UDP Server = 192
10.5 Conclusions = 193
11 Scripting Csound = 195
11.1 Introduction = 195
11.2 Csound API = 195
11.3 Managing an Instance of Csound = 196
11.3.1 Initialisation = 196
11.3.2 First Compilation = 197
11.3.3 Performing = 198
11.3.4 Score Playback Control and Clean-up = 199
11.4 Sending Events = 200
11.5 The Software Bus = 200
11.5.1 Control Data = 200
11.5.2 Audio Channels = 201
11.6 Manipulating Tables = 202
11.7 Compiling Orchestra Code = 203
11.8 A Complete Example = 203
11.9 Conclusions = 205
Part Ⅳ Instrument Development
12 Classic Synthesis = 209
12.1 Introduction = 209
12.1.1 Waveforms and Spectra = 210
12.2 Source-Modifier Methods = 212
12.2.1 Sources = 212
12.2.2 Modifiers = 219
12.2.3 Design Example 1 : Analogue Modelling = 223
12.2.4 Design Example 2 : Channel Vocoder = 225
12.3 Distortion Synthesis Methods = 228
12.3.1 Summation Formulae = 228
12.3.2 Waveshaping = 232
12.3.3 Frequency and Phase Modulation = 234
12.3.4 Phase-Aligned Formant Synthesis = 239
12.3.5 Modified FM Synthesis = 240
12.4 Additive Synthesis = 243
12.4.1 A Tonewheel Organ Instrument = 245
12.4.2 Synthesis by Analysis = 249
12.5 Conclusions = 253
13 Time-Domain Processing = 255
13.1 Introduction = 255
13.2 Delay Lines = 255
13.2.1 Feedback = 258
13.2.2 All-Pass Filters = 260
13.2.3 Reverb = 262
13.2.4 Convolution = 268
13.3 Variable Delays = 270
13.3.1 Flanger = 271
13.3.2 Chorus = 273
13.3.3 Vibrato = 274
13.3.4 Doppler = 276
13.3.5 Pitch Shifter = 278
13.4 Filters = 280
13.4.1 Design Example : a Second-Order All-Pass Filter = 280
13.4.2 Equalisation = 284
13.4.3 FIR Filters = 285
13.4.4 Head-Related Transfer Functions = 289
13.5 Multichannel Spatial Audio = 290
13.5.1 Ambisonics = 290
13.5.2 Vector Base Amplitude Panning = 293
13.6 Conclusions = 293
14 Spectral Processing = 295
14.1 Introduction = 295
14.2 Tools for Spectral Analysis and Synthesis = 296
14.2.1 Fourier Transform = 296
14.2.2 Fourier Series = 297
14.2.3 Discrete Fourier Transform = 298
14.3 Fast Convolution = 302
14.4 The Phase Vocoder = 306
14.4.1 Frequency Effects = 311
14.4.2 Formant Extraction = 312
14.4.3 Spectral Filters = 314
14.4.4 Cross-synthesis and Morphing = 315
14.4.5 Timescaling = 316
14.4.6 Spectral Delays = 319
14.4.7 Miscellaneous Effects = 321
14.5 Sinusoidal Modelling = 321
14.5.1 Additive Synthesis = 323
14.5.2 Residual Extraction = 324
14.5.3 Transformation = 326
14.6 Analysis Transformation and Synthesis = 326
14.6.1 The ATS Analysis = 326
14.6.2 The ATS Analysis File Format = 328
14.6.3 Resynthesis of the Sinusoidal Part = 329
14.6.4 Resynthesis of the Residual Part = 332
14.6.5 Transformations = 334
14.7 Conclusions = 336
15 Granular Synthesis = 337
15.1 Introduction = 337
15.1.1 Low Grain Rates, Long Grains = 338
15.1.2 High Grain Rates, Periodic Grain Clock = 340
15.1.3 Grain Clouds, Irregular Grain Clock = 342
15.2 Granular Synthesis Versus Granular Effects Processing = 343
15.2.1 Grain Delay = 344
15.2.2 Granular Reverb = 348
15.3 Manipulation of Individual Grains = 353
15.3.1 Channel Masks, Outputs and Spatialisation = 357
15.3.2 Waveform Mixing = 360
15.4 Clock Synchronisation = 363
15.5 Amplitude Modulation and Granular Synthesis = 368
15.6 Pitch Synchronous Granular Synthesis = 372
15.7 Morphing Between Classic Granular Synthesis Types = 374
15.7.1 Glissons = 374
15.7.2 Grainlets = 375
15.7.3 Trainlets = 375
15.7.4 Pulsars = 376
15.7.5 Formant Synthesis = 376
15.7.6 Morphing Between Types of Granular Synthesis = 378
15.8 Conclusions = 384
16 Physical Models = 385
16.1 Introduction = 385
16.2 Waveguides = 385
16.2.1 Simple Plucked String = 386
16.2.2 Wind Instruments = 390
16.2.3 More Waveguide Ideas = 394
16.3 Modal Models = 395
16.4 Differential Equations and Finite Differences = 397
16.5 Physically Inspired Models = 399
16.6 Other Approaches = 399
16.6.1 Spring-Mass System = 399
16.6.2 Scanned Synthesis = 402
16.6.3 And More = 405
16.7 Conclusions = 405
Part Ⅴ Composition Case Studies
17 Iain McCurdy : Csound Haiku = 409
17.1 Introduction = 409
17.2 Groundwork = 410
17.3 The Pieces = 411
17.3.1 Haiku Ⅰ = 412
17.3.2 Haiku Ⅱ = 415
17.3.3 Haiku Ⅲ = 420
17.3.4 Haiku Ⅳ = 423
17.3.5 Haiku Ⅴ = 426
17.3.6 Haiku Ⅵ = 428
17.3.7 Haiku Ⅶ = 431
17.3.8 Haiku Ⅷ = 435
17.3.9 Haiku Ⅸ = 440
17.4 Conclusions = 442
18 Øyvind Brandtsegg : Feedback Piece = 443
18.1 Introduction = 443
18.2 Feedback-Processing Techniques = 444
18.3 Coloring Effects = 447
18.4 Hosting and Interfacing = 450
18.5 Automation and Composed Form = 450
18.6 Spatial and Performative Considerations = 451
19 Joachim Heintz : Knuth and Alma, Live Electronics with Spoken Word = 455
19.1 Introduction = 455
19.2 Idea and Set-up = 456
19.3 Knuth = 456
19.3.1 Rhythm Analysis = 457
19.3.2 Possibilities = 458
19.4 Alma = 460
19.4.1 Game of Times = 460
19.4.2 Speech as Different-Sized Pieces of Sounding Matter = 460
19.4.3 Bringing Back the Past : Four Modes = 463
19.4.4 Improvisation or Composition = 464
19.5 Conclusions = 468
20 John flitch : Se''''nnight = 469
20.1 Introduction = 469
20.2 Henon Map and Torus Map = 470
20.3 Genesis of Se''''nnight = 471
20.4 Instruments = 472
20.5 Score Generation = 472
20.5.1 Score 1 = 472
20.5.2 Score2 and Score3 = 473
20.6 Start and End = 474
20.7 Multichannel Delivery = 474
20.8 Conclusions = 475
21 Steven Yi : Transit = 477
21.1 Introduction = 477
21.2 About Blue = 478
21.3 Mixer, Effects and the Signal Graph = 478
21.4 Instruments = 480
21.5 Improvisation and Sketching = 483
21.6 Score = 485
21.7 Conclusions = 486
22 Victor Lazzarini : Noctilucent Clouds = 487
22.1 Introduction = 487
22.2 The Basic Ingredients = 488
22.2.1 Dynamic Spectral Delays = 488
22.2.2 Variable Delay Processing = 491
22.2.3 Feedback = 492
22.3 Source Sounds = 493
22.4 Large-Scale Structure = 495
22.5 Post-production = 496
22.5.1 Source Code Packaging = 498
22.6 Conclusions = 498
References = 501
Index = 507