diff options
| author | jacqueline <me@jacqueline.id.au> | 2023-01-30 15:52:54 +1100 |
|---|---|---|
| committer | jacqueline <me@jacqueline.id.au> | 2023-01-30 15:52:54 +1100 |
| commit | ef8d404b15e6d32506617a95aa3161fbe59ecdaf (patch) | |
| tree | f05d5f0a81b1477846e85bf44f0154db015b9789 /src/audio/audio_element.cpp | |
| parent | 2cc0a38a1ac7fc54d7333dafa8b99479a7f5dc86 (diff) | |
| download | tangara-fw-ef8d404b15e6d32506617a95aa3161fbe59ecdaf.tar.gz | |
Continue ironing out i2s pipeline
still at least one heap corruption issue, plus the i2s write method
seems to block forever :/
Diffstat (limited to 'src/audio/audio_element.cpp')
| -rw-r--r-- | src/audio/audio_element.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/audio/audio_element.cpp b/src/audio/audio_element.cpp index 90d62e76..70a59a51 100644 --- a/src/audio/audio_element.cpp +++ b/src/audio/audio_element.cpp @@ -1,4 +1,5 @@ #include "audio_element.hpp" +#include <memory> namespace audio { @@ -38,7 +39,8 @@ auto IAudioElement::SendOrBufferEvent(std::unique_ptr<StreamEvent> event) } StreamEvent* raw_event = event.release(); if (!xQueueSend(output_events_, &raw_event, 0)) { - buffered_output_.emplace_front(raw_event); + event.reset(raw_event); + buffered_output_.push_back(std::move(event)); return false; } return true; |
