
Home Information Classes Download Usage Mail List Requirements Links FAQ Tutorial
44 FM(
unsigned int operators = 4 );
56 void setRatio(
unsigned int waveIndex, StkFloat ratio );
59 void setGain(
unsigned int waveIndex, StkFloat gain );
68 void setControl1( StkFloat cVal ) { control1_ = cVal * 2.0; };
71 void setControl2( StkFloat cVal ) { control2_ = cVal * 2.0; };
86 virtual StkFloat
tick(
unsigned int ) = 0;
100 std::vector<ADSR *> adsr_;
101 std::vector<FileLoop *> waves_;
104 unsigned int nOperators_;
105 StkFloat baseFrequency_;
106 std::vector<StkFloat> ratios_;
107 std::vector<StkFloat> gains_;
111 StkFloat fmGains_[100];
112 StkFloat fmSusLevels_[16];
113 StkFloat fmAttTimes_[32];
STK sinusoid oscillator class.
Definition: SineWave.h:26
FM(unsigned int operators=4)
Class constructor, taking the number of wave/envelope operators to control.
virtual void controlChange(int number, StkFloat value)
Perform the control change specified by number and value (0.0 - 128.0).
void setModulationSpeed(StkFloat mSpeed)
Set the modulation speed in Hz.
Definition: FM.h:62
void setControl1(StkFloat cVal)
Set the value of control1.
Definition: FM.h:68
void noteOff(StkFloat amplitude)
Stop a note with the given amplitude (speed of decay).
void setRatio(unsigned int waveIndex, StkFloat ratio)
Set the frequency ratio for the specified wave.
STK abstract FM synthesis base class.
Definition: FM.h:38
void loadWaves(const char **filenames)
Load the rawwave filenames in waves.
An STK class to handle vectorized audio data.
Definition: Stk.h:276
void setFrequency(StkFloat frequency)
Set the data interpolation rate based on a looping frequency.
void keyOn(void)
Start envelopes toward "on" targets.
virtual ~FM(void)
Class destructor.
virtual StkFrames & tick(StkFrames &frames, unsigned int channel=0)=0
Fill a channel of the StkFrames object with computed outputs.
void setGain(unsigned int waveIndex, StkFloat gain)
Set the gain for the specified wave.
STK two-zero filter class.
Definition: TwoZero.h:21
void keyOff(void)
Start envelopes toward "off" targets.
virtual StkFloat tick(unsigned int)=0
Compute and return one output sample.
The STK namespace.
Definition: ADSR.h:6
virtual void setFrequency(StkFloat frequency)
Set instrument parameters for a particular frequency.
STK instrument abstract base class.
Definition: Instrmnt.h:20
void setControl2(StkFloat cVal)
Set the value of control1.
Definition: FM.h:71
void setModulationDepth(StkFloat mDepth)
Set the modulation depth.
Definition: FM.h:65