
Home Information Classes Download Usage Mail List Requirements Links FAQ Tutorial
36 void reset(
void ) { lastFrame_[0] = 0.0; };
51 StkFloat
lastOut(
void )
const {
return lastFrame_[0]; };
54 StkFloat
tick(
void );
68 void sampleRateChanged( StkFloat newRate, StkFloat oldRate );
73 StkFloat vibratoGain_;
75 unsigned int noiseRate_;
76 unsigned int noiseCounter_;
83 lastFrame_[0] = vibratoGain_ * vibrato_.
tick();
84 if ( noiseCounter_++ >= noiseRate_ ) {
94 #if defined(_STK_DEBUG_)
95 if ( channel >= frames.
channels() ) {
96 oStream_ <<
"Modulate::tick(): channel and StkFrames arguments are incompatible!";
101 StkFloat *samples = &frames[channel];
102 unsigned int hop = frames.
channels();
103 for (
unsigned int i=0; i<frames.
frames(); i++, samples += hop )
STK one-pole filter class.
Definition: OnePole.h:20
STK sinusoid oscillator class.
Definition: SineWave.h:25
unsigned int frames(void) const
Return the number of sample frames represented by the data.
Definition: Stk.h:407
void setRandomRate(StkFloat rate)
Set the periodic (vibrato) rate or frequency in Hz.
Definition: Modulate.h:45
StkFloat tick(void)
Compute and return one output sample.
Definition: Noise.h:59
void reset(void)
Reset internal state.
Definition: Modulate.h:36
StkFloat tick(StkFloat input)
Input one sample to the filter and return one output.
Definition: OnePole.h:80
STK abstract unit generator parent class.
Definition: Generator.h:20
static StkFloat sampleRate(void)
Static method that returns the current STK sample rate.
Definition: Stk.h:145
void setRandomGain(StkFloat gain)
Set the random modulation gain.
An STK class to handle vectorized audio data.
Definition: Stk.h:275
void setFrequency(StkFloat frequency)
Set the data interpolation rate based on a looping frequency.
StkFloat tick(void)
Compute and return one output sample.
Definition: SineWave.h:99
StkFloat lastOut(void) const
Return the last computed output value.
Definition: Modulate.h:51
unsigned int channels(void) const
Return the number of channels represented by the data.
Definition: Stk.h:404
static void handleError(const char *message, StkError::Type type)
Static function for error reporting and handling using c-strings.
~Modulate(void)
Class destructor.
Modulate(void)
Class constructor.
StkFloat tick(void)
Compute and return one output sample.
Definition: Modulate.h:80
void setVibratoRate(StkFloat rate)
Set the periodic (vibrato) rate or frequency in Hz.
Definition: Modulate.h:39
STK noise generator.
Definition: Noise.h:21
void setVibratoGain(StkFloat gain)
Set the periodic (vibrato) gain.
Definition: Modulate.h:42
STK periodic/random modulator.
Definition: Modulate.h:23
The STK namespace.
Definition: ADSR.h:6
StkFloat lastOut(void) const
Return the last computed output value.
Definition: Noise.h:40