|
|
@@ -886,7 +886,7 @@ AudioProcessorGraph::Node::Node (const uint32 nodeId_, AudioProcessor* const pro |
|
|
|
processor (processor_),
|
|
|
|
isPrepared (false)
|
|
|
|
{
|
|
|
|
jassert (processor_ != nullptr);
|
|
|
|
jassert (processor != nullptr);
|
|
|
|
}
|
|
|
|
|
|
|
|
void AudioProcessorGraph::Node::prepare (const double sampleRate, const int blockSize,
|
|
|
@@ -1167,7 +1167,7 @@ void AudioProcessorGraph::clearRenderingSequence() |
|
|
|
Array<void*> oldOps;
|
|
|
|
|
|
|
|
{
|
|
|
|
const ScopedLock sl (renderLock);
|
|
|
|
const ScopedLock sl (getCallbackLock());
|
|
|
|
renderingOps.swapWithArray (oldOps);
|
|
|
|
}
|
|
|
|
|
|
|
@@ -1231,7 +1231,7 @@ void AudioProcessorGraph::buildRenderingSequence() |
|
|
|
|
|
|
|
{
|
|
|
|
// swap over to the new rendering sequence..
|
|
|
|
const ScopedLock sl (renderLock);
|
|
|
|
const ScopedLock sl (getCallbackLock());
|
|
|
|
|
|
|
|
renderingBuffers.setSize (numRenderingBuffersNeeded, getBlockSize());
|
|
|
|
renderingBuffers.clear();
|
|
|
@@ -1280,12 +1280,18 @@ void AudioProcessorGraph::releaseResources() |
|
|
|
currentMidiOutputBuffer.clear();
|
|
|
|
}
|
|
|
|
|
|
|
|
void AudioProcessorGraph::reset()
|
|
|
|
{
|
|
|
|
const ScopedLock sl (getCallbackLock());
|
|
|
|
|
|
|
|
for (int i = 0; i < nodes.size(); ++i)
|
|
|
|
nodes.getUnchecked(i)->getProcessor()->reset();
|
|
|
|
}
|
|
|
|
|
|
|
|
void AudioProcessorGraph::processBlock (AudioSampleBuffer& buffer, MidiBuffer& midiMessages)
|
|
|
|
{
|
|
|
|
const int numSamples = buffer.getNumSamples();
|
|
|
|
|
|
|
|
const ScopedLock sl (renderLock);
|
|
|
|
|
|
|
|
currentAudioInputBuffer = &buffer;
|
|
|
|
currentAudioOutputBuffer.setSize (jmax (1, buffer.getNumChannels()), numSamples);
|
|
|
|
currentAudioOutputBuffer.clear();
|
|
|
|