Go to the documentation of this file.
34 #include <mmdeviceapi.h>
53 if (in_pProps) in_pProps->GetValue(key, &
variant);
60 PropVariantInit(&other.variant);
77 PropVariantInit(&other.variant);
101 in_pDevice->OpenPropertyStore(STGM_READ, &
pProps);
108 other.pProps =
nullptr;
130 other.pProps =
nullptr;
161 other.pDevice =
nullptr;
190 other.pDevice =
nullptr;
234 LPWSTR pwszID =
NULL;
235 if (
pDevice->GetId(&pwszID) == S_OK)
239 szString[260 - 1] = 0;
242 CoTaskMemFree(pwszID);
264 Iterator(IMMDeviceCollection* in_pDevices, UINT in_i)
326 pEnumerator->EnumAudioEndpoints(eRender, DEVICE_STATEMASK_ALL, &
pDevices);
335 pEnumerator->EnumAudioEndpoints(eFlow, dwStateMask, &
pDevices);
345 other.pDevices =
nullptr;
371 other.pDevices =
nullptr;
409 __uuidof(MMDeviceEnumerator),
NULL,
410 CLSCTX_ALL, __uuidof(IMMDeviceEnumerator),
418 other.pEnumerator =
nullptr;
442 other.pEnumerator =
nullptr;
454 pEnumerator->GetDefaultAudioEndpoint(eRender, in_eRole, (IMMDevice**)&pDevice.
pDevice);
AkUInt32 GetDeviceID() const
virtual Device Item(AkUInt32 in_idx)=0
Returns the number of devices. This function can block.
DeviceProperty(const PROPERTYKEY &key, IPropertyStore *in_pProps)
DeviceCollection(IMMDeviceEnumerator *pEnumerator, EDataFlow eFlow, DWORD dwStateMask)
DeviceProperties(const DeviceProperties &other)=delete
DeviceEnumerator & operator=(const DeviceEnumerator &other)=delete
Iterator(IMMDeviceCollection *in_pDevices, UINT in_i)
void SetDevice(IMMDevice *in_pNew)
DeviceProperty GetProperty(const PROPERTYKEY &key)
virtual void Lock()=0
Gets item in_idx from the cache. Must be smaller than Count(). This function can block.
Device & operator=(const Device &other)
DeviceProperties & operator=(DeviceProperties &&other)
static const AkDeviceID AK_INVALID_DEVICE_ID
Invalid streaming device ID.
DeviceCollection(const DeviceCollection &other)=delete
DeviceProperties GetProperties() const
interface IMMDevice * pDevice
Device(const Device &other)
DeviceCollection & operator=(DeviceCollection &&other)
DeviceCollection(DeviceCollection &&other)
DeviceProperties & operator=(const DeviceProperties &other)=delete
Interface to access the IMMDevice cache. This avoids driver accesses.
DeviceProperty(const DeviceProperty &other)=delete
Iterator operator+(AkUInt32 inc) const
DeviceEnumerator(DeviceEnumerator &&other)
interface IMMDeviceCollection * pDevices
interface IMMDeviceEnumerator * pEnumerator
Device & operator=(Device &&other)
virtual AkUInt32 Count()=0
interface IMMDeviceCollection * pDevices
bool operator!=(const Iterator &in_rOp) const
DeviceProperty & operator=(const DeviceProperty &other)=delete
AkUInt32 operator-(Iterator const &rhs) const
DeviceEnumerator(const DeviceEnumerator &other)=delete
Iterator & operator++()
DeviceProperties(IMMDevice *in_pDevice)
virtual void Unlock()=0
For thread safety. If you iterate through all the devices, lock the enumerator to avoid changes....
bool operator==(const Iterator &in_rOp) const
DeviceProperty(DeviceProperty &&other)
DeviceCollection(IMMDeviceEnumerator *pEnumerator)
virtual Device FindDevice(AkUInt32 in_id)=0
For thread safety. See Lock()
Device & operator=(IMMDevice *pOther)
DeviceEnumerator & operator=(DeviceEnumerator &&other)
Device GetDefaultDevice(ERole in_eRole)
AkForceInline AkInt32 AkWideCharToChar(const wchar_t *in_pszUnicodeString, AkUInt32 in_uiOutBufferSize, char *io_pszAnsiString)
String conversion helper.
DeviceCollection & operator=(const DeviceCollection &other)=delete
Iterator & operator--()
static HashParams::HashType ComputeLowerCase(const char *in_pData)
DeviceProperty & operator=(DeviceProperty &&other)
DeviceProperties(DeviceProperties &&other)
Tell us about your project. We're here to help.
Register your project and we'll help you get started with no strings attached!
Get started with Wwise