faustgen

faustgen — Compiles, Instantiates and runs a compiled Faust program.

Description

Faustgen will invoke the just-in-time compiler, instantiate and run a Faust program.

Syntax

ihandle,a1[,a2,...] faustgen SCode[,ain1,...] 

Initialization

Scode -- a string containing a Faust program.

ihandle -- a handle to the Faust DSP instance, which can be used to access its controls with faustctl.

Performance

ain1,... -- input signals

a1,... -- output signals

Examples

Here is an example of the faustgen opcode. It uses the file faustgen.csd.

Example 259. Example of the faustgen opcode.

See the sections Real-time Audio and Command Line Flags for more information on using command line flags.

<CsoundSynthesizer>
<CsOptions>
-odac
</CsOptions>
<CsInstruments>
instr 1
 ain1 oscili 0dbfs/2, 440
 idsp,a1 faustgen {{
   gain = hslider("vol",1,0,1,0.01);
   process = (_ * gain); 
  }}, ain1
 k1 line  0, p3, 1
 faustctl idsp, "vol", k1
   out a1
endin
</CsInstruments>
<CsScore>
i1 0 10
</CsScore>
</CsoundSynthesizer>


Credits

Author: Victor Lazzarini, 2013