Instructions on using the PortAudio driver in the Fluidsynth Extension

From jOrgan Wiki v1.25.1
Jump to: navigation, search

Installing and configuring Fluidsynth backends in jOrgan 3.18 and upwards.

Fluidsynth can now be used with different “backends” or drivers for the soundcard used.

Currently the available backends are:

– default – using the dsound driver of Windows

– BCA provided drivers at [http://sourceforge.net/projects/jorgan/files/fluidsynth/]:

fluidsynth-dsound-portaudio-asio-demo-x86 for ASIO 32-bit driver

fluidsynth-dsound-portaudio-x86-1 for WMME/WDMKS/WASAPI 32-bit driver

- GrahamG provided drivers at [http://sourceforge.net/projects/jorgan/files/fluidsynth/]:

Fluidsynth 1.1.6 32-bit - Dsound, Portaudio_ASIO/WDMKS/WASAPAI/ALL, JACK

Fluidsynth 1.1.6 64-bit - Dsound, Portaudio_ASIO/WDMKS/WASAPAI/ALL, JACK

       NOTE: When using PortAudio-WASAPI you must make sure that the sample rate configured in the Fluidsynth element matches the sample rate that your soundcard is configured to.

Start jOrgan 3.18 or later and click View/Configuration/Fluidsynth.

Before adding any additional backends you should see:

Fluidsynth backends html 4a0a0417.png

To install the additional backends, open the .zip archives and place the respective subdirectories as shown below:

Fluidsynth backends html m5fac64de.png

To configure a backend, start jOrgan 3.18 or later and click View/Configuration/Fluidsynth.

Click on the small black triangle in the Backend drop-down box to open it.

Select the backend you want to use, click Apply, click OK close jOrgan and restart it.

Clicking Restore installs the “default” backend.


After having placed the backend subdirectories as indicated above you could see for ASIO:

Fluidsynth backends html m7598e309.png

or for WMME/WDMKS/WASAPI:


Fluidsynth backends html m7f4fc512.png

Using the Christie Theatre Organ disposition as example with the WASAPI driver, hereafter is what you see when you go into Construct mode and open the respective fluidsynth sound elements:

Fluidsynth backends html m2a77e83.png

Fluidsynth backends html m4ef31922.png

Fluidsynth backends html 21b360be.png



OLD Fluidsynth with PortAudio instructions for pre-jOrgan 3.18 users

Fluidsynth with PortAudio is supported starting with jOrgan 3.13 beta 7 and up to the most recent release - jOrgan 3.15.

Go to jOrgan 3.15 to download the latest version.

I have been asked by a few people about what the difference is between ASIO and WDM/KS and which one would be better for them to use.

The bottom line is this:

If you have an ASIO driver for your soundcard, or you want to add VST reverb using JackRouter, then the ASIO driver is what you should be using.

If you don't have an ASIO driver for your audio device, and are not using VST reverb, then the WDM/KS driver is the one that you should be using.

For those that are using ASIO4ALL, the ASIO4ALL driver receives audio through the ASIO specification interface, but it connects to your audio device through WDM/KS or its Win7 update called WaveRT, so unless you are using VST reverbs with JackRouter, there is no real difference between ASIO -> ASIO4ALL and WDM/KS.


Fluidsynth with PortAudio WDM/KS

WDM/KS is the Windows Driver Model Kernel Streaming driver, which offers much lower latency than the default DSound driver.

  • Download: [fluidsynth-1.1.4-wdmks.zip]
  • Decompress the ZIP file into your 32-bit jOrgan folder, and either allow the old libfluidsynth.dll to be overwritten or rename it in order to keep a copy of it.
  • Start jOrgan
  • Load a fluidsynth based disposition
  • Enter Construct Organ mode
  • Locate the Fluidsynth Sound element(s)
  • In the Fluidsynth element's audio driver select portaudio
  • Then in the audio device property select your WDM device
  • Exit Construct Organ mode
  • Test the organ

Notes:

Some audio device drivers are set to a specific sample rate, so the only way to connect to them is to adjust the Fluidsynth sample rate (which is the sample rate used to connect to the audio device) to match what is set by the driver. Unfortunately I don't know of a tool that reports back what these set sample rates are.... I just know that some audio devices are hardcoded for 44.1khz, others to 48khz. Use the trial and error method to see what works for you.

Fluidsynth with PortAudio ASIO

Audio Stream Input/Output (ASIO) is a computer sound card driver protocol for digital audio specified by Steinberg, providing a low-latency and high fidelity interface between a software application and a computer's sound card. If you do not have an ASIO driver for your soundcard you may consider using the ASIO4ALL generic driver (see Instructions on using the generic ASIO4ALL driver).

  • Download: [fluidsynth-1.1.4-asio.zip]
  • Decompress the ZIP file into your 32-bit jOrgan folder, and either allow the old libfluidsynth.dll to be overwritten or rename it in order to keep a copy of it.
  • Start jOrgan
  • Load a fluidsynth based disposition
  • Enter Construct Organ mode
  • Locate the Fluidsynth Sound element(s)
  • In the Fluidsynth element's audio driver select portaudio
  • Then in the audio device property select your ASIO device
  • Exit Construct Organ mode
  • Test the organ

NOTE: (from user Dell) If you have a red "X" in the ASIO4ALL WDM Device list for the desired audio card output, try adjusting the FluidSynth buffers. For example, on my Creative AudioPC (ES1371,ES1373) the "OUT: 2x 4-48khz, 16Bits" Pin was inactive. I went into jOrgan construct organ menu, selected the FluidSynth driver, and cranked the number of buffers down from 8 to 2. Went back to usual play mode in jOrgan and magically the ASIO4ALL 'out' pin was a blue arrow again!

Also see the Instructions on using the Jack Audio Connection Kit in Windows so that you can connect the ASIO output of fluidsynth to other ASIO capable programs (like VST convolution reverbs) and use multiple fluidsynth ASIO sound elements.

Fluidsynth with PortAudio WASAPI

WASAPI (Windows Audio Session API) is an updated Microsoft Windows low latency audio layer available in Windows Vista and Windows 7.

  • Download: [fluidsynth-1.1.4-wasapi.zip]
  • Decompress the ZIP file into your 32-bit jOrgan folder, and either allow the old libfluidsynth.dll to be overwritten or rename it in order to keep a copy of it.
  • Start jOrgan
  • Load a fluidsynth based disposition
  • Enter Construct Organ mode
  • Locate the Fluidsynth Sound element(s)
  • In the Fluidsynth element's audio driver select portaudio
  • Then in the audio device property select your WASAPI device
  • Exit Construct Organ mode
  • Test the organ

Notes: WASAPI can also operate in 'shared' mode, like the dsound driver, so multiple fluidysnth elements are supported.

Release Licenses

Fluidsynth

The Fluidsynth libraries available from these downloads are released under the Lesser General Public License (LGPL). Please see the Fluidsynth website [[1]] for links to the project SourceCode.

PortAudio

The PortAudio libraries are released under the MIT license:

PortAudio Portable Real-Time Audio Library Copyright (c) 1999-2011 Ross Bencina and Phil Burk

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND ON INFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. (See http://opensource.org/licenses/mit-license.php)

The PortAudio ASIO library

ASIO is a trademark of [Steinberg Media Technologies GmbH].