inwav - Input waveform from file


#include "wiodef.h"
long inwav (WVFILE *wfp, long nrecs, short *wavbuf)


inwav() reads nrecs samples starting at the current waveform file pointer location from the waveform file associated with wfp and places them in array wavbuf. On success, inwav() returns the number of samples actually read which may be less than the number requested if the number requested exceeded the number of samples available. When inwav() returns less than nrecs samples, the array wavbuf is padded with zeros out to nrecs samples. If the read fails with no samples available, inwav() returns a negative value indicating either a hard error or physical EOF (-1), or a 'soft' eof (-2) indicating the end of the requested segment.


outwav(), isam(), osam(), opnwav(), clswav(),
Libcwav library


H.T.Bunnell, Shirley Peters