Bypass
-
- KVRer
- Topic Starter
- 19 posts since 25 May, 2014
I was wondering how to make a simple Bypass button for a effect, when I click the button it will bypass the entire plugin. I know its probably a simple question but I am new to DSP!!
Cheers,
Aztek:)
Cheers,
Aztek:)
-
- KVRian
- 621 posts since 28 Feb, 2011 from Sweden
do you already have a plugin working? Bypass would be just simply don't do any handling of the audio data.
David Guda gudaaudio.com
-
- KVRer
- Topic Starter
- 19 posts since 25 May, 2014
Yes just a simple Graphic EQ, ok but still need an idea on how to do it.
I found this code in the Steinberg SDK,
//-------------------------------------------------------------------------------------------------------
/// \name State Transitions
//-------------------------------------------------------------------------------------------------------
//@{
virtual void open () {} ///< Called when plug-in is initialized
virtual void close () {} ///< Called when plug-in will be released
virtual void suspend () {} ///< Called when plug-in is switched to off
virtual void resume () {} ///< Called when plug-in is switched to on
Would this be what i was looking for?
I found this code in the Steinberg SDK,
//-------------------------------------------------------------------------------------------------------
/// \name State Transitions
//-------------------------------------------------------------------------------------------------------
//@{
virtual void open () {} ///< Called when plug-in is initialized
virtual void close () {} ///< Called when plug-in will be released
virtual void suspend () {} ///< Called when plug-in is switched to off
virtual void resume () {} ///< Called when plug-in is switched to on
Would this be what i was looking for?
-
- KVRian
- 573 posts since 1 Jan, 2013 from Denmark
No, those are events called by the host. You override them to react to the changes.
If it is your own plugin you want to suspend.. Well, you create a button that toggles a boolean. Inside your processor method, if the boolean is set, you merely copy the contents of the inputs into the outputs (effectively bypassing). If not, run your active code.
If it is your own plugin you want to suspend.. Well, you create a button that toggles a boolean. Inside your processor method, if the boolean is set, you merely copy the contents of the inputs into the outputs (effectively bypassing). If not, run your active code.
-
- KVRist
- 54 posts since 6 Mar, 2009 from LA
In your ProcessBlock you can do something like this...
Code: Select all
if(numChannels < 2 || MasterBypass)
{} // Passthrough
else
{ // do processing
float* leftData = buffer0;
float* rightData = buffer1
for(i=0; i<numSamples; i++)
engine(&leftData[i],&rightData[i]);
}
SOR8, Free AAX/RTAS/VST/AU
Classic Compressor plugin.
Based on acclaimed 8X compressor.
http://www.cocellproductions.com/Pensad ... lugin.html
Classic Compressor plugin.
Based on acclaimed 8X compressor.
http://www.cocellproductions.com/Pensad ... lugin.html
-
- KVRer
- Topic Starter
- 19 posts since 25 May, 2014
Cheers that worked and was nice and quick
-
- KVRist
- 54 posts since 6 Mar, 2009 from LA
No Problem
SOR8, Free AAX/RTAS/VST/AU
Classic Compressor plugin.
Based on acclaimed 8X compressor.
http://www.cocellproductions.com/Pensad ... lugin.html
Classic Compressor plugin.
Based on acclaimed 8X compressor.
http://www.cocellproductions.com/Pensad ... lugin.html