From 6a93208f0611dcfd8c4cbf7db19a09ba4dab4069 Mon Sep 17 00:00:00 2001 From: nofish Date: Mon, 4 Jul 2022 22:28:57 +0200 Subject: [PATCH] fix compiler warnings --- Source/PluginProcessor.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Source/PluginProcessor.cpp b/Source/PluginProcessor.cpp index 31c4716..80da18f 100644 --- a/Source/PluginProcessor.cpp +++ b/Source/PluginProcessor.cpp @@ -164,10 +164,10 @@ void AudioPluginAudioProcessor::processBlock (juce::AudioBuffer& buffer, auto audioBlock = juce::dsp::AudioBlock (buffer).getSubsetChannelBlock (0, (size_t) numChannels); auto context = juce::dsp::ProcessContextReplacing (audioBlock); - const auto& input = context.getInputBlock(); + const auto& inputBlock = context.getInputBlock(); const auto& output = context.getOutputBlock(); - mixer.pushDrySamples (input); + mixer.pushDrySamples (inputBlock); // This is the place where you'd normally do the guts of your plugin's // audio processing... @@ -177,10 +177,10 @@ void AudioPluginAudioProcessor::processBlock (juce::AudioBuffer& buffer, // interleaved by keeping the same state. for (int channel = 0; channel < numChannels; ++channel) { - auto* samplesIn = input.getChannelPointer (channel); + auto* samplesIn = inputBlock.getChannelPointer (channel); auto* samplesOut = output.getChannelPointer (channel); - for (size_t sample = 0; sample < input.getNumSamples(); ++sample) + for (size_t sample = 0; sample < inputBlock.getNumSamples(); ++sample) { auto input = samplesIn[sample]; @@ -244,7 +244,7 @@ juce::AudioProcessor* JUCE_CALLTYPE createPluginFilter() void AudioPluginAudioProcessor::parameterChanged (const String& parameterID, float newValue) { if (parameterID == "DELAY") - delayValue = newValue / 1000.0 * getSampleRate(); + delayValue = newValue / 1000.0 * (float)getSampleRate(); if (parameterID == "MIX") mixer.setWetMixProportion (newValue);