We have an instrument plugin that generates audio at random intervals. However ableton takes the executive decision to turn off processBlock calls sometimes. Presumably to save CPU …
Are there any flags we can set that ensure this doesn’t happen and we always get our processBlock call called?
Totally understand why the hosts do it … silenceInProducesSilenceOut has been depreciated from JUCE, I’m not sure what it used to do under the hood or why it’s been removed tho.
If your plugin always generate sound without needing any input audio, you can add the category "Generator" as subCategories (for example use kFxGenerator) or you can return kInfiniteTail in the function IAudioProcessor::getTailSamples
@fabian
I think this flag should be reintroduced, and should choose the “correct” method for any wrapper/format to show the host that its processBlock should be called always.
For example for VST the flag should be automatically return kInfiniteTail in function IAudioProcessor::getTailSamples if its false, or does somebody has a better idea?
Yes I think you are right. I’ve re-added experimental silenceInProducesSilenceOut support on my private repo. Didn’t have much time to test it though so it would be good if you could give the different plug-in formats a proper spin.
Fabian - we’ve had some detailed support on this issue from the ableton sound team, so I think we have some custom ableton implementation for silenceInProducesSilenceOut support. Do you want to integrate this into your implementation? I’ll get it over to you in an e-mail.
For cubase the advice above is correct re: generator or tail length to infinite.
@jimc just found this thread after a user reporting a problem that sounds remarkably similar. Just to confirm: some DAWs stop calling processBlock() for “instrument” plugins when they are silent for a given period and returning std::numeric_limits<double>::max() from getTailLength() is the way to prevent this?
Yes - but only works on Ableton with the develop branch at the moment. We’ve had success with other DAWs I think - but haven’t tested all of them thoroughly.
Ah, what about Logic and FinalCutProX? I have an old proof of concept that I rescheduled because of this problem, and I want to get back to it now… Did that anybody check already?
Interesting. My user-reported issue is in Logic, but only one user so far. Symptoms are “playback not working after leaving and coming back”! My own log suggests this is because processBlock() stops getting called.
Is there any way to conclusively prove “stops getting called” without setting and testing a flag from the message thread?