#include <aflibBufferDev.h>
Public Methods | |
aflibBufferDev () | |
~aflibBufferDev () | |
bool | init (int buf_size) |
Initializes the buffer class. More... | |
int | getBufferSize () const |
Gets the total size of the buffer. | |
int | bytes_available () |
Gets the number bytes available to read from the buffer. | |
void | write (unsigned char *buf, int num_bytes) |
void | read (unsigned char *buf, int num_bytes) |
Some audio devices do not provide buffering for audio data. The Solaris audio device in record mode is one. For record mode one must read data in blocks exactly. If the user requests a size different than the audio device block size then we must read the audio device block size and buffer the data and return the requested size from the buffer. This class provides this buffer.
|
|
|
|
|
Gets the number bytes available to read from the buffer.
|
|
Gets the total size of the buffer.
|
|
Initializes the buffer class. This will initialize the buffer class with a size of buf_size. Subsequent calls to this function will free any previous memory allocated with a call to init. |
|
|
|
|