26#include <condition_variable>
42 bool m_device_opened{
false};
47 bool m_playing{
false};
52 bool m_delayed_close_running{
false};
57 std::thread m_delayed_close_thread;
62 std::mutex m_delayed_close_mutex;
67 std::condition_variable m_immediate_close_condition;
72 std::chrono::milliseconds m_device_close_delay{10000};
77 std::chrono::time_point<std::chrono::steady_clock> m_playback_stopped_time;
82 void closeAfterDelay();
#define AUD_NAMESPACE_END
Closes the audaspace namespace aud.
Definition Audaspace.h:119
#define AUD_LOCAL
Used for hiding symbols from export in the shared library.
Definition Audaspace.h:80
#define AUD_NAMESPACE_BEGIN
Opens the audaspace namespace aud.
Definition Audaspace.h:116
#define AUD_PLUGIN_API
Used for exporting symbols in the shared library.
Definition Audaspace.h:94
The SoftwareDevice class.
This device extends the SoftwareDevice with code for running mixing in a separate thread.
Definition OpenCloseDevice.h:37
virtual void playing(bool playing)
This function tells the device, to start or pause playback.
The software device is a generic device with software mixing.
Definition SoftwareDevice.h:52