43 int deviceIndex = 0,
int bufferFrames = RT_BUFFER_SIZE,
int nBuffers = 20 );
72 StkFloat
lastOut(
unsigned int channel = 0 );
84 StkFloat
tick(
unsigned int channel = 0 );
99 void fillBuffer(
void *buffer,
unsigned int nFrames );
106 unsigned int readIndex_;
107 unsigned int writeIndex_;
108 unsigned int framesFilled_;
112inline StkFloat RtWvIn :: lastOut(
unsigned int channel )
114#if defined(_STK_DEBUG_)
115 if ( channel >= data_.channels() ) {
116 oStream_ <<
"RtWvIn::lastOut(): channel argument and audio stream are incompatible!";
117 handleError( StkError::FUNCTION_ARGUMENT );
121 return lastFrame_[channel];
Realtime audio i/o C++ classes.
Definition RtAudio.h:268
STK mutex class.
Definition Mutex.h:37
STK realtime audio (blocking) input class.
Definition RtWvIn.h:32
void start(void)
Start the audio input stream.
StkFrames & tick(StkFrames &frames, unsigned int channel=0)
Fill the StkFrames object with computed sample frames, starting at the specified channel and return t...
void stop(void)
Stop the audio input stream.
StkFloat lastOut(unsigned int channel=0)
Return the specified channel value of the last computed frame.
Definition RtWvIn.h:112
RtWvIn(unsigned int nChannels=1, StkFloat sampleRate=Stk::sampleRate(), int deviceIndex=0, int bufferFrames=RT_BUFFER_SIZE, int nBuffers=20)
Default constructor.
StkFloat tick(unsigned int channel=0)
Compute a sample frame and return the specified channel value.
~RtWvIn()
Class destructor.
An STK class to handle vectorized audio data.
Definition Stk.h:279
static StkFloat sampleRate(void)
Static method that returns the current STK sample rate.
Definition Stk.h:148
STK audio input abstract base class.
Definition WvIn.h:20
The STK namespace.
Definition ADSR.h:6