Struct thl::AudioDeviceInfo#
-
struct AudioDeviceInfo#
Collaboration diagram for thl::AudioDeviceInfo:
Contains information about an audio device available on the system.
AudioDeviceInfo encapsulates the essential properties of an audio device, including its display name, unique identifier, type (input/output), and supported sample rates. This structure is primarily used when enumerating available devices and selecting a device for initialisation.
See also
AudioDeviceManager::enumerateInputDevices()
See also
AudioDeviceManager::enumerateOutputDevices()
See also
Public Functions
-
inline const void *device_id_ptr() const#
Gets a pointer to the device ID for internal use.
Note
This is primarily used internally when initialising devices.
- Returns:
Pointer to the internal device ID storage.
-
inline void *device_id_storage_ptr()#
Public Members
-
std::string m_name#
Human-readable name of the audio device.
This is the display name provided by the operating system or driver, suitable for showing to users in device selection interfaces.
-
DeviceType m_device_type = DeviceType::Playback#
Type of the audio device (input, output, or duplex).
Indicates whether this device is capable of audio capture (input), playback (output), or both (duplex).
-
std::vector<uint32_t> m_sample_rates#
List of sample rates supported by the device.
Contains the discrete sample rates that this device can operate at. Common values include 44100, 48000, 88200, 96000, etc.
Public Static Attributes
-
static constexpr size_t k_device_id_storage_size = 256#
-
inline const void *device_id_ptr() const#