AudioProcessorGraph::reset()?


#1

Hi Jules,

With the recent implementation of reset() to VSTPluginInstance, I would like to request the addition of reset to the graph itself.

The following is what I’m currently doing in my slightly modified version of the graph:

void reset()
{
    juce::ScopedLock lock (renderLock);

    for (int i = 0; i < getNumNodes(); ++i)
    {
        nodes[i]->getProcessor()->reset();
    }
}

Also, I’ve a question; why does the graph use an internal lock (“renderLock”), and not the AudioProcessor’s callbackLock instead? (Not that I’m trying to achieve anything in particular with this - simply curious)


#2

Good idea, I’ll add a reset() method.

And TBH I can’t really remember why it’s got its own lock… I’ll have a think, and may replace it with the normal callbackLock. Thanks for the heads-up!