Ardour
9.0-pre0-582-g084a23a80d
|
#include <buffer.h>
Public Member Functions | |
Buffer (const Buffer &)=delete | |
Buffer & | operator= (const Buffer &)=delete |
virtual | ~Buffer () |
size_t | capacity () const |
DataType | type () const |
bool | silent () const |
virtual void | resize (size_t)=0 |
virtual void | silence (samplecnt_t len, samplecnt_t offset=0)=0 |
virtual bool | silent_data () const =0 |
virtual void | clear () |
virtual void | read_from (const Buffer &src, samplecnt_t len, sampleoffset_t dst_offset=0, sampleoffset_t src_offset=0)=0 |
virtual void | merge_from (const Buffer &src, samplecnt_t len, sampleoffset_t dst_offset=0, sampleoffset_t src_offset=0)=0 |
Static Public Member Functions | |
static Buffer * | create (DataType type, size_t capacity) |
Protected Member Functions | |
Buffer (DataType type) | |
Protected Attributes | |
DataType | _type |
pframes_t | _capacity |
bool | _silent |
A buffer of recordable/playable data.
This is a datatype-agnostic base class for all buffers (there are no methods to actually access the data). This provides a way for code that doesn't care about the data type to still deal with buffers (which is why the base class can't be a template).
To actually read/write buffer contents, use the appropriate derived class.
|
delete |
|
inline |
|
inlinevirtual |
Clear the entire buffer
Reimplemented in ARDOUR::MidiBuffer.
|
pure virtual |
Implemented in ARDOUR::MidiBuffer, and ARDOUR::AudioBuffer.
|
pure virtual |
Implemented in ARDOUR::MidiBuffer, and ARDOUR::AudioBuffer.
|
pure virtual |
Reallocate the buffer used internally to handle at least size_t units of data.
The buffer is not silent after this operation. the capacity argument passed to the constructor must have been non-zero.
Implemented in ARDOUR::MidiBuffer, and ARDOUR::AudioBuffer.
|
pure virtual |
Clear (eg zero, or empty) buffer
Implemented in ARDOUR::MidiBuffer, and ARDOUR::AudioBuffer.
|
pure virtual |
Implemented in ARDOUR::MidiBuffer, and ARDOUR::AudioBuffer.
|
inline |