HephAudio v3.1.0
A cross-platform C++ library for recording, playing, and processing audio on Windows, Android, Linux, iOS, and macOS.
Loading...
Searching...
No Matches
AudioDevice.h
Go to the documentation of this file.
1#pragma once
2#include "HephAudioShared.h"
3#include <string>
4#include <cinttypes>
5
8namespace HephAudio
9{
11 {
12 Null = 0,
13
18 Render = 1,
19
25
31 };
32
33 inline constexpr AudioDeviceType operator|(const AudioDeviceType& lhs, const AudioDeviceType& rhs)
34 {
35 return (AudioDeviceType)((uint8_t)lhs | (uint8_t)rhs);
36 }
37
38 inline constexpr AudioDeviceType& operator|=(AudioDeviceType& lhs, const AudioDeviceType& rhs)
39 {
40 lhs = lhs | rhs;
41 return lhs;
42 }
43
44 inline constexpr AudioDeviceType operator&(const AudioDeviceType& lhs, const AudioDeviceType& rhs)
45 {
46 return (AudioDeviceType)((uint8_t)lhs & (uint8_t)rhs);
47 }
48
49 inline constexpr AudioDeviceType& operator&=(AudioDeviceType& lhs, const AudioDeviceType& rhs)
50 {
51 lhs = lhs & rhs;
52 return lhs;
53 }
54
60 {
65 std::string id;
66
71 std::string name;
72
78
84
87 };
88}
AudioDeviceType
Definition AudioDevice.h:11
@ Capture
Definition AudioDevice.h:24
@ All
Definition AudioDevice.h:30
@ Render
Definition AudioDevice.h:18
#define HEPH_API
Definition HephShared.h:124
stores information about an audio device.
Definition AudioDevice.h:60
AudioDeviceType type
Definition AudioDevice.h:77
std::string name
Definition AudioDevice.h:71
std::string id
Definition AudioDevice.h:65
bool isDefault
Definition AudioDevice.h:83