faustdsp

faustdsp — Instantiates a Faust program.

Description

Plugin opcode in faustcsound. This opcode is part of the plugin repository and has to be installed separately. The plugin repository can be found here: https://github.com/csound/plugins

Faustdsp will instantiate a Faust program compiled with faustcompile.

Syntax

ihandle faustdsp ifac 

Initialization

ifac -- a handle to a compiled Faust program, produced by faustcompile.

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

Examples

Here is an example of the faustdsp opcode. Play faustdsp.csd

Example 289. Example of the faustdsp opcode.

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

<CsoundSynthesizer>
<CsOptions>
-d -odac
</CsOptions>
<CsInstruments>
nchnls= 1

giph faustcompile {{
SR = 44100;
decimal(a) = a - floor(a);
freq = hslider("freq", 0, -20000, 20000, 1);
incr(fr) =  fr / float(SR);
phasor(fr,ph) =  incr(fr) : (+ : decimal) ~ _ :
+(ph) : decimal;
process = phasor(freq,0);
}}, "-vec -lv 1"

instr 1
kb1 = p5
ib faustdsp giph
faustctl ib,"freq",kb1
asig faustplay ib
out sin(2*$M_PI*asig)*p4*0dbfs
endin


</CsInstruments>
<CsScore>
i1 0 1 0.5 150
</CsScore>
</CsoundSynthesizer>


Credits

Author: Victor Lazzarini, 2018