A class to write SND-files (the .au format) More...
#include <itpp/srccode/audiofile.h>
Public Member Functions | |
SND_Out_File () | |
Default constructor - creates uninitialized stream. | |
SND_Out_File (const char *fname, const Audio_Stream_Description &d) | |
Constructor from file name fname and stream description d. | |
~SND_Out_File () | |
Stream destructor. | |
bool | open (const char *fname, const Audio_Stream_Description &d) |
Open the file fname with stream description d. | |
void | close () |
Close the file. | |
Audio_Stream_Description | get_description () const |
Get stream description. | |
bool | seek_write (std::streamoff pos) |
Set current position to write to pos (samples). | |
std::streamoff | tell_write () |
Get current position in samples. | |
std::streamoff | num_samples () const |
Get number of samples in stream. | |
bool | write_sample (const double &s, int ch=0) |
Write single sample s at current position to channel ch. | |
bool | write_channel (const vec &v, int ch=0) |
Write the vector v to channel ch starting at current position. | |
bool | write (const mat &m) |
Write audio channels from columns of the matrix m starting at current position. | |
A class to write SND-files (the .au format)
Output stream uses underlying binary stream to write audio data to the audio file in au format. Audio can be written sample-by sample, channel-wise or taken column-wise from the input matrix
Following example illustrates write operations with SND_Out_File:
Definition at line 282 of file audiofile.h.
Generated on Sat May 25 2013 16:32:34 for IT++ by Doxygen 1.8.2