Why Does iirFilter::processSamples() Work After addNextBlock() but not Within?

Say you want to be able to add an IIRFilter to the buffer produced by the SamplerPlugin by some means (tracktion_SamplerPlugin.cpp). You might find that if you alter the member function SampledNote::addNextBlock to apply the filter to each block of samples the effects are not as intended (in my case the resulting audio clip always sounds very low pitch for a handful of samples and then is silent). However you would find that if you call IIRFilterBase::processSamples just after the call to addNextBlock within SamplerPlugin::appyToBuffer that the results are as expected.

Why might this be? I’m grateful for any insights people can provide about the inner workings of tracktion. Thanks!