SoundFileIn class public functions

SoundFileIn(char* filename = NULL, float start = NONE, float dur = NONE);
start is the time in seconds into the file to start playing the sound. If start is set to a negative number, then the start is 0 seconds. dur is the duration of the soundfile to play. If dur is -1, then then end of the file will be used to calculate the duration.
Deletes the name of the soundfile.
void action(void);
reads one sample set from a soundfile (e.g., 1 sample from a mono file, 2 samples from a stereo file.)
long getSamples(void);
Returns the number of samples in the soundfile. Stereo files are counted by pairs of samples, etc. for more channels.
sampleType output(int channel = 0);
Gives the amplitude of the current soundfile sample as a floating point number between -1.0 and +1.0 . Default reads channel 0 (mono channel, or left channel for stereo). if channel is negative, then output() returns a sum of all channels in the sound. Error if you try to access an invalid positive channel, but it will also give you the sum of all valid channels.
void printState(void);
Prints the sound header and name of the soundfile.
void reset(int sampleIndex = 0);
If sampleIndex is 0, then the read point is set to begSample. If sampleIndex is negative, then soundfile will be reset to start of file.
void setFile(char *aFileName, start = NONE, dur = NONE);
Opens the specified soundfile for reading.