Audacity 3.2.0
Reverb.cpp
Go to the documentation of this file.
1/**********************************************************************
2
3 Audacity: A Digital Audio Editor
4 Audacity(R) is copyright (c) 1999-2013 Audacity Team.
5 License: GPL v2 or later. See License.txt.
6
7 Reverb.cpp
8 Rob Sykes, Vaughan Johnson
9
10******************************************************************//*******************************************************************/
16#include "Reverb.h"
17#include "EffectEditor.h"
18#include "LoadEffects.h"
19
20#include <wx/arrstr.h>
21#include <wx/checkbox.h>
22#include <wx/slider.h>
23#include <wx/spinctrl.h>
24
25#include "Prefs.h"
26#include "ShuttleGui.h"
27#include "../widgets/valnum.h"
28
29#include "Reverb_libSoX.h"
30
31
33{
37 > parameters;
38 return parameters;
39}
40
41static const struct
42{
45}
47{
48 // Room Pre Hf Tone Tone Wet Dry Stereo Wet
49 // Name Size, Delay, Reverb, Damping, Low, High, Gain, Gain, Width, Only
50 { XO("Vocal I" ), { 70, 20, 40, 99, 100, 50, -12, 0, 70, false } },
51 { XO("Vocal II"), { 50, 0, 50, 99, 50, 100, -1, -1, 70, false } },
52 { XO("Bathroom"), { 16, 8, 80, 0, 0, 100, -6, 0, 100, false } },
53 { XO("Small Room Bright"), { 30, 10, 50, 50, 50, 100, -1, -1, 100, false } },
54 { XO("Small Room Dark"), { 30, 10, 50, 50, 100, 0, -1, -1, 100, false } },
55 { XO("Medium Room"), { 75, 10, 40, 50, 100, 70, -1, -1, 70, false } },
56 { XO("Large Room"), { 85, 10, 40, 50, 100, 80, 0, -6, 90, false } },
57 { XO("Church Hall"), { 90, 32, 60, 50, 100, 50, 0, -12, 100, false } },
58 { XO("Cathedral"), { 90, 16, 90, 50, 100, 0, 0, -20, 100, false } },
59};
60
62{
64 float *dry;
65 float *wet[2];
66};
67
69{
72 {
74 }
75};
76
78{
79 unsigned mNumChans{};
80 std::unique_ptr<Reverb_priv_ex[]> mP{};
81};
82
83
84//
85// EffectReverb
86//
87
89{ XO("Reverb") };
90
92
93
96{
97 Editor(const EffectUIServices& services,
99 ) : EffectEditor{ services, access }
101 {}
102 virtual ~Editor() = default;
103
104 bool ValidateUI() override;
105 bool UpdateUI() override;
106
108
110
111 bool mProcessingEvent = false;
112
113#define SpinSlider(n) \
114 wxSpinCtrl *m ## n ## T; \
115 wxSlider *m ## n ## S;
116
126
127#undef SpinSlider
128
129 wxCheckBox* mWetOnlyC;
130
131
132#define SpinSliderHandlers(n) \
133 void On ## n ## Slider(wxCommandEvent & evt); \
134 void On ## n ## Text(wxCommandEvent & evt);
135
145
146#undef SpinSliderHandlers
147
148 void OnCheckbox(wxCommandEvent &evt);
149
150};
151
152
154{
155 auto& rs = mSettings;
156
157 rs.mRoomSize = mRoomSizeS->GetValue();
158 rs.mPreDelay = mPreDelayS->GetValue();
159 rs.mReverberance = mReverberanceS->GetValue();
160 rs.mHfDamping = mHfDampingS->GetValue();
161 rs.mToneLow = mToneLowS->GetValue();
162 rs.mToneHigh = mToneHighS->GetValue();
163 rs.mWetGain = mWetGainS->GetValue();
164 rs.mDryGain = mDryGainS->GetValue();
165 rs.mStereoWidth = mStereoWidthS->GetValue();
166 rs.mWetOnly = mWetOnlyC->GetValue();
167
169 (
170 [this](EffectSettings& settings)
171 {
172 // pass back the modified settings to the MessageBuffer
173
175 return nullptr;
176 }
177 );
178
179 return true;
180}
181
182
186{
187 explicit Instance(const PerTrackEffect& effect)
188 : PerTrackEffect::Instance{ effect }
189 {}
190
192 ChannelNames chanMap) override;
193
195 const float* const* inBlock, float* const* outBlock, size_t blockLen) override;
196
197 bool ProcessFinalize(void) noexcept override;
198
199 // Realtime section
200
202 {
203 SetBlockSize(512);
204 mSlaves.clear();
205
208
209 return true;
210 }
211
213 unsigned numChannels, float sampleRate) override
214 {
216
217 // The notion of ChannelNames is unavailable here,
218 // so we'll have to force the stereo init, if this is the case
219 //
221 slave.mState, /*ChannelNames=*/nullptr, /*forceStereo=*/(numChannels == 2));
222
223 mSlaves.push_back( std::move(slave) );
224 return true;
225 }
226
227 bool RealtimeFinalize(EffectSettings& settings) noexcept override
228 {
229 mSlaves.clear();
230 return true;
231 }
232
234 const float* const* inbuf, float* const* outbuf, size_t numSamples) override
235 {
236
237 const auto& incomingSettings = GetSettings(settings);
238 if ( !(incomingSettings == mLastAppliedSettings) )
239 {
240 const bool onlySimpleOnes = OnlySimpleParametersChanged(incomingSettings, mLastAppliedSettings);
241
242 for (auto& slave : mSlaves)
243 {
244 for (unsigned int i = 0; i < slave.mState.mNumChans; i++)
245 {
246 auto& reverbCore = slave.mState.mP[i].reverb;
247 const auto& is = incomingSettings;
248
249 if (onlySimpleOnes)
250 {
252 is.mWetGain, is.mReverberance, is.mHfDamping, is.mToneLow, is.mToneHigh);
253 }
254 else
255 {
256 // One of the non-simple parameters changed, so we need to do a full reinit
257 reverb_init(&reverbCore, mLastSampleRate,
258 is.mWetGain, is.mRoomSize, is.mReverberance, is.mHfDamping,
259 is.mPreDelay, is.mStereoWidth, is.mToneLow, is.mToneHigh );
260 }
261 }
262 }
263
264 mLastAppliedSettings = incomingSettings;
265 }
266
267
268 if (group >= mSlaves.size())
269 return 0;
270 return InstanceProcess(settings, mSlaves[group].mState, inbuf, outbuf, numSamples);
271 }
272
273
274 bool RealtimeSuspend() override
275 {
276 for (auto& slave : mSlaves)
277 {
278 for (unsigned int i = 0; i < slave.mState.mNumChans; i++)
279 {
280 reverb_clear( &(slave.mState.mP[i].reverb) );
281 }
282 }
283
284 return true;
285 }
286
287
288 unsigned GetAudioOutCount() const override
289 {
290 return mChannels;
291 }
292
293 unsigned GetAudioInCount() const override
294 {
295 return mChannels;
296 }
297
299 EffectReverbState& data, ChannelNames chanMap, bool forceStereo);
300
302 const float* const* inBlock, float* const* outBlock, size_t blockLen);
303
305 std::vector<EffectReverb::Instance> mSlaves;
306
307 unsigned mChannels{ 2 };
308
310 double mLastSampleRate{ 0 };
311};
312
313
314
315std::shared_ptr<EffectInstance>
317{
318 return std::make_shared<Instance>(*this);
319}
320
321
323{
325}
326
328{
329}
330
331// ComponentInterface implementation
332
334{
335 return Symbol;
336}
337
339{
340 return XO("Adds ambience or a \"hall effect\"");
341}
342
344{
345 return L"Reverb";
346}
347
348// EffectDefinitionInterface implementation
349
351{
352 return EffectTypeProcess;
353}
354
356{
358}
359
360static size_t BLOCK = 16384;
361
363 double sampleRate, ChannelNames chanMap)
364{
365 // For descructive processing, fix the number of channels, maybe as 1 not 2
366 auto& rs = GetSettings(settings);
367 mChannels = rs.mStereoWidth ? 2 : 1;
368
369 return InstanceInit(settings,
370 sampleRate, mState, chanMap, /* forceStereo = */ false);
371}
372
373
375 double sampleRate, EffectReverbState& state,
376 ChannelNames chanMap, bool forceStereo)
377{
378 auto& rs = GetSettings(settings);
379
380 bool isStereo = false;
381 state.mNumChans = 1;
382 if ( (chanMap && chanMap[0] != ChannelNameEOL && chanMap[1] == ChannelNameFrontRight)
383 || forceStereo )
384 {
385 isStereo = true;
386 state.mNumChans = 2;
387 }
388
389 state.mP = std::make_unique<Reverb_priv_ex[]>(state.mNumChans);
390
391 for (unsigned int i = 0; i < state.mNumChans; i++)
392 {
393 reverb_create(&state.mP[i].reverb,
395 rs.mWetGain,
396 rs.mRoomSize,
397 rs.mReverberance,
398 rs.mHfDamping,
399 rs.mPreDelay,
400 rs.mStereoWidth * (isStereo ? 1 : 0),
401 rs.mToneLow,
402 rs.mToneHigh,
403 BLOCK,
404 state.mP[i].wet);
405 }
406
407 return true;
408}
409
411{
412 return true;
413}
414
416 const float* const* inBlock, float* const* outBlock, size_t blockLen)
417{
418 return InstanceProcess(settings, mState, inBlock, outBlock, blockLen);
419}
420
422 const float* const* inBlock, float* const* outBlock, size_t blockLen)
423{
424 auto& rs = GetSettings(settings);
425
426 const float *ichans[2] = {NULL, NULL};
427 float *ochans[2] = {NULL, NULL};
428
429 for (unsigned int c = 0; c < state.mNumChans; c++)
430 {
431 ichans[c] = inBlock[c];
432 ochans[c] = outBlock[c];
433 }
434
435 float const dryMult = rs.mWetOnly ? 0 : dB_to_linear(rs.mDryGain);
436
437 auto remaining = blockLen;
438
439 while (remaining)
440 {
441 auto len = std::min(remaining, decltype(remaining)(BLOCK));
442 for (unsigned int c = 0; c < state.mNumChans; c++)
443 {
444 // Write the input samples to the reverb fifo. Returned value is the address of the
445 // fifo buffer which contains a copy of the input samples.
446 state.mP[c].dry = (float *) fifo_write(&state.mP[c].reverb.input_fifo, len, ichans[c]);
447 reverb_process(&state.mP[c].reverb, len);
448 }
449
450 if (state.mNumChans == 2)
451 {
452 for (decltype(len) i = 0; i < len; i++)
453 {
454 for (int w = 0; w < 2; w++)
455 {
456 ochans[w][i] = dryMult *
457 state.mP[w].dry[i] +
458 0.5 *
459 (state.mP[0].wet[w][i] + state.mP[1].wet[w][i]);
460 }
461 }
462 }
463 else
464 {
465 for (decltype(len) i = 0; i < len; i++)
466 {
467 ochans[0][i] = dryMult *
468 state.mP[0].dry[i] +
469 state.mP[0].wet[0][i];
470 }
471 }
472
473 remaining -= len;
474
475 for (unsigned int c = 0; c < state.mNumChans; c++)
476 {
477 ichans[c] += len;
478 ochans[c] += len;
479 }
480 }
481
482 return blockLen;
483}
484
486{
488
489 for (size_t i = 0; i < WXSIZEOF(FactoryPresets); i++)
490 {
491 names.push_back( FactoryPresets[i].name.Translation() );
492 }
493
494 return names;
495}
496
497
500{
501 if (id < 0 || id >= (int) WXSIZEOF(FactoryPresets))
502 {
503 return {};
504 }
505
507
508 return { nullptr };
509}
510
511// Effect implementation
512std::unique_ptr<EffectEditor> EffectReverb::MakeEditor(
514 const EffectOutputs *) const
515{
516 auto& settings = access.Get();
517 auto& myEffSettings = GetSettings(settings);
518
519 auto result = std::make_unique<Editor>(*this, access, myEffSettings);
520 result->PopulateOrExchange(S);
521 return result;
522}
523
524
526{
527 S.AddSpace(0, 5);
528
529 S.StartMultiColumn(3, wxEXPAND);
530 {
531 S.SetStretchyCol(2);
532
533#define SpinSlider(n, p) \
534 m ## n ## T = S.AddSpinCtrl( p, n.def, n.max, n.min); \
535 BindTo(*m ## n ## T, wxEVT_SPINCTRL, &Editor::On ## n ## Text);\
536 \
537 m ## n ## S = S.Style(wxSL_HORIZONTAL).AddSlider( {}, n.def, n.max, n.min); \
538 BindTo(*m ## n ## S, wxEVT_SLIDER, &Editor::On ## n ## Slider);
539
540 SpinSlider(RoomSize, XXO("&Room Size (%):"))
541 SpinSlider(PreDelay, XXO("&Pre-delay (ms):"))
542 SpinSlider(Reverberance, XXO("Rever&berance (%):"))
543 SpinSlider(HfDamping, XXO("Da&mping (%):"))
544 SpinSlider(ToneLow, XXO("Tone &Low (%):"))
545 SpinSlider(ToneHigh, XXO("Tone &High (%):"))
546 SpinSlider(WetGain, XXO("Wet &Gain (dB):"))
547 SpinSlider(DryGain, XXO("Dr&y Gain (dB):"))
548 SpinSlider(StereoWidth, XXO("Stereo Wid&th (%):"))
549
550#undef SpinSlider
551
552 }
553 S.EndMultiColumn();
554
555 S.StartHorizontalLay(wxCENTER, false);
556 {
557 mWetOnlyC =
558 S.AddCheckBox(XXO("Wet O&nly"), WetOnly.def);
559 BindTo(*mWetOnlyC, wxEVT_CHECKBOX, &Editor::OnCheckbox);
560 }
561 S.EndHorizontalLay();
562
563}
564
566{
567 // get the settings from the MessageBuffer and write them to our local copy
568 mSettings = GetSettings(mAccess.Get());
569
570 auto& rs = mSettings;
571
572#define SetSpinSlider(n) \
573 m ## n ## S->SetValue((int) rs.m ## n); \
574 m ## n ## T->SetValue(wxString::Format(wxT("%d"), (int) rs.m ## n));
575
585
586#undef SetSpinSlider
587
588 mWetOnlyC->SetValue((int) rs.mWetOnly);
589
590 return true;
591}
592
593
594#define SpinSliderHandlers(n) \
595 void EffectReverb::Editor::On ## n ## Slider(wxCommandEvent & evt) \
596 { \
597 if (mProcessingEvent) return; \
598 mProcessingEvent = true; \
599 m ## n ## T->SetValue(wxString::Format(wxT("%d"), evt.GetInt())); \
600 mProcessingEvent = false; \
601 ValidateUI(); \
602 Publish(EffectSettingChanged{}); \
603 } \
604 void EffectReverb::Editor::On ## n ## Text(wxCommandEvent & evt) \
605 { \
606 if (mProcessingEvent) return; \
607 mProcessingEvent = true; \
608 m ## n ## S->SetValue(std::clamp<long>(evt.GetInt(), n.min, n.max)); \
609 mProcessingEvent = false; \
610 ValidateUI(); \
611 Publish(EffectSettingChanged{}); \
612 }
613
623
624void EffectReverb::Editor::OnCheckbox(wxCommandEvent &evt)
625{
626 ValidateUI();
627 Publish(EffectSettingChanged{});
628}
629
630#undef SpinSliderHandlers
631
633{
634 // With C++20, all of this can be replaced by =default
635 return (a.mRoomSize == b.mRoomSize)
636 && (a.mPreDelay == b.mPreDelay)
637 && (a.mReverberance == b.mReverberance)
638 && (a.mHfDamping == b.mHfDamping)
639 && (a.mToneLow == b.mToneLow)
640 && (a.mToneHigh == b.mToneHigh)
641 && (a.mWetGain == b.mWetGain)
642 && (a.mDryGain == b.mDryGain)
643 && (a.mStereoWidth == b.mStereoWidth)
644 && (a.mWetOnly == b.mWetOnly);
645}
646
648{
649 // A "simple" reverb parameter is one that when changed, does not require the
650 // reverb allpass/comb filters to be reset. This distinction enables us to
651 // code things so that the user can keep hearing the processed sound while
652 // they tweak one of the simple parameters.
653
654 const bool oneSimpleParameterChanged =
655
657 || (a.mHfDamping != b.mHfDamping)
658 || (a.mToneLow != b.mToneLow)
659 || (a.mToneHigh != b.mToneHigh)
660 || (a.mWetGain != b.mWetGain);
661
662
663 const bool allNonSimpleParametersStayedTheSame =
664
665 (a.mRoomSize == b.mRoomSize)
666 && (a.mPreDelay == b.mPreDelay)
667 && (a.mStereoWidth == b.mStereoWidth);
668
669 return oneSimpleParameterChanged && allNonSimpleParametersStayedTheSame;
670}
int min(int a, int b)
struct State mState
EffectType
@ EffectTypeProcess
ChannelName
@ ChannelNameEOL
@ ChannelNameFrontRight
std::optional< std::unique_ptr< EffectSettingsAccess::Message > > OptionalMessage
XO("Cut/Copy/Paste")
XXO("&Cut/Copy/Paste Toolbar")
std::vector< RegistryPath > RegistryPaths
Definition: Identifier.h:219
#define SetSpinSlider(n)
static size_t BLOCK
Definition: Reverb.cpp:360
#define SpinSliderHandlers(n)
Definition: Reverb.cpp:594
EffectReverbSettings preset
Definition: Reverb.cpp:44
bool operator==(const EffectReverbSettings &a, const EffectReverbSettings &b)
Definition: Reverb.cpp:632
bool OnlySimpleParametersChanged(const EffectReverbSettings &a, const EffectReverbSettings &b)
Definition: Reverb.cpp:647
const TranslatableString name
Definition: Reverb.cpp:43
#define SpinSlider(n)
Definition: Reverb.cpp:113
static const struct @30 FactoryPresets[]
static void reverb_init(reverb_t *p, double sample_rate_Hz, double wet_gain_dB, double room_scale, double reverberance, double hf_damping, double pre_delay_ms, double stereo_depth, double tone_low, double tone_high)
#define dB_to_linear(x)
Definition: Reverb_libSoX.h:27
static void reverb_set_simple_params(reverb_t *p, double sample_rate_Hz, double wet_gain_dB, double reverberance, double hf_damping, double tone_low, double tone_high)
static void reverb_process(reverb_t *p, size_t length)
static void reverb_delete(reverb_t *p)
static void reverb_clear(reverb_t *p)
static void reverb_create(reverb_t *p, double sample_rate_Hz, double wet_gain_dB, double room_scale, double reverberance, double hf_damping, double pre_delay_ms, double stereo_depth, double tone_low, double tone_high, size_t buffer_size, float **out)
static void * fifo_write(fifo_t *f, FIFO_SIZE_T n, void const *data)
Definition: Reverb_libSoX.h:81
static TranslatableStrings names
Definition: TagsEditor.cpp:153
#define S(N)
Definition: ToChars.cpp:64
static Settings & settings()
Definition: TrackInfo.cpp:47
int id
bool ValidateUI(const EffectPlugin &context, EffectSettings &) const override
Generates EffectParameterMethods overrides from variadic template arguments.
ComponentInterfaceSymbol pairs a persistent string identifier used internally with an optional,...
void SetLinearEffectFlag(bool linearEffectFlag)
Definition: EffectBase.cpp:210
RealtimeSince
In which versions of Audacity was an effect realtime capable?
EffectSettingsAccess & mAccess
Definition: EffectEditor.h:92
Performs effect computation.
Inherit to add a state variable to an EffectInstance subclass.
size_t SetBlockSize(size_t maxBlockSize) override
Hold values to send to effect output meters.
Interface for manipulations of an Effect's settings.
const EffectParameterMethods & Parameters() const override
Definition: Reverb.cpp:32
RealtimeSince RealtimeSupport() const override
Since which version of Audacity has the effect supported realtime?
Definition: Reverb.cpp:355
virtual ~EffectReverb()
Definition: Reverb.cpp:327
OptionalMessage LoadFactoryPreset(int id, EffectSettings &settings) const override
Definition: Reverb.cpp:499
EffectType GetType() const override
Type determines how it behaves.
Definition: Reverb.cpp:350
static constexpr EffectParameter ToneLow
Definition: Reverb.h:111
static constexpr EffectParameter PreDelay
Definition: Reverb.h:102
std::unique_ptr< EffectEditor > MakeEditor(ShuttleGui &S, EffectInstance &instance, EffectSettingsAccess &access, const EffectOutputs *pOutputs) const override
Called only from PopulateUI, to add controls to effect panel.
Definition: Reverb.cpp:512
static constexpr EffectParameter RoomSize
Definition: Reverb.h:99
ComponentInterfaceSymbol GetSymbol() const override
Definition: Reverb.cpp:333
static constexpr EffectParameter StereoWidth
Definition: Reverb.h:123
static const ComponentInterfaceSymbol Symbol
Definition: Reverb.h:58
static constexpr EffectParameter Reverberance
Definition: Reverb.h:105
static constexpr EffectParameter WetGain
Definition: Reverb.h:117
static constexpr EffectParameter HfDamping
Definition: Reverb.h:108
static constexpr EffectParameter ToneHigh
Definition: Reverb.h:114
static constexpr EffectParameter WetOnly
Definition: Reverb.h:126
TranslatableString GetDescription() const override
Definition: Reverb.cpp:338
ManualPageID ManualPage() const override
Name of a page in the Audacity alpha manual, default is empty.
Definition: Reverb.cpp:343
static constexpr EffectParameter DryGain
Definition: Reverb.h:120
std::shared_ptr< EffectInstance > MakeInstance() const override
Make an object maintaining short-term state of an Effect.
Definition: Reverb.cpp:316
RegistryPaths GetFactoryPresets() const override
Report names of factory presets.
Definition: Reverb.cpp:485
void ModifySettings(Function &&function)
Do a correct read-modify-write of settings.
virtual const EffectSettings & Get()=0
static EffectReverbSettings & GetSettings(EffectSettings &settings)
Assume settings originated from MakeSettings() and copies thereof.
Definition: Effect.h:166
const PerTrackEffect & mProcessor
Base class for many of the effects in Audacity.
Derived from ShuttleGuiBase, an Audacity specific class for shuttling data to and from GUI.
Definition: ShuttleGui.h:640
Holds a msgid for the translation catalog; may also bind format arguments.
wxString Translation() const
BuiltinEffectsModule::Registration< EffectReverb > reg
Definition: Reverb.cpp:91
const Type def
Default value.
SpinSlider(RoomSize) SpinSlider(PreDelay) SpinSlider(Reverberance) SpinSlider(HfDamping) SpinSlider(ToneLow) SpinSlider(ToneHigh) SpinSlider(WetGain) SpinSlider(DryGain) SpinSlider(StereoWidth) wxCheckBox *mWetOnlyC
bool UpdateUI() override
Update appearance of the panel for changes in settings.
Definition: Reverb.cpp:565
EffectReverbSettings mSettings
Definition: Reverb.cpp:109
bool ValidateUI() override
Get settings data from the panel; may make error dialogs and return false.
Definition: Reverb.cpp:153
Editor(const EffectUIServices &services, EffectSettingsAccess &access, const EffectReverbSettings &settings)
Definition: Reverb.cpp:97
SpinSliderHandlers(RoomSize) SpinSliderHandlers(PreDelay) SpinSliderHandlers(Reverberance) SpinSliderHandlers(HfDamping) SpinSliderHandlers(ToneLow) SpinSliderHandlers(ToneHigh) SpinSliderHandlers(WetGain) SpinSliderHandlers(DryGain) SpinSliderHandlers(StereoWidth) void OnCheckbox(wxCommandEvent &evt)
void PopulateOrExchange(ShuttleGui &S)
Definition: Reverb.cpp:525
virtual ~Editor()=default
unsigned GetAudioOutCount() const override
How many output buffers to allocate at once.
Definition: Reverb.cpp:288
bool ProcessInitialize(EffectSettings &settings, double sampleRate, ChannelNames chanMap) override
Definition: Reverb.cpp:362
size_t RealtimeProcess(size_t group, EffectSettings &settings, const float *const *inbuf, float *const *outbuf, size_t numSamples) override
Definition: Reverb.cpp:233
unsigned GetAudioInCount() const override
How many input buffers to allocate at once.
Definition: Reverb.cpp:293
EffectReverbSettings mLastAppliedSettings
Definition: Reverb.cpp:309
bool InstanceInit(EffectSettings &settings, double sampleRate, EffectReverbState &data, ChannelNames chanMap, bool forceStereo)
Definition: Reverb.cpp:374
size_t ProcessBlock(EffectSettings &settings, const float *const *inBlock, float *const *outBlock, size_t blockLen) override
Called for destructive effect computation.
Definition: Reverb.cpp:415
size_t InstanceProcess(EffectSettings &settings, EffectReverbState &data, const float *const *inBlock, float *const *outBlock, size_t blockLen)
Definition: Reverb.cpp:421
std::vector< EffectReverb::Instance > mSlaves
Definition: Reverb.cpp:305
bool RealtimeSuspend() override
Definition: Reverb.cpp:274
bool RealtimeInitialize(EffectSettings &settings, double sampleRate) override
Definition: Reverb.cpp:201
Instance(const PerTrackEffect &effect)
Definition: Reverb.cpp:187
bool RealtimeAddProcessor(EffectSettings &settings, EffectOutputs *, unsigned numChannels, float sampleRate) override
Definition: Reverb.cpp:212
bool RealtimeFinalize(EffectSettings &settings) noexcept override
Definition: Reverb.cpp:227
EffectReverbState mState
Definition: Reverb.cpp:304
bool ProcessFinalize(void) noexcept override
Definition: Reverb.cpp:410
double mStereoWidth
Definition: Reverb.h:42
double mReverberance
Definition: Reverb.h:36
double mHfDamping
Definition: Reverb.h:37
double mRoomSize
Definition: Reverb.h:34
double mPreDelay
Definition: Reverb.h:35
double mToneHigh
Definition: Reverb.h:39
std::unique_ptr< Reverb_priv_ex[]> mP
Definition: Reverb.cpp:80
unsigned mNumChans
Definition: Reverb.cpp:79
Message sent by EffectEditor when a setting is changed by the user.
Definition: EffectEditor.h:26
Externalized state of a plug-in.
float * wet[2]
Definition: Reverb.cpp:65
reverb_t reverb
Definition: Reverb.cpp:63
float * dry
Definition: Reverb.cpp:64