commit 6c58e3d1ff7d0872cbefe8a666cebdedfa8036bd
parent 86d27d716c73954b0ead3eda8254c5050a00a578
Author: Jatin Chowdhury <[email protected]>
Date: Fri, 3 Sep 2021 22:21:55 -0700
Fix DC noise from flutter processor when bypassed
Diffstat:
2 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/Plugin/Source/Processors/Timing_Effects/WowFlutterProcessor.cpp b/Plugin/Source/Processors/Timing_Effects/WowFlutterProcessor.cpp
@@ -72,6 +72,10 @@ void WowFlutterProcessor::processBlock (AudioBuffer<float>& buffer, MidiBuffer&
if (bypass.processBlockIn (buffer, ! shouldTurnOff))
{
processWetBuffer (buffer);
+
+ for (int ch = 0; ch < buffer.getNumChannels(); ++ch)
+ dcBlocker[ch].processBlock (buffer.getWritePointer (ch), buffer.getNumSamples());
+
bypass.processBlockOut (buffer, ! shouldTurnOff);
}
else
@@ -79,10 +83,6 @@ void WowFlutterProcessor::processBlock (AudioBuffer<float>& buffer, MidiBuffer&
processBypassed (buffer);
}
- // dc block
- for (int ch = 0; ch < buffer.getNumChannels(); ++ch)
- dcBlocker[ch].processBlock (buffer.getWritePointer (ch), buffer.getNumSamples());
-
wowProcessor.plotBuffer (wowPlot);
flutterProcessor.plotBuffer (flutterPlot);
}
@@ -110,7 +110,7 @@ void WowFlutterProcessor::processWetBuffer (AudioBuffer<float>& buffer)
}
}
-void WowFlutterProcessor::processBypassed (AudioBuffer<float>& buffer)
+void WowFlutterProcessor::processBypassed (const AudioBuffer<float>& buffer)
{
for (int ch = 0; ch < buffer.getNumChannels(); ++ch)
{
diff --git a/Plugin/Source/Processors/Timing_Effects/WowFlutterProcessor.h b/Plugin/Source/Processors/Timing_Effects/WowFlutterProcessor.h
@@ -17,10 +17,10 @@ public:
void prepareToPlay (double sampleRate, int samplesPerBlock);
void processBlock (AudioBuffer<float>&, MidiBuffer&);
+private:
void processWetBuffer (AudioBuffer<float>& buffer);
- void processBypassed (AudioBuffer<float>& buffer);
+ void processBypassed (const AudioBuffer<float>& buffer);
-private:
std::atomic<float>* flutterOnOff = nullptr;
std::atomic<float>* flutterRate = nullptr;
std::atomic<float>* flutterDepth = nullptr;