This commit is contained in:
2022-07-14 20:03:21 +02:00
parent a616970ce2
commit ff996e8e55
21 changed files with 1310 additions and 157 deletions

13
AsuroTool/AudioApi.h Normal file
View File

@@ -0,0 +1,13 @@
#pragma once
#include <mmdeviceapi.h>
#include "ApplicationData.h"
HRESULT getDeviceProperty(IPropertyStore* propertyStore, const PROPERTYKEY propertyKey, PROPVARIANT* outData);
HRESULT getDevicePropertyString(IPropertyStore* propertyStore, const PROPERTYKEY propertyKey, PROPVARIANT* outData, const wchar_t*& outString, const wchar_t* defaultStr = L"Unknown");
void setDefaultAudioDevice(ApplicationData* appData, const wchar_t* deviceId, ERole role);
void loadAudioDevices(std::vector<AudioDevice>& deviceList, EDataFlow deviceType);
void reloadDeviceLists(ApplicationData* appData);
float getVolume(IAudioEndpointVolume* volumeInterface);
float getMeterValue(IAudioMeterInformation* meterInterface);