12namespace tracktion {
inline namespace engine
32 static const char* getPluginName();
33 static inline const char* xmlTypeName =
"impulseResponse";
50 double sampleRateToStore,
72 bool needsConstantBufferSize()
override;
77 double getLatencySeconds()
override;
83 void reset()
override;
109 struct WetDryGain {
float wet, dry; };
110 static WetDryGain getWetDryLevels (
float mix)
112 const float dry = 1.0f - (mix * mix);
113 float temp = 1.0f - mix;
114 const float wet = 1.0f - (temp * temp);
118 void loadImpulseResponseFromState();
ImpulseResponsePlugin that loads an impulse response and applies it the audio stream.
bool loadImpulseResponse(const void *sourceData, size_t sourceDataSize)
Loads an impulse from binary audio file data i.e.
AutomatableParameter::Ptr gainParam
Parameter for the gain to apply.
AutomatableParameter::Ptr mixParam
Parameter for the mix control, 0.0 = dry, 1.0 = wet.
juce::CachedValue< juce::String > name
A name property.
~ImpulseResponsePlugin() override
Destructor.
void initialise(const PluginInitialisationInfo &) override
Gives the plugin a chance to set itself up before being played.
juce::String getSelectableDescription() override
Subclasses must return a description of what they are.
juce::String getName() const override
The name of the type, e.g.
void applyToBuffer(const PluginRenderContext &) override
Process the next block of data.
void deinitialise() override
Called after play stops to release resources.
AutomatableParameter::Ptr lowPassCutoffParam
Cutoff frequency for the low pass filter to applied after the IR.
AutomatableParameter::Ptr filterQParam
Parameter for the Q factor of the high pass and low pass filters.
juce::CachedValue< bool > normalise
Normalise the IR file when loading from the state.
AutomatableParameter::Ptr highPassCutoffParam
Cutoff frequency for the high pass filter to applied after the IR.
juce::CachedValue< bool > trimSilence
Trim silence from the IR file when loading from the state.
void reset() override
Should reset synth voices, tails, clear delay buffers, etc.
Passed into Plugins when they are being initialised, to give them useful contextual information that ...
The context passed to plugin render methods to provide it with buffers to fill.