<- C I ->

ORCHESTRA HEADER STATEMENTS

          sr = n1
          kr = n2
          ksmps = n3 
          nchnls = n4  
These statements are global value assignments, made at the beginning of an orchestra, before any instrument block is defined. Their function is to set certain reserved symbol variables that are required for performance. Once set, these reserved symbols can be used in expressions anywhere in the orchestra.

sr = (optional) - set sampling rate to n1 samples per second per channel. The default value is 10000.

kr = (optional) - set control rate to n2 samples per second. The default value is 1000.

ksmps = (optional) - set the number of samples in a Control Period to n3. This value must equal sr/kr. The default value is 10.

nchnls = (optional) - set number of channels of audio output to n4. (1 = mono, 2 = stereo, 4 = quadraphonic.) The default value is 1 (mono).

In addition, any global variable can be initialized by an init-time assignment anywhere before the first instr statement.

All of the above assignments are run as instrument 0 (i - pass only) at the start of real performance.

Example of header assignments

     sr = 10000 
     kr = 500 
     ksmps = 20 

gi1  =    sr/2.
ga   init 0
gitranspose =  octpch(.0l)   
<- C I ->
Prepared from the MIT Media Lab Csound Manual, PJN, Nov 1994.