fix: stream stops and dies on underflow

This commit is contained in:
MihailRis 2025-10-30 19:56:07 +03:00
parent ab7bf9c709
commit cf561e78a8
6 changed files with 60 additions and 27 deletions

View file

@ -221,6 +221,9 @@ namespace audio {
/// @brief Set playhead to the selected time
/// @param time selected time
virtual void setTime(duration_t time) = 0;
virtual bool isStopOnEnd() const = 0;
virtual void setStopOnEnd(bool stopOnEnd) = 0;
};
/// @brief Sound is an audio asset that supposed to support many
@ -355,6 +358,8 @@ namespace audio {
inline bool isStopped() const {
return getState() == State::stopped;
}
virtual bool isManuallyStopped() const = 0;
};
class Backend {