2010-01-23 19:44:49 +00:00
|
|
|
/**********************************************************************
|
|
|
|
|
|
|
|
Audacity: A Digital Audio Editor
|
|
|
|
|
|
|
|
Noise.h
|
|
|
|
|
|
|
|
Dominic Mazzoni
|
|
|
|
|
2015-04-17 03:53:42 +00:00
|
|
|
An effect to add white noise.
|
2010-01-23 19:44:49 +00:00
|
|
|
|
|
|
|
**********************************************************************/
|
|
|
|
|
|
|
|
#ifndef __AUDACITY_EFFECT_NOISE__
|
|
|
|
#define __AUDACITY_EFFECT_NOISE__
|
|
|
|
|
2015-04-17 03:53:42 +00:00
|
|
|
#include <wx/string.h>
|
2010-01-23 19:44:49 +00:00
|
|
|
|
2015-04-17 03:53:42 +00:00
|
|
|
#include "../widgets/NumericTextCtrl.h"
|
2010-01-23 19:44:49 +00:00
|
|
|
|
2015-04-17 03:53:42 +00:00
|
|
|
#include "Effect.h"
|
2010-01-23 19:44:49 +00:00
|
|
|
|
2015-06-18 14:24:36 +00:00
|
|
|
class ShuttleGui;
|
|
|
|
|
2015-04-19 03:49:05 +00:00
|
|
|
#define NOISE_PLUGIN_SYMBOL XO("Noise")
|
2010-01-23 19:44:49 +00:00
|
|
|
|
2015-04-17 03:53:42 +00:00
|
|
|
class EffectNoise : public Effect
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
EffectNoise();
|
|
|
|
virtual ~EffectNoise();
|
2010-01-23 19:44:49 +00:00
|
|
|
|
2015-04-17 03:53:42 +00:00
|
|
|
// IdentInterface implementation
|
2010-01-23 19:44:49 +00:00
|
|
|
|
2015-04-17 03:53:42 +00:00
|
|
|
virtual wxString GetSymbol();
|
|
|
|
virtual wxString GetDescription();
|
2010-01-23 19:44:49 +00:00
|
|
|
|
2015-04-17 03:53:42 +00:00
|
|
|
// EffectIdentInterface implementation
|
2010-01-23 19:44:49 +00:00
|
|
|
|
2015-04-17 03:53:42 +00:00
|
|
|
virtual EffectType GetType();
|
2010-01-23 19:44:49 +00:00
|
|
|
|
2015-04-17 03:53:42 +00:00
|
|
|
// EffectClientInterface implementation
|
2010-01-23 19:44:49 +00:00
|
|
|
|
2015-04-17 03:53:42 +00:00
|
|
|
virtual int GetAudioOutCount();
|
|
|
|
virtual sampleCount ProcessBlock(float **inBlock, float **outBlock, sampleCount blockLen);
|
|
|
|
virtual bool GetAutomationParameters(EffectAutomationParameters & parms);
|
|
|
|
virtual bool SetAutomationParameters(EffectAutomationParameters & parms);
|
2010-01-23 19:44:49 +00:00
|
|
|
|
2015-04-17 03:53:42 +00:00
|
|
|
// Effect implementation
|
2015-01-01 10:34:48 +00:00
|
|
|
|
2015-04-17 03:53:42 +00:00
|
|
|
virtual bool Startup();
|
|
|
|
virtual void PopulateOrExchange(ShuttleGui & S);
|
|
|
|
virtual bool TransferDataToWindow();
|
|
|
|
virtual bool TransferDataFromWindow();
|
2010-01-23 19:44:49 +00:00
|
|
|
|
2015-04-17 03:53:42 +00:00
|
|
|
private:
|
|
|
|
// EffectNoise implementation
|
2010-01-23 19:44:49 +00:00
|
|
|
|
2015-04-17 03:53:42 +00:00
|
|
|
private:
|
|
|
|
int mType;
|
|
|
|
double mAmp;
|
2010-01-23 19:44:49 +00:00
|
|
|
|
2013-02-14 01:10:59 +00:00
|
|
|
float y, z, buf0, buf1, buf2, buf3, buf4, buf5, buf6;
|
2010-01-23 19:44:49 +00:00
|
|
|
|
2014-11-08 15:18:43 +00:00
|
|
|
NumericTextCtrl *mNoiseDurationT;
|
2010-01-23 19:44:49 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|