46   FileWvIn( 
unsigned long chunkThreshold = 1000000, 
unsigned long chunkSize = 1024 );
 
   53   FileWvIn( std::string fileName, 
bool raw = 
false, 
bool doNormalize = 
true,
 
   54             unsigned long chunkThreshold = 1000000, 
unsigned long chunkSize = 1024 );
 
   69   virtual void openFile( std::string fileName, 
bool raw = 
false, 
bool doNormalize = 
true );
 
   75   virtual void reset( 
void );
 
  112   virtual void setRate( StkFloat rate );
 
  118   virtual void addTime( StkFloat time );
 
  139   StkFloat 
lastOut( 
unsigned int channel = 0 );
 
  151   virtual StkFloat 
tick( 
unsigned int channel = 0 );
 
  175   unsigned long chunkThreshold_;
 
  176   unsigned long chunkSize_;
 
  183 #if defined(_STK_DEBUG_) 
  184   if ( channel >= data_.
channels() ) {
 
  185     oStream_ << 
"FileWvIn::lastOut(): channel argument and soundfile data are incompatible!";
 
  190   if ( finished_ ) 
return 0.0;
 
  191   return lastFrame_[channel];
 
virtual void addTime(StkFloat time)
Increment the read pointer by time samples. 
Definition: FileWvIn.cpp:155
 
void sampleRateChanged(StkFloat newRate, StkFloat oldRate)
This function should be implemented in subclasses that depend on the sample rate. ...
Definition: FileWvIn.cpp:61
 
virtual unsigned long getSize(void) const 
Return the file size in sample frames. 
Definition: FileWvIn.h:92
 
virtual void normalize(void)
Normalize data to a maximum of +-1.0. 
Definition: FileWvIn.cpp:116
 
StkFloat lastOut(unsigned int channel=0)
Return the specified channel value of the last computed frame. 
Definition: FileWvIn.h:181
 
STK audio file input class. 
Definition: FileWvIn.h:42
 
void setInterpolate(bool doInterpolate)
Turn linear interpolation on/off. 
Definition: FileWvIn.h:127
 
unsigned long fileSize(void) const 
Return the file size in sample frames. 
Definition: FileRead.h:77
 
The STK namespace. 
Definition: FileRead.cpp:41
 
STK audio file input class. 
Definition: FileRead.h:41
 
bool isOpen(void)
Query whether a file is open. 
Definition: FileWvIn.h:103
 
virtual StkFloat tick(unsigned int channel=0)
Compute a sample frame and return the specified channel value. 
Definition: FileWvIn.cpp:168
 
static void handleError(const char *message, StkError::Type type)
Static function for error reporting and handling using c-strings. 
Definition: Stk.cpp:201
 
virtual void openFile(std::string fileName, bool raw=false, bool doNormalize=true)
Open the specified file and load its data. 
Definition: FileWvIn.cpp:74
 
virtual void reset(void)
Clear outputs and reset time (file) pointer to zero. 
Definition: FileWvIn.cpp:109
 
virtual void setRate(StkFloat rate)
Set the data read rate in samples. The rate can be negative. 
Definition: FileWvIn.cpp:143
 
bool isOpen(void)
Returns true if a file is currently open. 
Definition: FileRead.cpp:72
 
StkFloat dataRate(void) const 
Return the sample rate associated with the StkFrames data. 
Definition: Stk.h:394
 
An STK class to handle vectorized audio data. 
Definition: Stk.h:272
 
STK audio input abstract base class. 
Definition: WvIn.h:19
 
unsigned int channels(void) const 
Return the number of channels represented by the data. 
Definition: Stk.h:377
 
bool isFinished(void) const 
Query whether reading is complete. 
Definition: FileWvIn.h:106
 
virtual void closeFile(void)
Close a file if one is open. 
Definition: FileWvIn.cpp:67
 
FileWvIn(unsigned long chunkThreshold=1000000, unsigned long chunkSize=1024)
Default constructor. 
Definition: FileWvIn.cpp:39
 
~FileWvIn(void)
Class destructor. 
Definition: FileWvIn.cpp:55
 
virtual StkFloat getFileRate(void) const 
Return the input file sample rate in Hz (not the data read rate). 
Definition: FileWvIn.h:100