neoGFX
Cross-platform C++ app/game engine
Loading...
Searching...
No Matches
audio.hpp
Go to the documentation of this file.
1// audio.hpp
2/*
3 neogfx C++ App/Game Engine
4 Copyright (c) 2021 Leigh Johnston. All Rights Reserved.
5
6 This program is free software: you can redistribute it and / or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation, either version 3 of the License, or
9 (at your option) any later version.
10
11 This program is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
15
16 You should have received a copy of the GNU General Public License
17 along with this program. If not, see <http://www.gnu.org/licenses/>.
18*/
19
20#include <neogfx/neogfx.hpp>
24
25#pragma once
26
27namespace neogfx
28{
29 class audio : public i_audio
30 {
31 public:
33 ~audio() override;
34 public:
36 i_audio_device& create_device(i_audio_device_info const& aDeviceInfo, audio_data_format const& aDataFormat) override;
39 void destroy_device(i_audio_device& aDevice) override;
40 public:
42 private:
43 i_audio_device_info const* find_device(audio_device_type aType, audio_data_format const& aDataFormat);
44 private:
45 audio_context iContext;
46 vector<audio_device_info> iDeviceInfos;
48 audio_instrument_atlas iInstrumentAtlas;
49 };
50}
i_audio_device & create_playback_device(audio_data_format const &aDataFormat) override
i_audio_device & create_capture_device(audio_data_format const &aDataFormat) override
i_vector< i_audio_device_info > const & available_devices() override
void destroy_device(i_audio_device &aDevice) override
i_audio_instrument_atlas & instrument_atlas() override
i_audio_device & create_device(i_audio_device_info const &aDeviceInfo, audio_data_format const &aDataFormat) override
~audio() override
std::any audio_context
Definition i_audio.hpp:27