Audacity  3.0.3
Wahwah.cpp
Go to the documentation of this file.
1 /**********************************************************************
2 
3  Audacity: A Digital Audio Editor
4 
5  Wahwah.cpp
6 
7  Effect programming:
8  Nasca Octavian Paul (Paul Nasca)
9 
10  UI programming:
11  Dominic Mazzoni (with the help of wxDesigner)
12  Vaughan Johnson (Preview)
13 
14 *******************************************************************//*******************************************************************/
20 
21 
22 #include "Wahwah.h"
23 #include "LoadEffects.h"
24 
25 #include <math.h>
26 
27 #include <wx/intl.h>
28 #include <wx/slider.h>
29 
30 #include "../Shuttle.h"
31 #include "../ShuttleGui.h"
32 #include "../widgets/valnum.h"
33 
34 enum
35 {
36  ID_Freq = 10000,
42 };
43 
44 // Define keys, defaults, minimums, and maximums for the effect parameters
45 //
46 // Name Type Key Def Min Max Scale
47 Param( Freq, double, wxT("Freq"), 1.5, 0.1, 4.0, 10 );
48 Param( Phase, double, wxT("Phase"), 0.0, 0.0, 360.0, 1 );
49 Param( Depth, int, wxT("Depth"), 70, 0, 100, 1 ); // scaled to 0-1 before processing
50 Param( Res, double, wxT("Resonance"), 2.5, 0.1, 10.0, 10 );
51 Param( FreqOfs, int, wxT("Offset"), 30, 0, 100, 1 ); // scaled to 0-1 before processing
52 Param( OutGain, double, wxT("Gain"), -6.0, -30.0, 30.0, 1 );
53 
54 // How many samples are processed before recomputing the lfo value again
55 #define lfoskipsamples 30
56 
57 //
58 // EffectWahwah
59 //
60 
62 { XO("Wahwah") };
63 
65 
66 BEGIN_EVENT_TABLE(EffectWahwah, wxEvtHandler)
80 
82 {
83  mFreq = DEF_Freq;
84  mPhase = DEF_Phase;
85  mDepth = DEF_Depth;
86  mRes = DEF_Res;
87  mFreqOfs = DEF_FreqOfs;
88  mOutGain = DEF_OutGain;
89 
90  SetLinearEffectFlag(true);
91 }
92 
94 {
95 }
96 
97 // ComponentInterface implementation
98 
100 {
101  return Symbol;
102 }
103 
105 {
106  return XO("Rapid tone quality variations, like that guitar sound so popular in the 1970's");
107 }
108 
110 {
111  return L"Wahwah";
112 }
113 
114 // EffectDefinitionInterface implementation
115 
117 {
118  return EffectTypeProcess;
119 }
120 
122 {
123 #if defined(EXPERIMENTAL_REALTIME_AUDACITY_EFFECTS)
124  return true;
125 #else
126  return false;
127 #endif
128 }
129 
130 // EffectClientInterface implementation
131 
133 {
134  return 1;
135 }
136 
138 {
139  return 1;
140 }
141 
143 {
145 
146  if (chanMap[0] == ChannelNameFrontRight)
147  {
148  mMaster.phase += M_PI;
149  }
150 
151  return true;
152 }
153 
154 size_t EffectWahwah::ProcessBlock(float **inBlock, float **outBlock, size_t blockLen)
155 {
156  return InstanceProcess(mMaster, inBlock, outBlock, blockLen);
157 }
158 
160 {
161  SetBlockSize(512);
162 
163  mSlaves.clear();
164 
165  return true;
166 }
167 
168 bool EffectWahwah::RealtimeAddProcessor(unsigned WXUNUSED(numChannels), float sampleRate)
169 {
170  EffectWahwahState slave;
171 
172  InstanceInit(slave, sampleRate);
173 
174  mSlaves.push_back(slave);
175 
176  return true;
177 }
178 
180 {
181  mSlaves.clear();
182 
183  return true;
184 }
185 
187  float **inbuf,
188  float **outbuf,
189  size_t numSamples)
190 {
191 
192  return InstanceProcess(mSlaves[group], inbuf, outbuf, numSamples);
193 }
194 
196  S.SHUTTLE_PARAM( mFreq, Freq );
197  S.SHUTTLE_PARAM( mPhase, Phase );
198  S.SHUTTLE_PARAM( mDepth, Depth );
199  S.SHUTTLE_PARAM( mRes, Res );
200  S.SHUTTLE_PARAM( mFreqOfs, FreqOfs );
201  S.SHUTTLE_PARAM( mOutGain, OutGain );
202  return true;
203 }
204 
206 {
207  parms.Write(KEY_Freq, mFreq);
208  parms.Write(KEY_Phase, mPhase);
209  parms.Write(KEY_Depth, mDepth);
210  parms.Write(KEY_Res, mRes);
211  parms.Write(KEY_FreqOfs, mFreqOfs);
212  parms.Write(KEY_OutGain, mOutGain);
213 
214  return true;
215 }
216 
218 {
219  ReadAndVerifyDouble(Freq);
220  ReadAndVerifyDouble(Phase);
221  ReadAndVerifyInt(Depth);
222  ReadAndVerifyDouble(Res);
223  ReadAndVerifyInt(FreqOfs);
224  ReadAndVerifyDouble(OutGain);
225 
226  mFreq = Freq;
227  mPhase = Phase;
228  mDepth = Depth;
229  mRes = Res;
230  mFreqOfs = FreqOfs;
231  mOutGain = OutGain;
232 
233  return true;
234 }
235 
236 // Effect implementation
237 
239 {
240  S.SetBorder(5);
241  S.AddSpace(0, 5);
242 
243  S.StartMultiColumn(3, wxEXPAND);
244  {
245  S.SetStretchyCol(2);
246 
247  mFreqT = S.Id(ID_Freq)
248  .Validator<FloatingPointValidator<double>>(
249  5, &mFreq, NumValidatorStyle::ONE_TRAILING_ZERO, MIN_Freq, MAX_Freq)
250  .AddTextBox(XXO("LFO Freq&uency (Hz):"), wxT(""), 12);
251 
252  mFreqS = S.Id(ID_Freq)
253  .Name(XO("LFO frequency in hertz"))
254  .Style(wxSL_HORIZONTAL)
255  .MinSize( { 100, -1 } )
256  .AddSlider( {}, DEF_Freq * SCL_Freq, MAX_Freq * SCL_Freq, MIN_Freq * SCL_Freq);
257 
258  mPhaseT = S.Id(ID_Phase)
259  .Validator<FloatingPointValidator<double>>(
260  1, &mPhase, NumValidatorStyle::DEFAULT, MIN_Phase, MAX_Phase)
261  .AddTextBox(XXO("LFO Sta&rt Phase (deg.):"), wxT(""), 12);
262 
263  mPhaseS = S.Id(ID_Phase)
264  .Name(XO("LFO start phase in degrees"))
265  .Style(wxSL_HORIZONTAL)
266  .MinSize( { 100, -1 } )
267  .AddSlider( {}, DEF_Phase * SCL_Phase, MAX_Phase * SCL_Phase, MIN_Phase * SCL_Phase);
268  mPhaseS->SetLineSize(10);
269 
270  mDepthT = S.Id(ID_Depth)
271  .Validator<IntegerValidator<int>>(
272  &mDepth, NumValidatorStyle::DEFAULT, MIN_Depth, MAX_Depth)
273  .AddTextBox(XXO("Dept&h (%):"), wxT(""), 12);
274 
275  mDepthS = S.Id(ID_Depth)
276  .Name(XO("Depth in percent"))
277  .Style(wxSL_HORIZONTAL)
278  .MinSize( { 100, -1 } )
279  .AddSlider( {}, DEF_Depth * SCL_Depth, MAX_Depth * SCL_Depth, MIN_Depth * SCL_Depth);
280 
281  mResT = S.Id(ID_Res)
282  .Validator<FloatingPointValidator<double>>(
283  1, &mRes, NumValidatorStyle::DEFAULT, MIN_Res, MAX_Res)
284  .AddTextBox(XXO("Reso&nance:"), wxT(""), 12);
285 
286  mResS = S.Id(ID_Res)
287  .Name(XO("Resonance"))
288  .Style(wxSL_HORIZONTAL)
289  .MinSize( { 100, -1 } )
290  .AddSlider( {}, DEF_Res * SCL_Res, MAX_Res * SCL_Res, MIN_Res * SCL_Res);
291 
292  mFreqOfsT = S.Id(ID_FreqOfs)
293  .Validator<IntegerValidator<int>>(
294  &mFreqOfs, NumValidatorStyle::DEFAULT, MIN_FreqOfs, MAX_FreqOfs)
295  .AddTextBox(XXO("Wah Frequency Offse&t (%):"), wxT(""), 12);
296 
297  mFreqOfsS = S.Id(ID_FreqOfs)
298  .Name(XO("Wah frequency offset in percent"))
299  .Style(wxSL_HORIZONTAL)
300  .MinSize( { 100, -1 } )
301  .AddSlider( {}, DEF_FreqOfs * SCL_FreqOfs, MAX_FreqOfs * SCL_FreqOfs, MIN_FreqOfs * SCL_FreqOfs);
302 
303  mOutGainT = S.Id(ID_OutGain)
304  .Validator<FloatingPointValidator<double>>(
305  1, &mOutGain, NumValidatorStyle::DEFAULT, MIN_OutGain, MAX_OutGain)
306  .AddTextBox(XXO("&Output gain (dB):"), wxT(""), 12);
307 
308  mOutGainS = S.Id(ID_OutGain)
309  .Name(XO("Output gain (dB)"))
310  .Style(wxSL_HORIZONTAL)
311  .MinSize( { 100, -1 } )
312  .AddSlider( {}, DEF_OutGain * SCL_OutGain, MAX_OutGain * SCL_OutGain, MIN_OutGain * SCL_OutGain);
313  }
314  S.EndMultiColumn();
315 }
316 
318 {
319  if (!mUIParent->TransferDataToWindow())
320  {
321  return false;
322  }
323 
324  mFreqS->SetValue((int) (mFreq * SCL_Freq));
325  mPhaseS->SetValue((int) (mPhase * SCL_Phase));
326  mDepthS->SetValue((int) (mDepth * SCL_Depth));
327  mResS->SetValue((int) (mRes * SCL_Res));
328  mFreqOfsS->SetValue((int) (mFreqOfs * SCL_FreqOfs));
329  mOutGainS->SetValue((int) (mOutGain * SCL_OutGain));
330 
331  return true;
332 }
333 
335 {
336  if (!mUIParent->Validate() || !mUIParent->TransferDataFromWindow())
337  {
338  return false;
339  }
340 
341  return true;
342 }
343 
344 // EffectWahwah implementation
345 
346 void EffectWahwah::InstanceInit(EffectWahwahState & data, float sampleRate)
347 {
348  data.samplerate = sampleRate;
349  data.lfoskip = mFreq * 2 * M_PI / sampleRate;
350  data.skipcount = 0;
351  data.xn1 = 0;
352  data.xn2 = 0;
353  data.yn1 = 0;
354  data.yn2 = 0;
355  data.b0 = 0;
356  data.b1 = 0;
357  data.b2 = 0;
358  data.a0 = 0;
359  data.a1 = 0;
360  data.a2 = 0;
361 
362  data.depth = mDepth / 100.0;
363  data.freqofs = mFreqOfs / 100.0;
364  data.phase = mPhase * M_PI / 180.0;
365  data.outgain = DB_TO_LINEAR(mOutGain);
366 }
367 
368 size_t EffectWahwah::InstanceProcess(EffectWahwahState & data, float **inBlock, float **outBlock, size_t blockLen)
369 {
370  float *ibuf = inBlock[0];
371  float *obuf = outBlock[0];
372  double frequency, omega, sn, cs, alpha;
373  double in, out;
374 
375  data.lfoskip = mFreq * 2 * M_PI / data.samplerate;
376  data.depth = mDepth / 100.0;
377  data.freqofs = mFreqOfs / 100.0;
378 
379  data.phase = mPhase * M_PI / 180.0;
380  data.outgain = DB_TO_LINEAR(mOutGain);
381 
382  for (decltype(blockLen) i = 0; i < blockLen; i++)
383  {
384  in = (double) ibuf[i];
385 
386  if ((data.skipcount++) % lfoskipsamples == 0)
387  {
388  frequency = (1 + cos(data.skipcount * data.lfoskip + data.phase)) / 2;
389  frequency = frequency * data.depth * (1 - data.freqofs) + data.freqofs;
390  frequency = exp((frequency - 1) * 6);
391  omega = M_PI * frequency;
392  sn = sin(omega);
393  cs = cos(omega);
394  alpha = sn / (2 * mRes);
395  data.b0 = (1 - cs) / 2;
396  data.b1 = 1 - cs;
397  data.b2 = (1 - cs) / 2;
398  data.a0 = 1 + alpha;
399  data.a1 = -2 * cs;
400  data.a2 = 1 - alpha;
401  };
402  out = (data.b0 * in + data.b1 * data.xn1 + data.b2 * data.xn2 - data.a1 * data.yn1 - data.a2 * data.yn2) / data.a0;
403  data.xn2 = data.xn1;
404  data.xn1 = in;
405  data.yn2 = data.yn1;
406  data.yn1 = out;
407  out *= data.outgain;
408 
409  obuf[i] = (float) out;
410  }
411 
412  return blockLen;
413 }
414 
415 void EffectWahwah::OnFreqSlider(wxCommandEvent & evt)
416 {
417  mFreq = (double) evt.GetInt() / SCL_Freq;
418  mFreqT->GetValidator()->TransferToWindow();
419  EnableApply(mUIParent->Validate());
420 }
421 
422 void EffectWahwah::OnPhaseSlider(wxCommandEvent & evt)
423 {
424  int val = ((evt.GetInt() + 5) / 10) * 10; // round to nearest multiple of 10
425  val = val > MAX_Phase * SCL_Phase ? MAX_Phase * SCL_Phase : val;
426  mPhaseS->SetValue(val);
427  mPhase = (double) val / SCL_Phase;
428  mPhaseT->GetValidator()->TransferToWindow();
429  EnableApply(mUIParent->Validate());
430 }
431 
432 void EffectWahwah::OnDepthSlider(wxCommandEvent & evt)
433 {
434  mDepth = evt.GetInt() / SCL_Depth;
435  mDepthT->GetValidator()->TransferToWindow();
436  EnableApply(mUIParent->Validate());
437 }
438 
439 void EffectWahwah::OnResonanceSlider(wxCommandEvent & evt)
440 {
441  mRes = (double) evt.GetInt() / SCL_Res;
442  mResT->GetValidator()->TransferToWindow();
443  EnableApply(mUIParent->Validate());
444 }
445 
446 void EffectWahwah::OnFreqOffSlider(wxCommandEvent & evt)
447 {
448  mFreqOfs = evt.GetInt() / SCL_FreqOfs;
449  mFreqOfsT->GetValidator()->TransferToWindow();
450  EnableApply(mUIParent->Validate());
451 }
452 
453 void EffectWahwah::OnGainSlider(wxCommandEvent & evt)
454 {
455  mOutGain = evt.GetInt() / SCL_OutGain;
456  mOutGainT->GetValidator()->TransferToWindow();
457  EnableApply(mUIParent->Validate());
458 }
459 
460 void EffectWahwah::OnFreqText(wxCommandEvent & WXUNUSED(evt))
461 {
462  if (!EnableApply(mUIParent->TransferDataFromWindow()))
463  {
464  return;
465  }
466 
467  mFreqS->SetValue((int) (mFreq * SCL_Freq));
468 }
469 
470 void EffectWahwah::OnPhaseText(wxCommandEvent & WXUNUSED(evt))
471 {
472  if (!EnableApply(mUIParent->TransferDataFromWindow()))
473  {
474  return;
475  }
476 
477  mPhaseS->SetValue((int) (mPhase * SCL_Phase));
478 }
479 
480 void EffectWahwah::OnDepthText(wxCommandEvent & WXUNUSED(evt))
481 {
482  if (!EnableApply(mUIParent->TransferDataFromWindow()))
483  {
484  return;
485  }
486 
487  mDepthS->SetValue((int) (mDepth * SCL_Depth));
488 }
489 
490 void EffectWahwah::OnResonanceText(wxCommandEvent & WXUNUSED(evt))
491 {
492  if (!EnableApply(mUIParent->TransferDataFromWindow()))
493  {
494  return;
495  }
496 
497  mResS->SetValue((int) (mRes * SCL_Res));
498 }
499 
500 void EffectWahwah::OnFreqOffText(wxCommandEvent & WXUNUSED(evt))
501 {
502  if (!EnableApply(mUIParent->TransferDataFromWindow()))
503  {
504  return;
505  }
506 
507  mFreqOfsS->SetValue((int) (mFreqOfs * SCL_FreqOfs));
508 }
509 
510 void EffectWahwah::OnGainText(wxCommandEvent & WXUNUSED(evt))
511 {
512  if (!EnableApply(mUIParent->TransferDataFromWindow()))
513  {
514  return;
515  }
516 
517  mOutGainS->SetValue((int) (mOutGain * SCL_OutGain));
518 }
EffectWahwah::mSlaves
std::vector< EffectWahwahState > mSlaves
Definition: Wahwah.h:103
EffectWahwah
An Effect that adds a 'spectral glide'.
Definition: Wahwah.h:40
EffectWahwah::OnFreqSlider
void OnFreqSlider(wxCommandEvent &evt)
Definition: Wahwah.cpp:415
EffectWahwah::mFreqOfsT
wxTextCtrl * mFreqOfsT
Definition: Wahwah.h:128
TranslatableString
Holds a msgid for the translation catalog; may also bind format arguments.
Definition: TranslatableString.h:32
CommandParameters
CommandParameters, derived from wxFileConfig, is essentially doing the same things as the Shuttle cla...
Definition: EffectAutomationParameters.h:67
ID_Phase
@ ID_Phase
Definition: Wahwah.cpp:37
EffectTypeProcess
@ EffectTypeProcess
Definition: EffectInterface.h:59
DB_TO_LINEAR
const double MIN_Threshold_Linear DB_TO_LINEAR(MIN_Threshold_dB)
EffectWahwah::mOutGain
double mOutGain
Definition: Wahwah.h:122
Effect::EnableApply
virtual bool EnableApply(bool enable=true)
Definition: Effect.cpp:1925
EffectWahwah::RealtimeProcess
size_t RealtimeProcess(int group, float **inbuf, float **outbuf, size_t numSamples) override
Definition: Wahwah.cpp:186
EffectWahwahState::samplerate
float samplerate
Definition: Wahwah.h:28
EffectWahwah::RealtimeFinalize
bool RealtimeFinalize() override
Definition: Wahwah.cpp:179
EffectWahwah::OnFreqOffSlider
void OnFreqOffSlider(wxCommandEvent &evt)
Definition: Wahwah.cpp:446
ChannelNameFrontRight
@ ChannelNameFrontRight
Definition: EffectInterface.h:150
EffectWahwah::OnResonanceText
void OnResonanceText(wxCommandEvent &evt)
Definition: Wahwah.cpp:490
EffectWahwah::OnFreqOffText
void OnFreqOffText(wxCommandEvent &evt)
Definition: Wahwah.cpp:500
EffectWahwah::RealtimeInitialize
bool RealtimeInitialize() override
Definition: Wahwah.cpp:159
EffectWahwahState::depth
double depth
Definition: Wahwah.h:29
EffectWahwah::mResT
wxTextCtrl * mResT
Definition: Wahwah.h:127
EffectWahwahState::b1
double b1
Definition: Wahwah.h:36
ShuttleGui::AddSpace
wxSizerItem * AddSpace(int width, int height, int prop=0)
Definition: ShuttleGui.cpp:2447
EffectWahwah::ProcessBlock
size_t ProcessBlock(float **inBlock, float **outBlock, size_t blockLen) override
Definition: Wahwah.cpp:154
EffectWahwah::PopulateOrExchange
void PopulateOrExchange(ShuttleGui &S) override
Definition: Wahwah.cpp:238
ShuttleGui::MinSize
ShuttleGui & MinSize()
Definition: ShuttleGui.h:733
XO
#define XO(s)
Definition: Internat.h:31
END_EVENT_TABLE
END_EVENT_TABLE()
EffectWahwah::mDepth
int mDepth
Definition: Wahwah.h:119
ShuttleParams
Shuttle that deals with parameters. This is a base class with lots of virtual functions that do nothi...
Definition: Shuttle.h:62
EffectWahwahState::a2
double a2
Definition: Wahwah.h:36
ID_FreqOfs
@ ID_FreqOfs
Definition: Wahwah.cpp:40
ShuttleGuiBase::EndMultiColumn
void EndMultiColumn()
Definition: ShuttleGui.cpp:1238
EffectWahwahState::freqofs
double freqofs
Definition: Wahwah.h:30
EffectWahwah::mDepthS
wxSlider * mDepthS
Definition: Wahwah.h:133
EffectWahwah::mPhaseS
wxSlider * mPhaseS
Definition: Wahwah.h:132
Wahwah.h
ComponentInterfaceSymbol
ComponentInterfaceSymbol pairs a persistent string identifier used internally with an optional,...
Definition: ComponentInterfaceSymbol.h:27
ShuttleGui::Id
ShuttleGui & Id(int id)
Definition: ShuttleGui.cpp:2274
EffectWahwah::RealtimeAddProcessor
bool RealtimeAddProcessor(unsigned numChannels, float sampleRate) override
Definition: Wahwah.cpp:168
EffectWahwah::SupportsRealtime
bool SupportsRealtime() override
Definition: Wahwah.cpp:121
EffectWahwahState::b2
double b2
Definition: Wahwah.h:36
EffectWahwahState::skipcount
unsigned long skipcount
Definition: Wahwah.h:34
ReadAndVerifyInt
#define ReadAndVerifyInt(name)
Definition: Effect.h:632
EffectWahwah::mPhaseT
wxTextCtrl * mPhaseT
Definition: Wahwah.h:125
XXO
#define XXO(s)
Definition: Internat.h:44
EffectWahwahState::outgain
double outgain
Definition: Wahwah.h:32
EffectWahwah::mOutGainS
wxSlider * mOutGainS
Definition: Wahwah.h:136
EffectWahwah::SetAutomationParameters
bool SetAutomationParameters(CommandParameters &parms) override
Definition: Wahwah.cpp:217
Param
Param(Freq, double, wxT("Freq"), 1.5, 0.1, 4.0, 10)
EffectWahwah::ManualPage
ManualPageID ManualPage() override
Definition: Wahwah.cpp:109
EffectWahwahState::phase
double phase
Definition: Wahwah.h:31
EffectWahwah::mFreqT
wxTextCtrl * mFreqT
Definition: Wahwah.h:124
ShuttleGuiBase::StartMultiColumn
void StartMultiColumn(int nCols, int PositionFlags=wxALIGN_LEFT)
Definition: ShuttleGui.cpp:1229
EffectWahwah::GetSymbol
ComponentInterfaceSymbol GetSymbol() override
Definition: Wahwah.cpp:99
EffectWahwah::DefineParams
bool DefineParams(ShuttleParams &S) override
Definition: Wahwah.cpp:195
EffectWahwah::mRes
double mRes
Definition: Wahwah.h:120
EffectWahwah::OnDepthSlider
void OnDepthSlider(wxCommandEvent &evt)
Definition: Wahwah.cpp:432
EffectWahwah::OnGainText
void OnGainText(wxCommandEvent &evt)
Definition: Wahwah.cpp:510
EffectWahwah::GetAudioOutCount
unsigned GetAudioOutCount() override
Definition: Wahwah.cpp:137
EffectWahwah::mFreqOfsS
wxSlider * mFreqOfsS
Definition: Wahwah.h:135
EffectWahwah::GetAudioInCount
unsigned GetAudioInCount() override
Definition: Wahwah.cpp:132
EffectWahwahState::xn2
double xn2
Definition: Wahwah.h:35
ShuttleGui::Validator
ShuttleGui & Validator(const Factory &f)
Definition: ShuttleGui.h:678
EffectWahwahState::yn1
double yn1
Definition: Wahwah.h:35
ChannelNames
enum ChannelName * ChannelNames
EffectWahwah::ProcessInitialize
bool ProcessInitialize(sampleCount totalLen, ChannelNames chanMap=NULL) override
Definition: Wahwah.cpp:142
EffectWahwahState::lfoskip
double lfoskip
Definition: Wahwah.h:33
EffectWahwah::OnGainSlider
void OnGainSlider(wxCommandEvent &evt)
Definition: Wahwah.cpp:453
ReadAndVerifyDouble
#define ReadAndVerifyDouble(name)
Definition: Effect.h:633
EffectWahwah::mDepthT
wxTextCtrl * mDepthT
Definition: Wahwah.h:126
EffectWahwah::mFreqOfs
int mFreqOfs
Definition: Wahwah.h:121
EffectWahwah::TransferDataToWindow
bool TransferDataToWindow() override
Definition: Wahwah.cpp:317
LoadEffects.h
ID_Depth
@ ID_Depth
Definition: Wahwah.cpp:38
EffectWahwah::mFreqS
wxSlider * mFreqS
Definition: Wahwah.h:131
EffectWahwah::mMaster
EffectWahwahState mMaster
Definition: Wahwah.h:102
ShuttleGui::Name
ShuttleGui & Name(const TranslatableString &name)
Definition: ShuttleGui.h:663
Effect::mSampleRate
double mSampleRate
Definition: Effect.h:460
lfoskipsamples
#define lfoskipsamples
Definition: Wahwah.cpp:55
BuiltinEffectsModule::Registration
Definition: LoadEffects.h:40
Effect::mUIParent
wxWindow * mUIParent
Definition: Effect.h:478
TaggedIdentifier< ManualPageIDTag >
EffectWahwah::Symbol
static const ComponentInterfaceSymbol Symbol
Definition: Wahwah.h:42
ID_OutGain
@ ID_OutGain
Definition: Wahwah.cpp:41
sampleCount
Positions or offsets within audio files need a wide type.
Definition: SampleCount.h:18
EffectWahwah::OnResonanceSlider
void OnResonanceSlider(wxCommandEvent &evt)
Definition: Wahwah.cpp:439
EffectWahwah::GetAutomationParameters
bool GetAutomationParameters(CommandParameters &parms) override
Definition: Wahwah.cpp:205
EffectWahwahState::a1
double a1
Definition: Wahwah.h:36
EffectWahwah::OnFreqText
void OnFreqText(wxCommandEvent &evt)
Definition: Wahwah.cpp:460
EffectWahwahState::xn1
double xn1
Definition: Wahwah.h:35
EffectWahwah::OnPhaseText
void OnPhaseText(wxCommandEvent &evt)
Definition: Wahwah.cpp:470
EffectWahwah::mResS
wxSlider * mResS
Definition: Wahwah.h:134
EffectWahwah::InstanceInit
void InstanceInit(EffectWahwahState &data, float sampleRate)
Definition: Wahwah.cpp:346
EffectWahwahState::a0
double a0
Definition: Wahwah.h:36
M_PI
#define M_PI
Definition: Distortion.cpp:29
ID_Res
@ ID_Res
Definition: Wahwah.cpp:39
EffectWahwah::TransferDataFromWindow
bool TransferDataFromWindow() override
Definition: Wahwah.cpp:334
EffectWahwahState::yn2
double yn2
Definition: Wahwah.h:35
ShuttleGuiBase::SetBorder
void SetBorder(int Border)
Definition: ShuttleGui.h:489
EffectWahwah::GetDescription
TranslatableString GetDescription() override
Definition: Wahwah.cpp:104
EffectWahwah::mOutGainT
wxTextCtrl * mOutGainT
Definition: Wahwah.h:129
ID_Freq
@ ID_Freq
Definition: Wahwah.cpp:36
EffectType
EffectType
Definition: EffectInterface.h:55
EffectWahwah::mFreq
double mFreq
Definition: Wahwah.h:117
ShuttleGuiBase::SetStretchyCol
void SetStretchyCol(int i)
Used to modify an already placed FlexGridSizer to make a column stretchy.
Definition: ShuttleGui.cpp:202
EffectWahwah::GetType
EffectType GetType() override
Definition: Wahwah.cpp:116
Effect::SetBlockSize
size_t SetBlockSize(size_t maxBlockSize) override
Definition: Effect.cpp:316
EffectWahwahState::b0
double b0
Definition: Wahwah.h:36
EffectWahwah::mPhase
double mPhase
Definition: Wahwah.h:118
EffectWahwahState
Definition: Wahwah.h:26
ShuttleGui
Derived from ShuttleGuiBase, an Audacity specific class for shuttling data to and from GUI.
Definition: ShuttleGui.h:631
anonymous_namespace{Wahwah.cpp}::reg
BuiltinEffectsModule::Registration< EffectWahwah > reg
Definition: Wahwah.cpp:64
EffectWahwah::InstanceProcess
size_t InstanceProcess(EffectWahwahState &data, float **inBlock, float **outBlock, size_t blockLen)
Definition: Wahwah.cpp:368
EffectWahwah::~EffectWahwah
virtual ~EffectWahwah()
Definition: Wahwah.cpp:93
EffectWahwah::OnDepthText
void OnDepthText(wxCommandEvent &evt)
Definition: Wahwah.cpp:480
EffectWahwah::OnPhaseSlider
void OnPhaseSlider(wxCommandEvent &evt)
Definition: Wahwah.cpp:422