Remove unused codes

This commit is contained in:
Takeshi Yokemura
2021-05-21 21:34:23 +09:00
parent 97aadde9ab
commit 7efbf2a409
3 changed files with 5 additions and 148 deletions

View File

@ -293,67 +293,13 @@ bool Magical8bitPlug2AudioProcessor::isBusesLayoutSupported (const BusesLayout&
void Magical8bitPlug2AudioProcessor::processBlock (AudioBuffer<float>& buffer, MidiBuffer& midiMessages)
{
synth.renderNextBlock (buffer, midiMessages, 0, buffer.getNumSamples()); // [5]
/*
buffer.clear();
MidiBuffer processedMidi;
int time;
MidiMessage m;
for (MidiBuffer::Iterator i (midiMessages); i.getNextEvent (m, time);)
{
if (m.isNoteOn())
{
uint8 newVel = (uint8)noteOnVel;
m = MidiMessage::noteOn(m.getChannel(), m.getNoteNumber(), newVel);
}
else if (m.isNoteOff())
{
}
else if (m.isAftertouch())
{
}
else if (m.isPitchWheel())
{
}
processedMidi.addEvent (m, time);
}
midiMessages.swapWith (processedMidi);
ScopedNoDenormals noDenormals;
auto totalNumInputChannels = getTotalNumInputChannels();
auto totalNumOutputChannels = getTotalNumOutputChannels();
// In case we have more outputs than inputs, this code clears any output
// channels that didn't contain input data, (because these aren't
// guaranteed to be empty - they may contain garbage).
// This is here to avoid people getting screaming feedback
// when they first compile a plugin, but obviously you don't need to keep
// this code if your algorithm always overwrites all the output channels.
for (auto i = totalNumInputChannels; i < totalNumOutputChannels; ++i)
buffer.clear (i, 0, buffer.getNumSamples());
// This is the place where you'd normally do the guts of your plugin's
// audio processing...
// Make sure to reset the state if your inner loop is processing
// the samples and the outer loop is handling the channels.
// Alternatively, you can process the samples with the channels
// interleaved by keeping the same state.
for (int channel = 0; channel < totalNumInputChannels; ++channel)
{
auto* channelData = buffer.getWritePointer (channel);
// ..do something to the data...
}
*/
synth.renderNextBlock (buffer, midiMessages, 0, buffer.getNumSamples());
}
//==============================================================================
bool Magical8bitPlug2AudioProcessor::hasEditor() const
{
return true; // (change this to false if you choose to not supply an editor)
return true;
}
AudioProcessorEditor* Magical8bitPlug2AudioProcessor::createEditor()