Help with simple FIR filter convolution

Not an expert in CPP and/or JUCE, but I’m trying to implement a long (>511) FIR filter with the convolution class.

Everything seems to run and build from a simple example, but I notice that the filter is not doing anything while bypassing on/ff with the plugin host. There are 10dB dfference in low freq resp, so when you listen to it is very easy to notice that is working. (When testing it offline without JUCE of course)

When debugging with CMAKE I continuously see: AudioPluginHost[10831:2836784] [AMCP] 88331 HALC_ProxyIOContext.cpp:1334 HALC_ProxyIOContext::IOWorkLoop: skipping cycle due to overload

A brief on the implementation:

In my pluginProcessor.h:

    struct ConvolutionWithLatency : public juce::dsp::Convolution
    {
        ConvolutionWithLatency() : juce::dsp::Convolution(juce::dsp::Convolution::NonUniform{256}) {}
    };

    juce::dsp::ProcessorChain<juce::dsp::Gain<float>, ConvolutionWithLatency> processorChain;

In my pluginProcessor.cpp

    int numTries = 0;
    auto dir = juce::File::getCurrentWorkingDirectory();
     while (! dir.getChildFile ("hinv.wav").exists() && numTries++ < 15)
            dir = dir.getParentDirectory();
    auto& convolution = processorChain.get<1>();
    convolution.loadImpulseResponse(dir.getChildFile ("hinv.wav"), juce::dsp::Convolution::Stereo::no, juce::dsp::Convolution::Trim::no, 0);

    processorChain.prepare(spec);

The filter has 511 samples and here is a REW screenshot of its analysis:

Any comment are appreciated

You’re not showing how you’re actually using the processorChain inside processBlock.

thanks for the quick reply. Like this:

void PluginProcessor::processBlock (juce::AudioBuffer<float>& buffer, juce::MidiBuffer& midiMessages)
{
    juce::ScopedNoDenormals noDenormals;
    
    // if (requiresUpdate.load())
    //     update();

    auto totalNumInputChannels  = getTotalNumInputChannels();
    auto totalNumOutputChannels = getTotalNumOutputChannels();
    
    const auto numChannels = juce::jmax(totalNumInputChannels, totalNumOutputChannels);

    auto inoutBlock = juce::dsp::AudioBlock<float> (buffer).getSubsetChannelBlock (0, (size_t) numChannels);
    processorChain.process (juce::dsp::ProcessContextReplacing<float> (inoutBlock));
}

Have you verified this actually finds the wav file?

yes, basically renaming the file to something else just asserts. So it goes through when putting the correct name