Audaspace 1.5.0
A high level audio library.
|
This class writes a sound file via ffmpeg. More...
#include <FFMPEGWriter.h>
Public Member Functions | |
FFMPEGWriter (const std::string &filename, DeviceSpecs specs, Container format, Codec codec, unsigned int bitrate) | |
Creates a new writer. | |
virtual | ~FFMPEGWriter () |
Destroys the writer and closes the file. | |
virtual int | getPosition () const |
Returns how many samples have been written so far. | |
virtual DeviceSpecs | getSpecs () const |
Returns the specification of the audio data being written into the sink. | |
virtual void | write (unsigned int length, sample_t *buffer) |
Request to write the next length samples out into the sink. | |
Public Member Functions inherited from IWriter | |
virtual | ~IWriter () |
Destroys the writer. | |
This class writes a sound file via ffmpeg.
FFMPEGWriter::FFMPEGWriter | ( | const std::string & | filename, |
DeviceSpecs | specs, | ||
Container | format, | ||
Codec | codec, | ||
unsigned int | bitrate ) |
Creates a new writer.
filename | The path to the file to be read. |
specs | The file's audio specification. |
format | The file's container format. |
codec | The codec used for encoding the audio data. |
bitrate | The bitrate for encoding. |
Exception | Thrown if the file specified does not exist or cannot be read with ffmpeg. |
|
virtual |
Returns how many samples have been written so far.
Implements IWriter.
|
virtual |
Returns the specification of the audio data being written into the sink.
Implements IWriter.
|
virtual |
Request to write the next length samples out into the sink.
length | The count of samples to write. |
buffer | The pointer to the buffer containing the data. |
Implements IWriter.