Skip to content

Commit

Permalink
Fixed MIDI issue in DAW
Browse files Browse the repository at this point in the history
  • Loading branch information
timothyschoen committed Dec 23, 2023
1 parent 08feed8 commit e55390c
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions Source/PluginProcessor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -699,7 +699,7 @@ void PluginProcessor::processVariable(dsp::AudioBlock<float> buffer, MidiBuffer&

inputFifo->writeAudioAndMidi(buffer, midiMessages);

audioAdvancement = 0;
audioAdvancement = 0; // Always has to be 0 if we use the AudioMidiFifo!

while (inputFifo->getNumSamplesAvailable() >= pdBlockSize) {
midiBufferIn.clear();
Expand Down Expand Up @@ -744,7 +744,6 @@ void PluginProcessor::processVariable(dsp::AudioBlock<float> buffer, MidiBuffer&
}

outputFifo->writeAudioAndMidi(audioBufferOut, midiBufferOut);
audioAdvancement += pdBlockSize;
}

// When the amount of samples availabble is larger than (2 * pdBlockSize) - buffer.getNumSamples(), we know for sure that we'll have enough samples to process the next block as well
Expand Down

0 comments on commit e55390c

Please sign in to comment.