|
|
@ -148,9 +148,7 @@ void AudioState::react(const QueueUpdate& ev) { |
|
|
|
|
|
|
|
|
|
|
|
void AudioState::react(const SetTrack& ev) { |
|
|
|
void AudioState::react(const SetTrack& ev) { |
|
|
|
if (std::holds_alternative<std::monostate>(ev.new_track)) { |
|
|
|
if (std::holds_alternative<std::monostate>(ev.new_track)) { |
|
|
|
ESP_LOGI(kTag, "playback finished, awaiting drain"); |
|
|
|
|
|
|
|
sDecoder->open({}); |
|
|
|
sDecoder->open({}); |
|
|
|
sStreamCues.clear(); |
|
|
|
|
|
|
|
return; |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -212,6 +210,7 @@ void AudioState::react(const TtsPlaybackChanged& ev) { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
void AudioState::react(const internal::DecodingFinished& ev) { |
|
|
|
void AudioState::react(const internal::DecodingFinished& ev) { |
|
|
|
|
|
|
|
ESP_LOGD(kTag, "end of file decoded; awaiting playback of buffered audio"); |
|
|
|
// If we just finished playing whatever's at the front of the queue, then we
|
|
|
|
// If we just finished playing whatever's at the front of the queue, then we
|
|
|
|
// need to advanve and start playing the next one ASAP in order to continue
|
|
|
|
// need to advanve and start playing the next one ASAP in order to continue
|
|
|
|
// gaplessly.
|
|
|
|
// gaplessly.
|
|
|
|