#include <SimpleOscillator.hxx>

Public Member Functions | |
| SimpleOscillator (const SimpleOscillatorConfig &c=Config()) | |
| virtual | ~SimpleOscillator () |
| const char * | GetClassName () const |
| Override it in every subclass and retur the name of that class. | |
| virtual const ProcessingConfig & | GetConfig () const |
| Configuration getter. | |
| virtual bool | ConcreteConfigure (const ProcessingConfig &c) |
| Configuration method interface. | |
| virtual bool | Do (void) |
| Supervised mode execution method (using ports). | |
| bool | Do (Audio &out) |
| bool | Do (TData &out) |
| Do for generating one sample at a time: useful to use the oscillator as a LFO. | |
Protected Types | |
| typedef SimpleOscillatorConfig | Config |
Protected Member Functions | |
| void | ApplyFreqAndAmpControls () |
| void | UpdateFreq (TControlData) |
| void | UpdateAmp (TControlData) |
Protected Attributes | |
| AudioOutPort | mOutput |
| SimpleOscillatorConfig | mConfig |
| TData | mAmp |
| TData | mPhase |
| TData | mDeltaPhase |
| TData | mSamplingRate |
| bool | mFreqUpdated |
| bool | mAmpUpdated |
| FloatInControl | mFreqCtl |
| FloatInControl | mAmpCtl |
| FloatInControl | mSamplesBetweenCallsCtl |
Definition at line 84 of file SimpleOscillator.hxx.
typedef SimpleOscillatorConfig CLAM::SimpleOscillator::Config [protected] |
| CLAM::SimpleOscillator::SimpleOscillator | ( | const SimpleOscillatorConfig & | c = Config() |
) |
| CLAM::SimpleOscillator::~SimpleOscillator | ( | ) | [virtual] |
Definition at line 67 of file SimpleOscillator.cxx.
| void CLAM::SimpleOscillator::ApplyFreqAndAmpControls | ( | ) | [inline, protected] |
Definition at line 104 of file SimpleOscillator.hxx.
References CLAM::InControl< ControlDataType >::GetLastValue(), mAmp, mAmpCtl, mAmpUpdated, mDeltaPhase, mFreqCtl, mFreqUpdated, mSamplingRate, and PI.
Referenced by Do().
| void CLAM::SimpleOscillator::UpdateFreq | ( | TControlData | value | ) | [protected] |
| void CLAM::SimpleOscillator::UpdateAmp | ( | TControlData | value | ) | [protected] |
| const char* CLAM::SimpleOscillator::GetClassName | ( | ) | const [inline, virtual] |
Override it in every subclass and retur the name of that class.
Implements CLAM::Processing.
Reimplemented in CLAM::Oscillator.
Definition at line 127 of file SimpleOscillator.hxx.
| virtual const ProcessingConfig& CLAM::SimpleOscillator::GetConfig | ( | ) | const [inline, virtual] |
Configuration getter.
Gets the configuration parameters used to create the object.
Reimplemented from CLAM::Processing.
Reimplemented in CLAM::Oscillator.
Definition at line 129 of file SimpleOscillator.hxx.
References mConfig.
| bool CLAM::SimpleOscillator::ConcreteConfigure | ( | const ProcessingConfig & | ) | [virtual] |
Configuration method interface.
The Processing base class forces all the concrete classes derived from it to implement this method, which must actually perform the specific configuration tasks.
Note that the user can not call this method directly. He will use Configure instead. The argument is expected to be an object of the necesary concrete configuration class.
| Reference | to the configuration object. |
| This | method must throw a bad_cast exception if the argument is not an object of the expected configuration class. |
Reimplemented from CLAM::Processing.
Reimplemented in CLAM::Oscillator.
Definition at line 71 of file SimpleOscillator.cxx.
References CLAM::Processing::CopyAsConcreteConfig(), CLAM::InControl< ControlDataType >::DoControl(), mAmp, mConfig, mDeltaPhase, mPhase, mSamplesBetweenCallsCtl, mSamplingRate, and PI.
| bool CLAM::SimpleOscillator::Do | ( | void | ) | [virtual] |
Supervised mode execution method (using ports).
Implements CLAM::Processing.
Reimplemented in CLAM::Oscillator.
Definition at line 85 of file SimpleOscillator.cxx.
References CLAM::AudioOutPort::GetAudio(), mOutput, and CLAM::OutPort< Token >::Produce().
Referenced by CLAM::SpectralRingModulation::Do(), CLAM::SpectralPhaseModulation::Do(), CLAM::SpectralAmplitudeModulation::Do(), CLAM::Oscillator::Do(), CLAM::OscillatingSpectralNotch::Do(), and CLAM::ThreeBandAM::Do().
Reimplemented in CLAM::Oscillator.
Definition at line 93 of file SimpleOscillator.cxx.
References CLAM::Processing::AbleToExecute(), ApplyFreqAndAmpControls(), CLAM::Audio::GetSize(), mAmp, mDeltaPhase, mPhase, and PI.
Do for generating one sample at a time: useful to use the oscillator as a LFO.
Definition at line 113 of file SimpleOscillator.cxx.
References CLAM::Processing::AbleToExecute(), ApplyFreqAndAmpControls(), CLAM::InControl< ControlDataType >::GetLastValue(), mAmp, mDeltaPhase, mPhase, mSamplesBetweenCallsCtl, and PI.
AudioOutPort CLAM::SimpleOscillator::mOutput [protected] |
Definition at line 89 of file SimpleOscillator.hxx.
Referenced by ConcreteConfigure(), and GetConfig().
TData CLAM::SimpleOscillator::mAmp [protected] |
Definition at line 90 of file SimpleOscillator.hxx.
Referenced by ApplyFreqAndAmpControls(), ConcreteConfigure(), CLAM::Oscillator::ConcreteConfigure(), Do(), and CLAM::Oscillator::Do().
TData CLAM::SimpleOscillator::mPhase [protected] |
Definition at line 91 of file SimpleOscillator.hxx.
Referenced by ConcreteConfigure(), CLAM::Oscillator::ConcreteConfigure(), Do(), and CLAM::Oscillator::Do().
TData CLAM::SimpleOscillator::mDeltaPhase [protected] |
Definition at line 92 of file SimpleOscillator.hxx.
Referenced by ApplyFreqAndAmpControls(), ConcreteConfigure(), CLAM::Oscillator::ConcreteConfigure(), Do(), and CLAM::Oscillator::Do().
TData CLAM::SimpleOscillator::mSamplingRate [protected] |
Definition at line 93 of file SimpleOscillator.hxx.
Referenced by ApplyFreqAndAmpControls(), ConcreteConfigure(), and CLAM::Oscillator::ConcreteConfigure().
bool CLAM::SimpleOscillator::mFreqUpdated [protected] |
Definition at line 95 of file SimpleOscillator.hxx.
Referenced by ApplyFreqAndAmpControls(), and UpdateFreq().
bool CLAM::SimpleOscillator::mAmpUpdated [protected] |
Definition at line 96 of file SimpleOscillator.hxx.
Referenced by ApplyFreqAndAmpControls(), and UpdateAmp().
FloatInControl CLAM::SimpleOscillator::mFreqCtl [protected] |
FloatInControl CLAM::SimpleOscillator::mAmpCtl [protected] |
1.5.6