#include <audio_transfer_buffer.h>
Definition at line 18 of file audio_transfer_buffer.h.
◆ ~AudioTransferBuffer()
esphome::audio::AudioTransferBuffer::~AudioTransferBuffer |
( |
| ) |
|
◆ allocate_buffer_()
bool esphome::audio::AudioTransferBuffer::allocate_buffer_ |
( |
size_t |
buffer_size | ) |
|
|
protected |
Allocates the transfer buffer in external memory, if available.
- Parameters
-
buffer_size | The number of bytes to allocate |
- Returns
- True is successful, false otherwise.
Definition at line 86 of file audio_transfer_buffer.cpp.
◆ available()
size_t esphome::audio::AudioTransferBuffer::available |
( |
| ) |
const |
|
inline |
◆ capacity()
size_t esphome::audio::AudioTransferBuffer::capacity |
( |
| ) |
const |
|
inline |
◆ clear_buffered_data()
void esphome::audio::AudioTransferBuffer::clear_buffered_data |
( |
| ) |
|
|
virtual |
◆ deallocate_buffer_()
void esphome::audio::AudioTransferBuffer::deallocate_buffer_ |
( |
| ) |
|
|
protected |
◆ decrease_buffer_length()
void esphome::audio::AudioTransferBuffer::decrease_buffer_length |
( |
size_t |
bytes | ) |
|
Updates the internal state of the transfer buffer.
This should be called after reading data
- Parameters
-
bytes | The number of bytes consumed/read |
Definition at line 39 of file audio_transfer_buffer.cpp.
◆ free()
size_t esphome::audio::AudioTransferBuffer::free |
( |
| ) |
const |
◆ get_buffer_end()
uint8_t* esphome::audio::AudioTransferBuffer::get_buffer_end |
( |
| ) |
const |
|
inline |
◆ get_buffer_start()
uint8_t* esphome::audio::AudioTransferBuffer::get_buffer_start |
( |
| ) |
const |
|
inline |
◆ has_buffered_data()
bool esphome::audio::AudioTransferBuffer::has_buffered_data |
( |
| ) |
const |
|
virtual |
◆ increase_buffer_length()
void esphome::audio::AudioTransferBuffer::increase_buffer_length |
( |
size_t |
bytes | ) |
|
Updates the internal state of the transfer buffer.
This should be called after writing data
- Parameters
-
bytes | The number of bytes written |
Definition at line 49 of file audio_transfer_buffer.cpp.
◆ reallocate()
bool esphome::audio::AudioTransferBuffer::reallocate |
( |
size_t |
new_buffer_size | ) |
|
◆ buffer_
uint8_t* esphome::audio::AudioTransferBuffer::buffer_ {nullptr} |
|
protected |
◆ buffer_length_
size_t esphome::audio::AudioTransferBuffer::buffer_length_ {0} |
|
protected |
◆ buffer_size_
size_t esphome::audio::AudioTransferBuffer::buffer_size_ {0} |
|
protected |
◆ data_start_
uint8_t* esphome::audio::AudioTransferBuffer::data_start_ {nullptr} |
|
protected |
◆ ring_buffer_
std::shared_ptr<RingBuffer> esphome::audio::AudioTransferBuffer::ring_buffer_ |
|
protected |
The documentation for this class was generated from the following files: