QUICK-REF - CsoundManual - Top of this section - Previous - Contents - Index - Next 

rms, gain, balance

     kr   rms       asig[, ihp, istor]
     nr   gain      asig, krms[, ihp, istor]
     ar   balance   asig, acomp[, ihp, istor]


The rms power of asig can be interrogated, set, or adjusted to match that of a comparator signal.


ihp (optional) - half-power point (in cps) of a special internal low-pass filter. The default value is 10.

istor (optional) - initial disposition of internal data space ( see reson). The default value is 0.


rms output values kr will trace the rms value of the audio input asig. This unit is not a signal modifier, but functions rather as a signal power-guage.

gain provides an amplitude modification of asig so that the output ar has rms power equal to krms. rms and gain used together (and given matching ihp values) will provide the same effect as balance.

balance outputs a version of asig, amplitude-modified so that its rms power is equal to that of a comparator signal acomp. Thus a signal that has suffered loss of power (eg., in passing through a filter bank) can be restored by matching it with, for instance, its own source. It should be noted that gain and balance provide amplitude modification only - output signals are not altered in any other respect.


  asrc  buzz      10000,440, sr/440, 1   ; band-limited pulse train
  a1    reson     asrc, 1000,100         ; sent through
  a2    reson     a1,3000,500            ; 2 filters
  afin  balance   a2, asrc               ; then balanced with source

QUICK-REF - CsoundManual - Top of this section - Previous - Contents - Index - Next 
HTML Csound Manual - © Jean Piché & Peter J. Nix, 1994-97