HikoGUI
A low latency retained GUI
Loading...
Searching...
No Matches
src
hikogui
audio
audio_system.hpp
1
// Copyright Take Vos 2020.
2
// Distributed under the Boost Software License, Version 1.0.
3
// (See accompanying file LICENSE_1_0.txt or copy at https://www.boost.org/LICENSE_1_0.txt)
4
5
#pragma once
6
7
#include "audio_system_delegate.hpp"
8
#include "audio_device.hpp"
9
#include "../unfair_recursive_mutex.hpp"
10
#include "../weak_or_unique_ptr.hpp"
11
#include <vector>
12
#include <memory>
13
14
namespace
hi::inline v1 {
15
19
class
audio_system
{
20
public
:
21
[[nodiscard]]
static
std::unique_ptr<audio_system>
22
make_unique(
std::weak_ptr<audio_system_delegate>
delegate)
noexcept
;
23
24
audio_system
(
std::weak_ptr<audio_system_delegate>
delegate);
25
virtual
~audio_system
();
26
audio_system
(
audio_system
const
&) =
delete
;
27
audio_system
(
audio_system
&&) =
delete
;
28
audio_system
&operator=(
audio_system
const
&) =
delete
;
29
audio_system
&operator=(
audio_system
&&) =
delete
;
30
31
virtual
void
init()
noexcept
;
32
virtual
void
deinit()
noexcept
;
33
39
[[nodiscard]]
virtual
std::vector<audio_device *>
devices
() noexcept = 0;
40
41
protected:
42
std
::weak_ptr<
audio_system_delegate
> _delegate;
43
};
44
45
}
// namespace hi::inline v1
std
STL namespace.
v1::audio_system
Definition
audio_system.hpp:19
v1::audio_system::devices
virtual std::vector< audio_device * > devices() noexcept=0
The devices that are part of the audio system.
v1::audio_system_delegate
Definition
audio_system_delegate.hpp:12
std::unique_ptr
std::vector
std::weak_ptr
Generated on Mon Apr 22 2024 12:53:25 for HikoGUI by
1.10.0