Sound Effects

Effects modules are available only with the MPTK Pro version.

Important: by default, MPTK disable these effects. You have to enable them from the prefabs inspector. Adding low-filter effect is often good to get a better sound!

There is two kinds of effects:

  • Effects defined from SoundFont and processed with fluidsynth,
  • Unity Effects associated to the AudioSource

Look at the inspector of the MPTK prefab (MidiFilePlayer, MidiStreamPlayer, MidiListPayer, …) to see effects parameters.

SoundFont effects

A SoundFont contains parameters to apply three kinds of effects: low-pass filter, reverb, chorus. These parameters can be specifics for each instruments and even each notes. See below the low-pass frequency set for Piano. Viena is a perfect tool to edit SoundFont.

Screen shot from Viena

MPTK effects are based on FluidSynth effects modules. Furthermore, to get more liberty from SoundFont, MPTK can increase or decrease the impact of effects (from the inspector or by script).

In summary:

  • Effects are applied independently for each notes but are statically defined in the SoundFont.
  • MPTK parameters can increase or decrease default SoundFont Values. This will be applied to the whole prefab. See below.
  • More CPU is need for these effects. See impact of effect on DSP load here. See performance information here

Unity Effects

Obviously, Unity effects are also available, but unlike SoundFont effects, they applied to the whole player. On the other hand, the Unity effects parameters are rich!

Reverb and Chorus effects can be applied directly in the prefab:

Furthermore, you can add any Audio Filter you want to the AudoSource in the prefab:

Set effect by script

All effects parameters available from Inspector can be set also by script. See detail in the the class MidiSynth documentation. See below for the SoundFont Effects:

  • bool MPTK_ApplySFFilter
  • float MPTK_SFFilterFreqOffset
  • bool MPTK_ApplySFChorus
  • float MPTK_SFChorusAmplify
  • boolMPTK_ApplySFReverb
  • float MPTK_SFReverbAmplify