Is it possible to leverge built-in DSPs when creating a DSP plugin?

Say I want to make a multiband compressor and want to leverage the filter and compressor plugin that comes with FMOD, is it possible?

The DSP API seems to only support routing signals to it and doesn’t have a way to pass in audio buffers directly. (I could be totally wrong)

Hi,

Could you elaborate on how you wish to use this DSP? This may help guide you in the right direction.

In JUCE the DSPs have a process function that takes an audio buffer reference and process it. So to make a multiband compressor in theory the programmer doesn’t have to re-write the compressor and filters. They can make it by: (assuming 3 bands)

  1. Construct 3 filters
  2. Construct 3 compressors
  3. For every buffer block, copy the block 2 more times, pass them into each filter, call filter->process(buffer) to get the bands
  4. Pass the bands into compressors, call compressor->process(buffer)
  5. Combine the output buffers from the compressors

Here is an example:

(File PluginProcessor.cpp, key functions: SimpleMBCompAudioProcessor::splitBands and SimpleMBCompAudioProcessor::processBlock )

Does FMOD DSPs also have something similar to the process function that takes an audio buffer and outputs the processed result. (Or a way to add DSP callbacks to the out-of-box DSPs)

Hi,

Thank you for the explanation, while yes this is possible it will be rather messy.

Yes, we do. Both the FMOD_DSP_READ_CALLBACK and the FMOD_DSP_PROCESS_CALLBACK (FMOD API | Plugin API Reference - DSP) which allow you to process an audio buffer.

This is the part where it will get messy:

It would be possible to pass either a built DSP into another or pass the System object which will allow you to build DSP within the ‘top-level’ DSP. However, this could cause race condition issues and other unexpected behavior. In summary, while it is possible to do so, I wouldn’t recommend it - since you’re familiar with JUCE, you may find it easier to implement the filters and compressors yourself, and connect them to the DSP parameters"

I hope this helps

1 Like