fluidOut

fluidOut — Outputs sound from a given fluidEngine

Syntax

aleft, aright fluidOut ienginenum

Description

Outputs the sound from a fluidEngine.

Initialization

ienginenum -- engine number assigned from fluidEngine

Performance

aleft -- Left channel audio output.

aright -- Right channel audio output.

Invoke fluidOut in an instrument definition numbered higher than any fluidcontrol instrument definitions. All SoundFonts used in the fluidEngine numbered ienginenum send their audio output to this one opcode. Send a note with an indefinite duration to this instrument to turn the SoundFonts on for as long as required.

Examples

Here is an example of the fluidsynth opcodes. It uses the file fluid.orc.

sr = 44100
ksmps = 100
nchnls = 2

giengine  fluidEngine
isfnum    fluidLoad "07AcousticGuitar.sf2", giengine, 1
          fluidProgramSelect giengine, 1, isfnum, 0, 0

instr 1
          mididefault     60, p3
          midinoteonkey   p4, p5

  ikey    init            p4
  ivel    init            p5

          fluidNote       giengine, 1, ikey, ivel
endin

instr 99
  imvol   init            70000
  asigl, asigr fluidOut   giengine
          outs            asigl * imvol, asigr * imvol
endin

See fluidEngine for more examples.

See Also

fluidEngine, fluidNote, fluidLoad

Credits

Michael Gogins (gogins at pipeline dot com), Steven Yi. Thanks to Peter Hanappe for Fluidsynth.