[1166] | 1 | /*** Autogenerated by WIDL 6.4 from include/mmdeviceapi.idl - Do not edit ***/
|
---|
| 2 |
|
---|
| 3 | #ifdef _WIN32
|
---|
| 4 | #ifndef __REQUIRED_RPCNDR_H_VERSION__
|
---|
| 5 | #define __REQUIRED_RPCNDR_H_VERSION__ 475
|
---|
| 6 | #endif
|
---|
| 7 | #include <rpc.h>
|
---|
| 8 | #include <rpcndr.h>
|
---|
| 9 | #endif
|
---|
| 10 |
|
---|
| 11 | #ifndef COM_NO_WINDOWS_H
|
---|
| 12 | #include <windows.h>
|
---|
| 13 | #include <ole2.h>
|
---|
| 14 | #endif
|
---|
| 15 |
|
---|
| 16 | #ifndef __mmdeviceapi_h__
|
---|
| 17 | #define __mmdeviceapi_h__
|
---|
| 18 |
|
---|
| 19 | /* Forward declarations */
|
---|
| 20 |
|
---|
| 21 | #ifndef __IMMNotificationClient_FWD_DEFINED__
|
---|
| 22 | #define __IMMNotificationClient_FWD_DEFINED__
|
---|
| 23 | typedef interface IMMNotificationClient IMMNotificationClient;
|
---|
| 24 | #ifdef __cplusplus
|
---|
| 25 | interface IMMNotificationClient;
|
---|
| 26 | #endif /* __cplusplus */
|
---|
| 27 | #endif
|
---|
| 28 |
|
---|
| 29 | #ifndef __IMMDevice_FWD_DEFINED__
|
---|
| 30 | #define __IMMDevice_FWD_DEFINED__
|
---|
| 31 | typedef interface IMMDevice IMMDevice;
|
---|
| 32 | #ifdef __cplusplus
|
---|
| 33 | interface IMMDevice;
|
---|
| 34 | #endif /* __cplusplus */
|
---|
| 35 | #endif
|
---|
| 36 |
|
---|
| 37 | #ifndef __IMMDeviceCollection_FWD_DEFINED__
|
---|
| 38 | #define __IMMDeviceCollection_FWD_DEFINED__
|
---|
| 39 | typedef interface IMMDeviceCollection IMMDeviceCollection;
|
---|
| 40 | #ifdef __cplusplus
|
---|
| 41 | interface IMMDeviceCollection;
|
---|
| 42 | #endif /* __cplusplus */
|
---|
| 43 | #endif
|
---|
| 44 |
|
---|
| 45 | #ifndef __IMMEndpoint_FWD_DEFINED__
|
---|
| 46 | #define __IMMEndpoint_FWD_DEFINED__
|
---|
| 47 | typedef interface IMMEndpoint IMMEndpoint;
|
---|
| 48 | #ifdef __cplusplus
|
---|
| 49 | interface IMMEndpoint;
|
---|
| 50 | #endif /* __cplusplus */
|
---|
| 51 | #endif
|
---|
| 52 |
|
---|
| 53 | #ifndef __IMMDeviceEnumerator_FWD_DEFINED__
|
---|
| 54 | #define __IMMDeviceEnumerator_FWD_DEFINED__
|
---|
| 55 | typedef interface IMMDeviceEnumerator IMMDeviceEnumerator;
|
---|
| 56 | #ifdef __cplusplus
|
---|
| 57 | interface IMMDeviceEnumerator;
|
---|
| 58 | #endif /* __cplusplus */
|
---|
| 59 | #endif
|
---|
| 60 |
|
---|
| 61 | #ifndef __IMMDeviceActivator_FWD_DEFINED__
|
---|
| 62 | #define __IMMDeviceActivator_FWD_DEFINED__
|
---|
| 63 | typedef interface IMMDeviceActivator IMMDeviceActivator;
|
---|
| 64 | #ifdef __cplusplus
|
---|
| 65 | interface IMMDeviceActivator;
|
---|
| 66 | #endif /* __cplusplus */
|
---|
| 67 | #endif
|
---|
| 68 |
|
---|
| 69 | #ifndef __IActivateAudioInterfaceAsyncOperation_FWD_DEFINED__
|
---|
| 70 | #define __IActivateAudioInterfaceAsyncOperation_FWD_DEFINED__
|
---|
| 71 | typedef interface IActivateAudioInterfaceAsyncOperation IActivateAudioInterfaceAsyncOperation;
|
---|
| 72 | #ifdef __cplusplus
|
---|
| 73 | interface IActivateAudioInterfaceAsyncOperation;
|
---|
| 74 | #endif /* __cplusplus */
|
---|
| 75 | #endif
|
---|
| 76 |
|
---|
| 77 | #ifndef __IActivateAudioInterfaceCompletionHandler_FWD_DEFINED__
|
---|
| 78 | #define __IActivateAudioInterfaceCompletionHandler_FWD_DEFINED__
|
---|
| 79 | typedef interface IActivateAudioInterfaceCompletionHandler IActivateAudioInterfaceCompletionHandler;
|
---|
| 80 | #ifdef __cplusplus
|
---|
| 81 | interface IActivateAudioInterfaceCompletionHandler;
|
---|
| 82 | #endif /* __cplusplus */
|
---|
| 83 | #endif
|
---|
| 84 |
|
---|
| 85 | #ifndef __MMDeviceEnumerator_FWD_DEFINED__
|
---|
| 86 | #define __MMDeviceEnumerator_FWD_DEFINED__
|
---|
| 87 | #ifdef __cplusplus
|
---|
| 88 | typedef class MMDeviceEnumerator MMDeviceEnumerator;
|
---|
| 89 | #else
|
---|
| 90 | typedef struct MMDeviceEnumerator MMDeviceEnumerator;
|
---|
| 91 | #endif /* defined __cplusplus */
|
---|
| 92 | #endif /* defined __MMDeviceEnumerator_FWD_DEFINED__ */
|
---|
| 93 |
|
---|
| 94 | /* Headers for imported files */
|
---|
| 95 |
|
---|
| 96 | #include <unknwn.h>
|
---|
| 97 | #include <propsys.h>
|
---|
| 98 |
|
---|
| 99 | #ifdef __cplusplus
|
---|
| 100 | extern "C" {
|
---|
| 101 | #endif
|
---|
| 102 |
|
---|
| 103 | #ifndef E_NOTFOUND
|
---|
| 104 | #define E_NOTFOUND HRESULT_FROM_WIN32(ERROR_NOT_FOUND)
|
---|
| 105 | #endif
|
---|
| 106 | #ifndef E_UNSUPPORTED_TYPE
|
---|
| 107 | #define E_UNSUPPORTED_TYPE HRESULT_FROM_WIN32(ERROR_UNSUPPORTED_TYPE)
|
---|
| 108 | #endif
|
---|
| 109 | DEFINE_GUID(DEVINTERFACE_AUDIO_RENDER, 0xe6327cad,0xdcec,0x4949,0xae,0x8a,0x99,0x1e,0x97,0x6a,0x79,0xd2);
|
---|
| 110 | DEFINE_GUID(DEVINTERFACE_AUDIO_CAPTURE, 0x2eef81be,0x33fa,0x4800,0x96,0x70,0x1c,0xd4,0x74,0x97,0x2c,0x3f);
|
---|
| 111 | #define DEVICE_STATE_ACTIVE 0x1
|
---|
| 112 | #define DEVICE_STATE_DISABLED 0x2
|
---|
| 113 | #define DEVICE_STATE_NOTPRESENT 0x4
|
---|
| 114 | #define DEVICE_STATE_UNPLUGGED 0x8
|
---|
| 115 | #define DEVICE_STATEMASK_ALL 0xf
|
---|
| 116 | DEFINE_PROPERTYKEY(PKEY_AudioEndpoint_FormFactor,0x1da5d803,0xd492,0x4edd,0x8c,0x23,0xe0,0xc0,0xff,0xee,0x7f,0x0e,0);
|
---|
| 117 | DEFINE_PROPERTYKEY(PKEY_AudioEndpoint_ControlPanelPageProvider,0x1da5d803,0xd492,0x4edd,0x8c,0x23,0xe0,0xc0,0xff,0xee,0x7f,0x0e,1);
|
---|
| 118 | DEFINE_PROPERTYKEY(PKEY_AudioEndpoint_Association,0x1da5d803,0xd492,0x4edd,0x8c,0x23,0xe0,0xc0,0xff,0xee,0x7f,0x0e,2);
|
---|
| 119 | DEFINE_PROPERTYKEY(PKEY_AudioEndpoint_PhysicalSpeakers,0x1da5d803,0xd492,0x4edd,0x8c,0x23,0xe0,0xc0,0xff,0xee,0x7f,0x0e,3);
|
---|
| 120 | DEFINE_PROPERTYKEY(PKEY_AudioEndpoint_GUID,0x1da5d803,0xd492,0x4edd,0x8c,0x23,0xe0,0xc0,0xff,0xee,0x7f,0x0e,4);
|
---|
| 121 | DEFINE_PROPERTYKEY(PKEY_AudioEndpoint_Disable_SysFx,0x1da5d803,0xd492,0x4edd,0x8c,0x23,0xe0,0xc0,0xff,0xee,0x7f,0x0e,5);
|
---|
| 122 | #define ENDPOINT_SYSFX_ENABLED 0
|
---|
| 123 | #define ENDPOINT_SYSFX_DISABLED 1
|
---|
| 124 | DEFINE_PROPERTYKEY(PKEY_AudioEndpoint_FullRangeSpeakers,0x1da5d803,0xd492,0x4edd,0x8c,0x23,0xe0,0xc0,0xff,0xee,0x7f,0x0e,6);
|
---|
| 125 | DEFINE_PROPERTYKEY(PKEY_AudioEndpoint_Supports_EventDriven_Mode,0x1da5d803,0xd492,0x4edd,0x8c,0x23,0xe0,0xc0,0xff,0xee,0x7f,0x0e,7);
|
---|
| 126 | DEFINE_PROPERTYKEY(PKEY_AudioEndpoint_JackSubType,0x1da5d803,0xd492,0x4edd,0x8c,0x23,0xe0,0xc0,0xff,0xee,0x7f,0x0e,8);
|
---|
| 127 | DEFINE_PROPERTYKEY(PKEY_AudioEngine_DeviceFormat,0xf19f064d,0x082c,0x4e27,0xbc,0x73,0x68,0x82,0xa1,0xbb,0x8e,0x4c,0);
|
---|
| 128 | DEFINE_PROPERTYKEY(PKEY_AudioEngine_OEMFormat,0xe4870e26,0x3cc5,0x4cd2,0xba,0x46,0xca,0x0a,0x9a,0x70,0xed,0x04,3);
|
---|
| 129 | typedef struct tagDIRECTX_AUDIO_ACTIVATION_PARAMS {
|
---|
| 130 | DWORD cbDirectXAudioActivationParams;
|
---|
| 131 | GUID guidAudioSession;
|
---|
| 132 | DWORD dwAudioStreamFlags;
|
---|
| 133 | } DIRECTX_AUDIO_ACTIVATION_PARAMS;
|
---|
| 134 | typedef struct tagDIRECTX_AUDIO_ACTIVATION_PARAMS *PDIRECTX_AUDIO_ACTIVATION_PARAMS;
|
---|
| 135 | typedef enum _EDataFlow {
|
---|
| 136 | eRender = 0,
|
---|
| 137 | eCapture = 1,
|
---|
| 138 | eAll = 2,
|
---|
| 139 | EDataFlow_enum_count = 3
|
---|
| 140 | } EDataFlow;
|
---|
| 141 | typedef enum _ERole {
|
---|
| 142 | eConsole = 0,
|
---|
| 143 | eMultimedia = 1,
|
---|
| 144 | eCommunications = 2,
|
---|
| 145 | ERole_enum_count = 3
|
---|
| 146 | } ERole;
|
---|
| 147 | typedef enum _EndpointFormFactor {
|
---|
| 148 | RemoteNetworkDevice = 0,
|
---|
| 149 | Speakers = 1,
|
---|
| 150 | LineLevel = 2,
|
---|
| 151 | Headphones = 3,
|
---|
| 152 | Microphone = 4,
|
---|
| 153 | Headset = 5,
|
---|
| 154 | Handset = 6,
|
---|
| 155 | UnknownDigitalPassthrough = 7,
|
---|
| 156 | SPDIF = 8,
|
---|
| 157 | DigitalAudioDisplayDevice = 9,
|
---|
| 158 | UnknownFormFactor = 10,
|
---|
| 159 | EndpointFormFactor_enum_count = 11
|
---|
| 160 | } EndpointFormFactor;
|
---|
| 161 | #define HDMI DigitalAudioDisplayDevice
|
---|
| 162 | /*****************************************************************************
|
---|
| 163 | * IMMNotificationClient interface
|
---|
| 164 | */
|
---|
| 165 | #ifndef __IMMNotificationClient_INTERFACE_DEFINED__
|
---|
| 166 | #define __IMMNotificationClient_INTERFACE_DEFINED__
|
---|
| 167 |
|
---|
| 168 | DEFINE_GUID(IID_IMMNotificationClient, 0x7991eec9, 0x7e89, 0x4d85, 0x83,0x90, 0x6c,0x70,0x3c,0xec,0x60,0xc0);
|
---|
| 169 | #if defined(__cplusplus) && !defined(CINTERFACE)
|
---|
| 170 | MIDL_INTERFACE("7991eec9-7e89-4d85-8390-6c703cec60c0")
|
---|
| 171 | IMMNotificationClient : public IUnknown
|
---|
| 172 | {
|
---|
| 173 | virtual HRESULT STDMETHODCALLTYPE OnDeviceStateChanged(
|
---|
| 174 | LPCWSTR pwstrDeviceId,
|
---|
| 175 | DWORD dwNewState) = 0;
|
---|
| 176 |
|
---|
| 177 | virtual HRESULT STDMETHODCALLTYPE OnDeviceAdded(
|
---|
| 178 | LPCWSTR pwstrDeviceId) = 0;
|
---|
| 179 |
|
---|
| 180 | virtual HRESULT STDMETHODCALLTYPE OnDeviceRemoved(
|
---|
| 181 | LPCWSTR pwstrDeviceId) = 0;
|
---|
| 182 |
|
---|
| 183 | virtual HRESULT STDMETHODCALLTYPE OnDefaultDeviceChanged(
|
---|
| 184 | EDataFlow flow,
|
---|
| 185 | ERole role,
|
---|
| 186 | LPCWSTR pwstrDeviceId) = 0;
|
---|
| 187 |
|
---|
| 188 | virtual HRESULT STDMETHODCALLTYPE OnPropertyValueChanged(
|
---|
| 189 | LPCWSTR pwstrDeviceId,
|
---|
| 190 | const PROPERTYKEY key) = 0;
|
---|
| 191 |
|
---|
| 192 | };
|
---|
| 193 | #ifdef __CRT_UUID_DECL
|
---|
| 194 | __CRT_UUID_DECL(IMMNotificationClient, 0x7991eec9, 0x7e89, 0x4d85, 0x83,0x90, 0x6c,0x70,0x3c,0xec,0x60,0xc0)
|
---|
| 195 | #endif
|
---|
| 196 | #else
|
---|
| 197 | typedef struct IMMNotificationClientVtbl {
|
---|
| 198 | BEGIN_INTERFACE
|
---|
| 199 |
|
---|
| 200 | /*** IUnknown methods ***/
|
---|
| 201 | HRESULT (STDMETHODCALLTYPE *QueryInterface)(
|
---|
| 202 | IMMNotificationClient *This,
|
---|
| 203 | REFIID riid,
|
---|
| 204 | void **ppvObject);
|
---|
| 205 |
|
---|
| 206 | ULONG (STDMETHODCALLTYPE *AddRef)(
|
---|
| 207 | IMMNotificationClient *This);
|
---|
| 208 |
|
---|
| 209 | ULONG (STDMETHODCALLTYPE *Release)(
|
---|
| 210 | IMMNotificationClient *This);
|
---|
| 211 |
|
---|
| 212 | /*** IMMNotificationClient methods ***/
|
---|
| 213 | HRESULT (STDMETHODCALLTYPE *OnDeviceStateChanged)(
|
---|
| 214 | IMMNotificationClient *This,
|
---|
| 215 | LPCWSTR pwstrDeviceId,
|
---|
| 216 | DWORD dwNewState);
|
---|
| 217 |
|
---|
| 218 | HRESULT (STDMETHODCALLTYPE *OnDeviceAdded)(
|
---|
| 219 | IMMNotificationClient *This,
|
---|
| 220 | LPCWSTR pwstrDeviceId);
|
---|
| 221 |
|
---|
| 222 | HRESULT (STDMETHODCALLTYPE *OnDeviceRemoved)(
|
---|
| 223 | IMMNotificationClient *This,
|
---|
| 224 | LPCWSTR pwstrDeviceId);
|
---|
| 225 |
|
---|
| 226 | HRESULT (STDMETHODCALLTYPE *OnDefaultDeviceChanged)(
|
---|
| 227 | IMMNotificationClient *This,
|
---|
| 228 | EDataFlow flow,
|
---|
| 229 | ERole role,
|
---|
| 230 | LPCWSTR pwstrDeviceId);
|
---|
| 231 |
|
---|
| 232 | HRESULT (STDMETHODCALLTYPE *OnPropertyValueChanged)(
|
---|
| 233 | IMMNotificationClient *This,
|
---|
| 234 | LPCWSTR pwstrDeviceId,
|
---|
| 235 | const PROPERTYKEY key);
|
---|
| 236 |
|
---|
| 237 | END_INTERFACE
|
---|
| 238 | } IMMNotificationClientVtbl;
|
---|
| 239 |
|
---|
| 240 | interface IMMNotificationClient {
|
---|
| 241 | CONST_VTBL IMMNotificationClientVtbl* lpVtbl;
|
---|
| 242 | };
|
---|
| 243 |
|
---|
| 244 | #ifdef COBJMACROS
|
---|
| 245 | #ifndef WIDL_C_INLINE_WRAPPERS
|
---|
| 246 | /*** IUnknown methods ***/
|
---|
| 247 | #define IMMNotificationClient_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
|
---|
| 248 | #define IMMNotificationClient_AddRef(This) (This)->lpVtbl->AddRef(This)
|
---|
| 249 | #define IMMNotificationClient_Release(This) (This)->lpVtbl->Release(This)
|
---|
| 250 | /*** IMMNotificationClient methods ***/
|
---|
| 251 | #define IMMNotificationClient_OnDeviceStateChanged(This,pwstrDeviceId,dwNewState) (This)->lpVtbl->OnDeviceStateChanged(This,pwstrDeviceId,dwNewState)
|
---|
| 252 | #define IMMNotificationClient_OnDeviceAdded(This,pwstrDeviceId) (This)->lpVtbl->OnDeviceAdded(This,pwstrDeviceId)
|
---|
| 253 | #define IMMNotificationClient_OnDeviceRemoved(This,pwstrDeviceId) (This)->lpVtbl->OnDeviceRemoved(This,pwstrDeviceId)
|
---|
| 254 | #define IMMNotificationClient_OnDefaultDeviceChanged(This,flow,role,pwstrDeviceId) (This)->lpVtbl->OnDefaultDeviceChanged(This,flow,role,pwstrDeviceId)
|
---|
| 255 | #define IMMNotificationClient_OnPropertyValueChanged(This,pwstrDeviceId,key) (This)->lpVtbl->OnPropertyValueChanged(This,pwstrDeviceId,key)
|
---|
| 256 | #else
|
---|
| 257 | /*** IUnknown methods ***/
|
---|
| 258 | static FORCEINLINE HRESULT IMMNotificationClient_QueryInterface(IMMNotificationClient* This,REFIID riid,void **ppvObject) {
|
---|
| 259 | return This->lpVtbl->QueryInterface(This,riid,ppvObject);
|
---|
| 260 | }
|
---|
| 261 | static FORCEINLINE ULONG IMMNotificationClient_AddRef(IMMNotificationClient* This) {
|
---|
| 262 | return This->lpVtbl->AddRef(This);
|
---|
| 263 | }
|
---|
| 264 | static FORCEINLINE ULONG IMMNotificationClient_Release(IMMNotificationClient* This) {
|
---|
| 265 | return This->lpVtbl->Release(This);
|
---|
| 266 | }
|
---|
| 267 | /*** IMMNotificationClient methods ***/
|
---|
| 268 | static FORCEINLINE HRESULT IMMNotificationClient_OnDeviceStateChanged(IMMNotificationClient* This,LPCWSTR pwstrDeviceId,DWORD dwNewState) {
|
---|
| 269 | return This->lpVtbl->OnDeviceStateChanged(This,pwstrDeviceId,dwNewState);
|
---|
| 270 | }
|
---|
| 271 | static FORCEINLINE HRESULT IMMNotificationClient_OnDeviceAdded(IMMNotificationClient* This,LPCWSTR pwstrDeviceId) {
|
---|
| 272 | return This->lpVtbl->OnDeviceAdded(This,pwstrDeviceId);
|
---|
| 273 | }
|
---|
| 274 | static FORCEINLINE HRESULT IMMNotificationClient_OnDeviceRemoved(IMMNotificationClient* This,LPCWSTR pwstrDeviceId) {
|
---|
| 275 | return This->lpVtbl->OnDeviceRemoved(This,pwstrDeviceId);
|
---|
| 276 | }
|
---|
| 277 | static FORCEINLINE HRESULT IMMNotificationClient_OnDefaultDeviceChanged(IMMNotificationClient* This,EDataFlow flow,ERole role,LPCWSTR pwstrDeviceId) {
|
---|
| 278 | return This->lpVtbl->OnDefaultDeviceChanged(This,flow,role,pwstrDeviceId);
|
---|
| 279 | }
|
---|
| 280 | static FORCEINLINE HRESULT IMMNotificationClient_OnPropertyValueChanged(IMMNotificationClient* This,LPCWSTR pwstrDeviceId,const PROPERTYKEY key) {
|
---|
| 281 | return This->lpVtbl->OnPropertyValueChanged(This,pwstrDeviceId,key);
|
---|
| 282 | }
|
---|
| 283 | #endif
|
---|
| 284 | #endif
|
---|
| 285 |
|
---|
| 286 | #endif
|
---|
| 287 |
|
---|
| 288 |
|
---|
| 289 | #endif /* __IMMNotificationClient_INTERFACE_DEFINED__ */
|
---|
| 290 |
|
---|
| 291 | /*****************************************************************************
|
---|
| 292 | * IMMDevice interface
|
---|
| 293 | */
|
---|
| 294 | #ifndef __IMMDevice_INTERFACE_DEFINED__
|
---|
| 295 | #define __IMMDevice_INTERFACE_DEFINED__
|
---|
| 296 |
|
---|
| 297 | DEFINE_GUID(IID_IMMDevice, 0xd666063f, 0x1587, 0x4e43, 0x81,0xf1, 0xb9,0x48,0xe8,0x07,0x36,0x3f);
|
---|
| 298 | #if defined(__cplusplus) && !defined(CINTERFACE)
|
---|
| 299 | MIDL_INTERFACE("d666063f-1587-4e43-81f1-b948e807363f")
|
---|
| 300 | IMMDevice : public IUnknown
|
---|
| 301 | {
|
---|
| 302 | virtual HRESULT STDMETHODCALLTYPE Activate(
|
---|
| 303 | REFIID iid,
|
---|
| 304 | DWORD dwClsCtx,
|
---|
| 305 | PROPVARIANT *pActivationParams,
|
---|
| 306 | void **ppv) = 0;
|
---|
| 307 |
|
---|
| 308 | virtual HRESULT STDMETHODCALLTYPE OpenPropertyStore(
|
---|
| 309 | DWORD stgmAccess,
|
---|
| 310 | IPropertyStore **ppProperties) = 0;
|
---|
| 311 |
|
---|
| 312 | virtual HRESULT STDMETHODCALLTYPE GetId(
|
---|
| 313 | LPWSTR *ppstrId) = 0;
|
---|
| 314 |
|
---|
| 315 | virtual HRESULT STDMETHODCALLTYPE GetState(
|
---|
| 316 | DWORD *pdwState) = 0;
|
---|
| 317 |
|
---|
| 318 | };
|
---|
| 319 | #ifdef __CRT_UUID_DECL
|
---|
| 320 | __CRT_UUID_DECL(IMMDevice, 0xd666063f, 0x1587, 0x4e43, 0x81,0xf1, 0xb9,0x48,0xe8,0x07,0x36,0x3f)
|
---|
| 321 | #endif
|
---|
| 322 | #else
|
---|
| 323 | typedef struct IMMDeviceVtbl {
|
---|
| 324 | BEGIN_INTERFACE
|
---|
| 325 |
|
---|
| 326 | /*** IUnknown methods ***/
|
---|
| 327 | HRESULT (STDMETHODCALLTYPE *QueryInterface)(
|
---|
| 328 | IMMDevice *This,
|
---|
| 329 | REFIID riid,
|
---|
| 330 | void **ppvObject);
|
---|
| 331 |
|
---|
| 332 | ULONG (STDMETHODCALLTYPE *AddRef)(
|
---|
| 333 | IMMDevice *This);
|
---|
| 334 |
|
---|
| 335 | ULONG (STDMETHODCALLTYPE *Release)(
|
---|
| 336 | IMMDevice *This);
|
---|
| 337 |
|
---|
| 338 | /*** IMMDevice methods ***/
|
---|
| 339 | HRESULT (STDMETHODCALLTYPE *Activate)(
|
---|
| 340 | IMMDevice *This,
|
---|
| 341 | REFIID iid,
|
---|
| 342 | DWORD dwClsCtx,
|
---|
| 343 | PROPVARIANT *pActivationParams,
|
---|
| 344 | void **ppv);
|
---|
| 345 |
|
---|
| 346 | HRESULT (STDMETHODCALLTYPE *OpenPropertyStore)(
|
---|
| 347 | IMMDevice *This,
|
---|
| 348 | DWORD stgmAccess,
|
---|
| 349 | IPropertyStore **ppProperties);
|
---|
| 350 |
|
---|
| 351 | HRESULT (STDMETHODCALLTYPE *GetId)(
|
---|
| 352 | IMMDevice *This,
|
---|
| 353 | LPWSTR *ppstrId);
|
---|
| 354 |
|
---|
| 355 | HRESULT (STDMETHODCALLTYPE *GetState)(
|
---|
| 356 | IMMDevice *This,
|
---|
| 357 | DWORD *pdwState);
|
---|
| 358 |
|
---|
| 359 | END_INTERFACE
|
---|
| 360 | } IMMDeviceVtbl;
|
---|
| 361 |
|
---|
| 362 | interface IMMDevice {
|
---|
| 363 | CONST_VTBL IMMDeviceVtbl* lpVtbl;
|
---|
| 364 | };
|
---|
| 365 |
|
---|
| 366 | #ifdef COBJMACROS
|
---|
| 367 | #ifndef WIDL_C_INLINE_WRAPPERS
|
---|
| 368 | /*** IUnknown methods ***/
|
---|
| 369 | #define IMMDevice_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
|
---|
| 370 | #define IMMDevice_AddRef(This) (This)->lpVtbl->AddRef(This)
|
---|
| 371 | #define IMMDevice_Release(This) (This)->lpVtbl->Release(This)
|
---|
| 372 | /*** IMMDevice methods ***/
|
---|
| 373 | #define IMMDevice_Activate(This,iid,dwClsCtx,pActivationParams,ppv) (This)->lpVtbl->Activate(This,iid,dwClsCtx,pActivationParams,ppv)
|
---|
| 374 | #define IMMDevice_OpenPropertyStore(This,stgmAccess,ppProperties) (This)->lpVtbl->OpenPropertyStore(This,stgmAccess,ppProperties)
|
---|
| 375 | #define IMMDevice_GetId(This,ppstrId) (This)->lpVtbl->GetId(This,ppstrId)
|
---|
| 376 | #define IMMDevice_GetState(This,pdwState) (This)->lpVtbl->GetState(This,pdwState)
|
---|
| 377 | #else
|
---|
| 378 | /*** IUnknown methods ***/
|
---|
| 379 | static FORCEINLINE HRESULT IMMDevice_QueryInterface(IMMDevice* This,REFIID riid,void **ppvObject) {
|
---|
| 380 | return This->lpVtbl->QueryInterface(This,riid,ppvObject);
|
---|
| 381 | }
|
---|
| 382 | static FORCEINLINE ULONG IMMDevice_AddRef(IMMDevice* This) {
|
---|
| 383 | return This->lpVtbl->AddRef(This);
|
---|
| 384 | }
|
---|
| 385 | static FORCEINLINE ULONG IMMDevice_Release(IMMDevice* This) {
|
---|
| 386 | return This->lpVtbl->Release(This);
|
---|
| 387 | }
|
---|
| 388 | /*** IMMDevice methods ***/
|
---|
| 389 | static FORCEINLINE HRESULT IMMDevice_Activate(IMMDevice* This,REFIID iid,DWORD dwClsCtx,PROPVARIANT *pActivationParams,void **ppv) {
|
---|
| 390 | return This->lpVtbl->Activate(This,iid,dwClsCtx,pActivationParams,ppv);
|
---|
| 391 | }
|
---|
| 392 | static FORCEINLINE HRESULT IMMDevice_OpenPropertyStore(IMMDevice* This,DWORD stgmAccess,IPropertyStore **ppProperties) {
|
---|
| 393 | return This->lpVtbl->OpenPropertyStore(This,stgmAccess,ppProperties);
|
---|
| 394 | }
|
---|
| 395 | static FORCEINLINE HRESULT IMMDevice_GetId(IMMDevice* This,LPWSTR *ppstrId) {
|
---|
| 396 | return This->lpVtbl->GetId(This,ppstrId);
|
---|
| 397 | }
|
---|
| 398 | static FORCEINLINE HRESULT IMMDevice_GetState(IMMDevice* This,DWORD *pdwState) {
|
---|
| 399 | return This->lpVtbl->GetState(This,pdwState);
|
---|
| 400 | }
|
---|
| 401 | #endif
|
---|
| 402 | #endif
|
---|
| 403 |
|
---|
| 404 | #endif
|
---|
| 405 |
|
---|
| 406 |
|
---|
| 407 | #endif /* __IMMDevice_INTERFACE_DEFINED__ */
|
---|
| 408 |
|
---|
| 409 | /*****************************************************************************
|
---|
| 410 | * IMMDeviceCollection interface
|
---|
| 411 | */
|
---|
| 412 | #ifndef __IMMDeviceCollection_INTERFACE_DEFINED__
|
---|
| 413 | #define __IMMDeviceCollection_INTERFACE_DEFINED__
|
---|
| 414 |
|
---|
| 415 | DEFINE_GUID(IID_IMMDeviceCollection, 0x0bd7a1be, 0x7a1a, 0x44db, 0x83,0x97, 0xcc,0x53,0x92,0x38,0x7b,0x5e);
|
---|
| 416 | #if defined(__cplusplus) && !defined(CINTERFACE)
|
---|
| 417 | MIDL_INTERFACE("0bd7a1be-7a1a-44db-8397-cc5392387b5e")
|
---|
| 418 | IMMDeviceCollection : public IUnknown
|
---|
| 419 | {
|
---|
| 420 | virtual HRESULT STDMETHODCALLTYPE GetCount(
|
---|
| 421 | UINT *pcDevices) = 0;
|
---|
| 422 |
|
---|
| 423 | virtual HRESULT STDMETHODCALLTYPE Item(
|
---|
| 424 | UINT nDevice,
|
---|
| 425 | IMMDevice **ppdevice) = 0;
|
---|
| 426 |
|
---|
| 427 | };
|
---|
| 428 | #ifdef __CRT_UUID_DECL
|
---|
| 429 | __CRT_UUID_DECL(IMMDeviceCollection, 0x0bd7a1be, 0x7a1a, 0x44db, 0x83,0x97, 0xcc,0x53,0x92,0x38,0x7b,0x5e)
|
---|
| 430 | #endif
|
---|
| 431 | #else
|
---|
| 432 | typedef struct IMMDeviceCollectionVtbl {
|
---|
| 433 | BEGIN_INTERFACE
|
---|
| 434 |
|
---|
| 435 | /*** IUnknown methods ***/
|
---|
| 436 | HRESULT (STDMETHODCALLTYPE *QueryInterface)(
|
---|
| 437 | IMMDeviceCollection *This,
|
---|
| 438 | REFIID riid,
|
---|
| 439 | void **ppvObject);
|
---|
| 440 |
|
---|
| 441 | ULONG (STDMETHODCALLTYPE *AddRef)(
|
---|
| 442 | IMMDeviceCollection *This);
|
---|
| 443 |
|
---|
| 444 | ULONG (STDMETHODCALLTYPE *Release)(
|
---|
| 445 | IMMDeviceCollection *This);
|
---|
| 446 |
|
---|
| 447 | /*** IMMDeviceCollection methods ***/
|
---|
| 448 | HRESULT (STDMETHODCALLTYPE *GetCount)(
|
---|
| 449 | IMMDeviceCollection *This,
|
---|
| 450 | UINT *pcDevices);
|
---|
| 451 |
|
---|
| 452 | HRESULT (STDMETHODCALLTYPE *Item)(
|
---|
| 453 | IMMDeviceCollection *This,
|
---|
| 454 | UINT nDevice,
|
---|
| 455 | IMMDevice **ppdevice);
|
---|
| 456 |
|
---|
| 457 | END_INTERFACE
|
---|
| 458 | } IMMDeviceCollectionVtbl;
|
---|
| 459 |
|
---|
| 460 | interface IMMDeviceCollection {
|
---|
| 461 | CONST_VTBL IMMDeviceCollectionVtbl* lpVtbl;
|
---|
| 462 | };
|
---|
| 463 |
|
---|
| 464 | #ifdef COBJMACROS
|
---|
| 465 | #ifndef WIDL_C_INLINE_WRAPPERS
|
---|
| 466 | /*** IUnknown methods ***/
|
---|
| 467 | #define IMMDeviceCollection_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
|
---|
| 468 | #define IMMDeviceCollection_AddRef(This) (This)->lpVtbl->AddRef(This)
|
---|
| 469 | #define IMMDeviceCollection_Release(This) (This)->lpVtbl->Release(This)
|
---|
| 470 | /*** IMMDeviceCollection methods ***/
|
---|
| 471 | #define IMMDeviceCollection_GetCount(This,pcDevices) (This)->lpVtbl->GetCount(This,pcDevices)
|
---|
| 472 | #define IMMDeviceCollection_Item(This,nDevice,ppdevice) (This)->lpVtbl->Item(This,nDevice,ppdevice)
|
---|
| 473 | #else
|
---|
| 474 | /*** IUnknown methods ***/
|
---|
| 475 | static FORCEINLINE HRESULT IMMDeviceCollection_QueryInterface(IMMDeviceCollection* This,REFIID riid,void **ppvObject) {
|
---|
| 476 | return This->lpVtbl->QueryInterface(This,riid,ppvObject);
|
---|
| 477 | }
|
---|
| 478 | static FORCEINLINE ULONG IMMDeviceCollection_AddRef(IMMDeviceCollection* This) {
|
---|
| 479 | return This->lpVtbl->AddRef(This);
|
---|
| 480 | }
|
---|
| 481 | static FORCEINLINE ULONG IMMDeviceCollection_Release(IMMDeviceCollection* This) {
|
---|
| 482 | return This->lpVtbl->Release(This);
|
---|
| 483 | }
|
---|
| 484 | /*** IMMDeviceCollection methods ***/
|
---|
| 485 | static FORCEINLINE HRESULT IMMDeviceCollection_GetCount(IMMDeviceCollection* This,UINT *pcDevices) {
|
---|
| 486 | return This->lpVtbl->GetCount(This,pcDevices);
|
---|
| 487 | }
|
---|
| 488 | static FORCEINLINE HRESULT IMMDeviceCollection_Item(IMMDeviceCollection* This,UINT nDevice,IMMDevice **ppdevice) {
|
---|
| 489 | return This->lpVtbl->Item(This,nDevice,ppdevice);
|
---|
| 490 | }
|
---|
| 491 | #endif
|
---|
| 492 | #endif
|
---|
| 493 |
|
---|
| 494 | #endif
|
---|
| 495 |
|
---|
| 496 |
|
---|
| 497 | #endif /* __IMMDeviceCollection_INTERFACE_DEFINED__ */
|
---|
| 498 |
|
---|
| 499 | /*****************************************************************************
|
---|
| 500 | * IMMEndpoint interface
|
---|
| 501 | */
|
---|
| 502 | #ifndef __IMMEndpoint_INTERFACE_DEFINED__
|
---|
| 503 | #define __IMMEndpoint_INTERFACE_DEFINED__
|
---|
| 504 |
|
---|
| 505 | DEFINE_GUID(IID_IMMEndpoint, 0x1be09788, 0x6894, 0x4089, 0x85,0x86, 0x9a,0x2a,0x6c,0x26,0x5a,0xc5);
|
---|
| 506 | #if defined(__cplusplus) && !defined(CINTERFACE)
|
---|
| 507 | MIDL_INTERFACE("1be09788-6894-4089-8586-9a2a6c265ac5")
|
---|
| 508 | IMMEndpoint : public IUnknown
|
---|
| 509 | {
|
---|
| 510 | virtual HRESULT STDMETHODCALLTYPE GetDataFlow(
|
---|
| 511 | EDataFlow *pDataFlow) = 0;
|
---|
| 512 |
|
---|
| 513 | };
|
---|
| 514 | #ifdef __CRT_UUID_DECL
|
---|
| 515 | __CRT_UUID_DECL(IMMEndpoint, 0x1be09788, 0x6894, 0x4089, 0x85,0x86, 0x9a,0x2a,0x6c,0x26,0x5a,0xc5)
|
---|
| 516 | #endif
|
---|
| 517 | #else
|
---|
| 518 | typedef struct IMMEndpointVtbl {
|
---|
| 519 | BEGIN_INTERFACE
|
---|
| 520 |
|
---|
| 521 | /*** IUnknown methods ***/
|
---|
| 522 | HRESULT (STDMETHODCALLTYPE *QueryInterface)(
|
---|
| 523 | IMMEndpoint *This,
|
---|
| 524 | REFIID riid,
|
---|
| 525 | void **ppvObject);
|
---|
| 526 |
|
---|
| 527 | ULONG (STDMETHODCALLTYPE *AddRef)(
|
---|
| 528 | IMMEndpoint *This);
|
---|
| 529 |
|
---|
| 530 | ULONG (STDMETHODCALLTYPE *Release)(
|
---|
| 531 | IMMEndpoint *This);
|
---|
| 532 |
|
---|
| 533 | /*** IMMEndpoint methods ***/
|
---|
| 534 | HRESULT (STDMETHODCALLTYPE *GetDataFlow)(
|
---|
| 535 | IMMEndpoint *This,
|
---|
| 536 | EDataFlow *pDataFlow);
|
---|
| 537 |
|
---|
| 538 | END_INTERFACE
|
---|
| 539 | } IMMEndpointVtbl;
|
---|
| 540 |
|
---|
| 541 | interface IMMEndpoint {
|
---|
| 542 | CONST_VTBL IMMEndpointVtbl* lpVtbl;
|
---|
| 543 | };
|
---|
| 544 |
|
---|
| 545 | #ifdef COBJMACROS
|
---|
| 546 | #ifndef WIDL_C_INLINE_WRAPPERS
|
---|
| 547 | /*** IUnknown methods ***/
|
---|
| 548 | #define IMMEndpoint_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
|
---|
| 549 | #define IMMEndpoint_AddRef(This) (This)->lpVtbl->AddRef(This)
|
---|
| 550 | #define IMMEndpoint_Release(This) (This)->lpVtbl->Release(This)
|
---|
| 551 | /*** IMMEndpoint methods ***/
|
---|
| 552 | #define IMMEndpoint_GetDataFlow(This,pDataFlow) (This)->lpVtbl->GetDataFlow(This,pDataFlow)
|
---|
| 553 | #else
|
---|
| 554 | /*** IUnknown methods ***/
|
---|
| 555 | static FORCEINLINE HRESULT IMMEndpoint_QueryInterface(IMMEndpoint* This,REFIID riid,void **ppvObject) {
|
---|
| 556 | return This->lpVtbl->QueryInterface(This,riid,ppvObject);
|
---|
| 557 | }
|
---|
| 558 | static FORCEINLINE ULONG IMMEndpoint_AddRef(IMMEndpoint* This) {
|
---|
| 559 | return This->lpVtbl->AddRef(This);
|
---|
| 560 | }
|
---|
| 561 | static FORCEINLINE ULONG IMMEndpoint_Release(IMMEndpoint* This) {
|
---|
| 562 | return This->lpVtbl->Release(This);
|
---|
| 563 | }
|
---|
| 564 | /*** IMMEndpoint methods ***/
|
---|
| 565 | static FORCEINLINE HRESULT IMMEndpoint_GetDataFlow(IMMEndpoint* This,EDataFlow *pDataFlow) {
|
---|
| 566 | return This->lpVtbl->GetDataFlow(This,pDataFlow);
|
---|
| 567 | }
|
---|
| 568 | #endif
|
---|
| 569 | #endif
|
---|
| 570 |
|
---|
| 571 | #endif
|
---|
| 572 |
|
---|
| 573 |
|
---|
| 574 | #endif /* __IMMEndpoint_INTERFACE_DEFINED__ */
|
---|
| 575 |
|
---|
| 576 | /*****************************************************************************
|
---|
| 577 | * IMMDeviceEnumerator interface
|
---|
| 578 | */
|
---|
| 579 | #ifndef __IMMDeviceEnumerator_INTERFACE_DEFINED__
|
---|
| 580 | #define __IMMDeviceEnumerator_INTERFACE_DEFINED__
|
---|
| 581 |
|
---|
| 582 | DEFINE_GUID(IID_IMMDeviceEnumerator, 0xa95664d2, 0x9614, 0x4f35, 0xa7,0x46, 0xde,0x8d,0xb6,0x36,0x17,0xe6);
|
---|
| 583 | #if defined(__cplusplus) && !defined(CINTERFACE)
|
---|
| 584 | MIDL_INTERFACE("a95664d2-9614-4f35-a746-de8db63617e6")
|
---|
| 585 | IMMDeviceEnumerator : public IUnknown
|
---|
| 586 | {
|
---|
| 587 | virtual HRESULT STDMETHODCALLTYPE EnumAudioEndpoints(
|
---|
| 588 | EDataFlow dataFlow,
|
---|
| 589 | DWORD dwStateMask,
|
---|
| 590 | IMMDeviceCollection **ppDevices) = 0;
|
---|
| 591 |
|
---|
| 592 | virtual HRESULT STDMETHODCALLTYPE GetDefaultAudioEndpoint(
|
---|
| 593 | EDataFlow dataFlow,
|
---|
| 594 | ERole role,
|
---|
| 595 | IMMDevice **ppEndpoint) = 0;
|
---|
| 596 |
|
---|
| 597 | virtual HRESULT STDMETHODCALLTYPE GetDevice(
|
---|
| 598 | LPCWSTR pwstrId,
|
---|
| 599 | IMMDevice **ppDevice) = 0;
|
---|
| 600 |
|
---|
| 601 | virtual HRESULT STDMETHODCALLTYPE RegisterEndpointNotificationCallback(
|
---|
| 602 | IMMNotificationClient *pClient) = 0;
|
---|
| 603 |
|
---|
| 604 | virtual HRESULT STDMETHODCALLTYPE UnregisterEndpointNotificationCallback(
|
---|
| 605 | IMMNotificationClient *pClient) = 0;
|
---|
| 606 |
|
---|
| 607 | };
|
---|
| 608 | #ifdef __CRT_UUID_DECL
|
---|
| 609 | __CRT_UUID_DECL(IMMDeviceEnumerator, 0xa95664d2, 0x9614, 0x4f35, 0xa7,0x46, 0xde,0x8d,0xb6,0x36,0x17,0xe6)
|
---|
| 610 | #endif
|
---|
| 611 | #else
|
---|
| 612 | typedef struct IMMDeviceEnumeratorVtbl {
|
---|
| 613 | BEGIN_INTERFACE
|
---|
| 614 |
|
---|
| 615 | /*** IUnknown methods ***/
|
---|
| 616 | HRESULT (STDMETHODCALLTYPE *QueryInterface)(
|
---|
| 617 | IMMDeviceEnumerator *This,
|
---|
| 618 | REFIID riid,
|
---|
| 619 | void **ppvObject);
|
---|
| 620 |
|
---|
| 621 | ULONG (STDMETHODCALLTYPE *AddRef)(
|
---|
| 622 | IMMDeviceEnumerator *This);
|
---|
| 623 |
|
---|
| 624 | ULONG (STDMETHODCALLTYPE *Release)(
|
---|
| 625 | IMMDeviceEnumerator *This);
|
---|
| 626 |
|
---|
| 627 | /*** IMMDeviceEnumerator methods ***/
|
---|
| 628 | HRESULT (STDMETHODCALLTYPE *EnumAudioEndpoints)(
|
---|
| 629 | IMMDeviceEnumerator *This,
|
---|
| 630 | EDataFlow dataFlow,
|
---|
| 631 | DWORD dwStateMask,
|
---|
| 632 | IMMDeviceCollection **ppDevices);
|
---|
| 633 |
|
---|
| 634 | HRESULT (STDMETHODCALLTYPE *GetDefaultAudioEndpoint)(
|
---|
| 635 | IMMDeviceEnumerator *This,
|
---|
| 636 | EDataFlow dataFlow,
|
---|
| 637 | ERole role,
|
---|
| 638 | IMMDevice **ppEndpoint);
|
---|
| 639 |
|
---|
| 640 | HRESULT (STDMETHODCALLTYPE *GetDevice)(
|
---|
| 641 | IMMDeviceEnumerator *This,
|
---|
| 642 | LPCWSTR pwstrId,
|
---|
| 643 | IMMDevice **ppDevice);
|
---|
| 644 |
|
---|
| 645 | HRESULT (STDMETHODCALLTYPE *RegisterEndpointNotificationCallback)(
|
---|
| 646 | IMMDeviceEnumerator *This,
|
---|
| 647 | IMMNotificationClient *pClient);
|
---|
| 648 |
|
---|
| 649 | HRESULT (STDMETHODCALLTYPE *UnregisterEndpointNotificationCallback)(
|
---|
| 650 | IMMDeviceEnumerator *This,
|
---|
| 651 | IMMNotificationClient *pClient);
|
---|
| 652 |
|
---|
| 653 | END_INTERFACE
|
---|
| 654 | } IMMDeviceEnumeratorVtbl;
|
---|
| 655 |
|
---|
| 656 | interface IMMDeviceEnumerator {
|
---|
| 657 | CONST_VTBL IMMDeviceEnumeratorVtbl* lpVtbl;
|
---|
| 658 | };
|
---|
| 659 |
|
---|
| 660 | #ifdef COBJMACROS
|
---|
| 661 | #ifndef WIDL_C_INLINE_WRAPPERS
|
---|
| 662 | /*** IUnknown methods ***/
|
---|
| 663 | #define IMMDeviceEnumerator_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
|
---|
| 664 | #define IMMDeviceEnumerator_AddRef(This) (This)->lpVtbl->AddRef(This)
|
---|
| 665 | #define IMMDeviceEnumerator_Release(This) (This)->lpVtbl->Release(This)
|
---|
| 666 | /*** IMMDeviceEnumerator methods ***/
|
---|
| 667 | #define IMMDeviceEnumerator_EnumAudioEndpoints(This,dataFlow,dwStateMask,ppDevices) (This)->lpVtbl->EnumAudioEndpoints(This,dataFlow,dwStateMask,ppDevices)
|
---|
| 668 | #define IMMDeviceEnumerator_GetDefaultAudioEndpoint(This,dataFlow,role,ppEndpoint) (This)->lpVtbl->GetDefaultAudioEndpoint(This,dataFlow,role,ppEndpoint)
|
---|
| 669 | #define IMMDeviceEnumerator_GetDevice(This,pwstrId,ppDevice) (This)->lpVtbl->GetDevice(This,pwstrId,ppDevice)
|
---|
| 670 | #define IMMDeviceEnumerator_RegisterEndpointNotificationCallback(This,pClient) (This)->lpVtbl->RegisterEndpointNotificationCallback(This,pClient)
|
---|
| 671 | #define IMMDeviceEnumerator_UnregisterEndpointNotificationCallback(This,pClient) (This)->lpVtbl->UnregisterEndpointNotificationCallback(This,pClient)
|
---|
| 672 | #else
|
---|
| 673 | /*** IUnknown methods ***/
|
---|
| 674 | static FORCEINLINE HRESULT IMMDeviceEnumerator_QueryInterface(IMMDeviceEnumerator* This,REFIID riid,void **ppvObject) {
|
---|
| 675 | return This->lpVtbl->QueryInterface(This,riid,ppvObject);
|
---|
| 676 | }
|
---|
| 677 | static FORCEINLINE ULONG IMMDeviceEnumerator_AddRef(IMMDeviceEnumerator* This) {
|
---|
| 678 | return This->lpVtbl->AddRef(This);
|
---|
| 679 | }
|
---|
| 680 | static FORCEINLINE ULONG IMMDeviceEnumerator_Release(IMMDeviceEnumerator* This) {
|
---|
| 681 | return This->lpVtbl->Release(This);
|
---|
| 682 | }
|
---|
| 683 | /*** IMMDeviceEnumerator methods ***/
|
---|
| 684 | static FORCEINLINE HRESULT IMMDeviceEnumerator_EnumAudioEndpoints(IMMDeviceEnumerator* This,EDataFlow dataFlow,DWORD dwStateMask,IMMDeviceCollection **ppDevices) {
|
---|
| 685 | return This->lpVtbl->EnumAudioEndpoints(This,dataFlow,dwStateMask,ppDevices);
|
---|
| 686 | }
|
---|
| 687 | static FORCEINLINE HRESULT IMMDeviceEnumerator_GetDefaultAudioEndpoint(IMMDeviceEnumerator* This,EDataFlow dataFlow,ERole role,IMMDevice **ppEndpoint) {
|
---|
| 688 | return This->lpVtbl->GetDefaultAudioEndpoint(This,dataFlow,role,ppEndpoint);
|
---|
| 689 | }
|
---|
| 690 | static FORCEINLINE HRESULT IMMDeviceEnumerator_GetDevice(IMMDeviceEnumerator* This,LPCWSTR pwstrId,IMMDevice **ppDevice) {
|
---|
| 691 | return This->lpVtbl->GetDevice(This,pwstrId,ppDevice);
|
---|
| 692 | }
|
---|
| 693 | static FORCEINLINE HRESULT IMMDeviceEnumerator_RegisterEndpointNotificationCallback(IMMDeviceEnumerator* This,IMMNotificationClient *pClient) {
|
---|
| 694 | return This->lpVtbl->RegisterEndpointNotificationCallback(This,pClient);
|
---|
| 695 | }
|
---|
| 696 | static FORCEINLINE HRESULT IMMDeviceEnumerator_UnregisterEndpointNotificationCallback(IMMDeviceEnumerator* This,IMMNotificationClient *pClient) {
|
---|
| 697 | return This->lpVtbl->UnregisterEndpointNotificationCallback(This,pClient);
|
---|
| 698 | }
|
---|
| 699 | #endif
|
---|
| 700 | #endif
|
---|
| 701 |
|
---|
| 702 | #endif
|
---|
| 703 |
|
---|
| 704 |
|
---|
| 705 | #endif /* __IMMDeviceEnumerator_INTERFACE_DEFINED__ */
|
---|
| 706 |
|
---|
| 707 | /*****************************************************************************
|
---|
| 708 | * IMMDeviceActivator interface
|
---|
| 709 | */
|
---|
| 710 | #ifndef __IMMDeviceActivator_INTERFACE_DEFINED__
|
---|
| 711 | #define __IMMDeviceActivator_INTERFACE_DEFINED__
|
---|
| 712 |
|
---|
| 713 | DEFINE_GUID(IID_IMMDeviceActivator, 0x3b0d0ea4, 0xd0a9, 0x4b0e, 0x93,0x5b, 0x09,0x51,0x67,0x46,0xfa,0xc0);
|
---|
| 714 | #if defined(__cplusplus) && !defined(CINTERFACE)
|
---|
| 715 | MIDL_INTERFACE("3b0d0ea4-d0a9-4b0e-935b-09516746fac0")
|
---|
| 716 | IMMDeviceActivator : public IUnknown
|
---|
| 717 | {
|
---|
| 718 | virtual HRESULT STDMETHODCALLTYPE Activate(
|
---|
| 719 | REFIID iid,
|
---|
| 720 | IMMDevice *pDevice,
|
---|
| 721 | PROPVARIANT *pActivationParams,
|
---|
| 722 | void **ppv) = 0;
|
---|
| 723 |
|
---|
| 724 | };
|
---|
| 725 | #ifdef __CRT_UUID_DECL
|
---|
| 726 | __CRT_UUID_DECL(IMMDeviceActivator, 0x3b0d0ea4, 0xd0a9, 0x4b0e, 0x93,0x5b, 0x09,0x51,0x67,0x46,0xfa,0xc0)
|
---|
| 727 | #endif
|
---|
| 728 | #else
|
---|
| 729 | typedef struct IMMDeviceActivatorVtbl {
|
---|
| 730 | BEGIN_INTERFACE
|
---|
| 731 |
|
---|
| 732 | /*** IUnknown methods ***/
|
---|
| 733 | HRESULT (STDMETHODCALLTYPE *QueryInterface)(
|
---|
| 734 | IMMDeviceActivator *This,
|
---|
| 735 | REFIID riid,
|
---|
| 736 | void **ppvObject);
|
---|
| 737 |
|
---|
| 738 | ULONG (STDMETHODCALLTYPE *AddRef)(
|
---|
| 739 | IMMDeviceActivator *This);
|
---|
| 740 |
|
---|
| 741 | ULONG (STDMETHODCALLTYPE *Release)(
|
---|
| 742 | IMMDeviceActivator *This);
|
---|
| 743 |
|
---|
| 744 | /*** IMMDeviceActivator methods ***/
|
---|
| 745 | HRESULT (STDMETHODCALLTYPE *Activate)(
|
---|
| 746 | IMMDeviceActivator *This,
|
---|
| 747 | REFIID iid,
|
---|
| 748 | IMMDevice *pDevice,
|
---|
| 749 | PROPVARIANT *pActivationParams,
|
---|
| 750 | void **ppv);
|
---|
| 751 |
|
---|
| 752 | END_INTERFACE
|
---|
| 753 | } IMMDeviceActivatorVtbl;
|
---|
| 754 |
|
---|
| 755 | interface IMMDeviceActivator {
|
---|
| 756 | CONST_VTBL IMMDeviceActivatorVtbl* lpVtbl;
|
---|
| 757 | };
|
---|
| 758 |
|
---|
| 759 | #ifdef COBJMACROS
|
---|
| 760 | #ifndef WIDL_C_INLINE_WRAPPERS
|
---|
| 761 | /*** IUnknown methods ***/
|
---|
| 762 | #define IMMDeviceActivator_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
|
---|
| 763 | #define IMMDeviceActivator_AddRef(This) (This)->lpVtbl->AddRef(This)
|
---|
| 764 | #define IMMDeviceActivator_Release(This) (This)->lpVtbl->Release(This)
|
---|
| 765 | /*** IMMDeviceActivator methods ***/
|
---|
| 766 | #define IMMDeviceActivator_Activate(This,iid,pDevice,pActivationParams,ppv) (This)->lpVtbl->Activate(This,iid,pDevice,pActivationParams,ppv)
|
---|
| 767 | #else
|
---|
| 768 | /*** IUnknown methods ***/
|
---|
| 769 | static FORCEINLINE HRESULT IMMDeviceActivator_QueryInterface(IMMDeviceActivator* This,REFIID riid,void **ppvObject) {
|
---|
| 770 | return This->lpVtbl->QueryInterface(This,riid,ppvObject);
|
---|
| 771 | }
|
---|
| 772 | static FORCEINLINE ULONG IMMDeviceActivator_AddRef(IMMDeviceActivator* This) {
|
---|
| 773 | return This->lpVtbl->AddRef(This);
|
---|
| 774 | }
|
---|
| 775 | static FORCEINLINE ULONG IMMDeviceActivator_Release(IMMDeviceActivator* This) {
|
---|
| 776 | return This->lpVtbl->Release(This);
|
---|
| 777 | }
|
---|
| 778 | /*** IMMDeviceActivator methods ***/
|
---|
| 779 | static FORCEINLINE HRESULT IMMDeviceActivator_Activate(IMMDeviceActivator* This,REFIID iid,IMMDevice *pDevice,PROPVARIANT *pActivationParams,void **ppv) {
|
---|
| 780 | return This->lpVtbl->Activate(This,iid,pDevice,pActivationParams,ppv);
|
---|
| 781 | }
|
---|
| 782 | #endif
|
---|
| 783 | #endif
|
---|
| 784 |
|
---|
| 785 | #endif
|
---|
| 786 |
|
---|
| 787 |
|
---|
| 788 | #endif /* __IMMDeviceActivator_INTERFACE_DEFINED__ */
|
---|
| 789 |
|
---|
| 790 | typedef struct _AudioExtensionParams {
|
---|
| 791 | LPARAM AddPageParam;
|
---|
| 792 | IMMDevice *pEndPoint;
|
---|
| 793 | IMMDevice *pPnpInterface;
|
---|
| 794 | IMMDevice *pPnpDevnode;
|
---|
| 795 | } AudioExtensionParams;
|
---|
| 796 | /*****************************************************************************
|
---|
| 797 | * IActivateAudioInterfaceAsyncOperation interface
|
---|
| 798 | */
|
---|
| 799 | #ifndef __IActivateAudioInterfaceAsyncOperation_INTERFACE_DEFINED__
|
---|
| 800 | #define __IActivateAudioInterfaceAsyncOperation_INTERFACE_DEFINED__
|
---|
| 801 |
|
---|
| 802 | DEFINE_GUID(IID_IActivateAudioInterfaceAsyncOperation, 0x72a22d78, 0xcde4, 0x431d, 0xb8,0xcc, 0x84,0x3a,0x71,0x19,0x9b,0x6d);
|
---|
| 803 | #if defined(__cplusplus) && !defined(CINTERFACE)
|
---|
| 804 | MIDL_INTERFACE("72a22d78-cde4-431d-b8cc-843a71199b6d")
|
---|
| 805 | IActivateAudioInterfaceAsyncOperation : public IUnknown
|
---|
| 806 | {
|
---|
| 807 | virtual HRESULT STDMETHODCALLTYPE GetActivateResult(
|
---|
| 808 | HRESULT *result,
|
---|
| 809 | IUnknown **iface) = 0;
|
---|
| 810 |
|
---|
| 811 | };
|
---|
| 812 | #ifdef __CRT_UUID_DECL
|
---|
| 813 | __CRT_UUID_DECL(IActivateAudioInterfaceAsyncOperation, 0x72a22d78, 0xcde4, 0x431d, 0xb8,0xcc, 0x84,0x3a,0x71,0x19,0x9b,0x6d)
|
---|
| 814 | #endif
|
---|
| 815 | #else
|
---|
| 816 | typedef struct IActivateAudioInterfaceAsyncOperationVtbl {
|
---|
| 817 | BEGIN_INTERFACE
|
---|
| 818 |
|
---|
| 819 | /*** IUnknown methods ***/
|
---|
| 820 | HRESULT (STDMETHODCALLTYPE *QueryInterface)(
|
---|
| 821 | IActivateAudioInterfaceAsyncOperation *This,
|
---|
| 822 | REFIID riid,
|
---|
| 823 | void **ppvObject);
|
---|
| 824 |
|
---|
| 825 | ULONG (STDMETHODCALLTYPE *AddRef)(
|
---|
| 826 | IActivateAudioInterfaceAsyncOperation *This);
|
---|
| 827 |
|
---|
| 828 | ULONG (STDMETHODCALLTYPE *Release)(
|
---|
| 829 | IActivateAudioInterfaceAsyncOperation *This);
|
---|
| 830 |
|
---|
| 831 | /*** IActivateAudioInterfaceAsyncOperation methods ***/
|
---|
| 832 | HRESULT (STDMETHODCALLTYPE *GetActivateResult)(
|
---|
| 833 | IActivateAudioInterfaceAsyncOperation *This,
|
---|
| 834 | HRESULT *result,
|
---|
| 835 | IUnknown **iface);
|
---|
| 836 |
|
---|
| 837 | END_INTERFACE
|
---|
| 838 | } IActivateAudioInterfaceAsyncOperationVtbl;
|
---|
| 839 |
|
---|
| 840 | interface IActivateAudioInterfaceAsyncOperation {
|
---|
| 841 | CONST_VTBL IActivateAudioInterfaceAsyncOperationVtbl* lpVtbl;
|
---|
| 842 | };
|
---|
| 843 |
|
---|
| 844 | #ifdef COBJMACROS
|
---|
| 845 | #ifndef WIDL_C_INLINE_WRAPPERS
|
---|
| 846 | /*** IUnknown methods ***/
|
---|
| 847 | #define IActivateAudioInterfaceAsyncOperation_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
|
---|
| 848 | #define IActivateAudioInterfaceAsyncOperation_AddRef(This) (This)->lpVtbl->AddRef(This)
|
---|
| 849 | #define IActivateAudioInterfaceAsyncOperation_Release(This) (This)->lpVtbl->Release(This)
|
---|
| 850 | /*** IActivateAudioInterfaceAsyncOperation methods ***/
|
---|
| 851 | #define IActivateAudioInterfaceAsyncOperation_GetActivateResult(This,result,iface) (This)->lpVtbl->GetActivateResult(This,result,iface)
|
---|
| 852 | #else
|
---|
| 853 | /*** IUnknown methods ***/
|
---|
| 854 | static FORCEINLINE HRESULT IActivateAudioInterfaceAsyncOperation_QueryInterface(IActivateAudioInterfaceAsyncOperation* This,REFIID riid,void **ppvObject) {
|
---|
| 855 | return This->lpVtbl->QueryInterface(This,riid,ppvObject);
|
---|
| 856 | }
|
---|
| 857 | static FORCEINLINE ULONG IActivateAudioInterfaceAsyncOperation_AddRef(IActivateAudioInterfaceAsyncOperation* This) {
|
---|
| 858 | return This->lpVtbl->AddRef(This);
|
---|
| 859 | }
|
---|
| 860 | static FORCEINLINE ULONG IActivateAudioInterfaceAsyncOperation_Release(IActivateAudioInterfaceAsyncOperation* This) {
|
---|
| 861 | return This->lpVtbl->Release(This);
|
---|
| 862 | }
|
---|
| 863 | /*** IActivateAudioInterfaceAsyncOperation methods ***/
|
---|
| 864 | static FORCEINLINE HRESULT IActivateAudioInterfaceAsyncOperation_GetActivateResult(IActivateAudioInterfaceAsyncOperation* This,HRESULT *result,IUnknown **iface) {
|
---|
| 865 | return This->lpVtbl->GetActivateResult(This,result,iface);
|
---|
| 866 | }
|
---|
| 867 | #endif
|
---|
| 868 | #endif
|
---|
| 869 |
|
---|
| 870 | #endif
|
---|
| 871 |
|
---|
| 872 |
|
---|
| 873 | #endif /* __IActivateAudioInterfaceAsyncOperation_INTERFACE_DEFINED__ */
|
---|
| 874 |
|
---|
| 875 | /*****************************************************************************
|
---|
| 876 | * IActivateAudioInterfaceCompletionHandler interface
|
---|
| 877 | */
|
---|
| 878 | #ifndef __IActivateAudioInterfaceCompletionHandler_INTERFACE_DEFINED__
|
---|
| 879 | #define __IActivateAudioInterfaceCompletionHandler_INTERFACE_DEFINED__
|
---|
| 880 |
|
---|
| 881 | DEFINE_GUID(IID_IActivateAudioInterfaceCompletionHandler, 0x41d949ab, 0x9862, 0x444a, 0x80,0xf6, 0xc2,0x61,0x33,0x4d,0xa5,0xeb);
|
---|
| 882 | #if defined(__cplusplus) && !defined(CINTERFACE)
|
---|
| 883 | MIDL_INTERFACE("41d949ab-9862-444a-80f6-c261334da5eb")
|
---|
| 884 | IActivateAudioInterfaceCompletionHandler : public IUnknown
|
---|
| 885 | {
|
---|
| 886 | virtual HRESULT STDMETHODCALLTYPE ActivateCompleted(
|
---|
| 887 | IActivateAudioInterfaceAsyncOperation *op) = 0;
|
---|
| 888 |
|
---|
| 889 | };
|
---|
| 890 | #ifdef __CRT_UUID_DECL
|
---|
| 891 | __CRT_UUID_DECL(IActivateAudioInterfaceCompletionHandler, 0x41d949ab, 0x9862, 0x444a, 0x80,0xf6, 0xc2,0x61,0x33,0x4d,0xa5,0xeb)
|
---|
| 892 | #endif
|
---|
| 893 | #else
|
---|
| 894 | typedef struct IActivateAudioInterfaceCompletionHandlerVtbl {
|
---|
| 895 | BEGIN_INTERFACE
|
---|
| 896 |
|
---|
| 897 | /*** IUnknown methods ***/
|
---|
| 898 | HRESULT (STDMETHODCALLTYPE *QueryInterface)(
|
---|
| 899 | IActivateAudioInterfaceCompletionHandler *This,
|
---|
| 900 | REFIID riid,
|
---|
| 901 | void **ppvObject);
|
---|
| 902 |
|
---|
| 903 | ULONG (STDMETHODCALLTYPE *AddRef)(
|
---|
| 904 | IActivateAudioInterfaceCompletionHandler *This);
|
---|
| 905 |
|
---|
| 906 | ULONG (STDMETHODCALLTYPE *Release)(
|
---|
| 907 | IActivateAudioInterfaceCompletionHandler *This);
|
---|
| 908 |
|
---|
| 909 | /*** IActivateAudioInterfaceCompletionHandler methods ***/
|
---|
| 910 | HRESULT (STDMETHODCALLTYPE *ActivateCompleted)(
|
---|
| 911 | IActivateAudioInterfaceCompletionHandler *This,
|
---|
| 912 | IActivateAudioInterfaceAsyncOperation *op);
|
---|
| 913 |
|
---|
| 914 | END_INTERFACE
|
---|
| 915 | } IActivateAudioInterfaceCompletionHandlerVtbl;
|
---|
| 916 |
|
---|
| 917 | interface IActivateAudioInterfaceCompletionHandler {
|
---|
| 918 | CONST_VTBL IActivateAudioInterfaceCompletionHandlerVtbl* lpVtbl;
|
---|
| 919 | };
|
---|
| 920 |
|
---|
| 921 | #ifdef COBJMACROS
|
---|
| 922 | #ifndef WIDL_C_INLINE_WRAPPERS
|
---|
| 923 | /*** IUnknown methods ***/
|
---|
| 924 | #define IActivateAudioInterfaceCompletionHandler_QueryInterface(This,riid,ppvObject) (This)->lpVtbl->QueryInterface(This,riid,ppvObject)
|
---|
| 925 | #define IActivateAudioInterfaceCompletionHandler_AddRef(This) (This)->lpVtbl->AddRef(This)
|
---|
| 926 | #define IActivateAudioInterfaceCompletionHandler_Release(This) (This)->lpVtbl->Release(This)
|
---|
| 927 | /*** IActivateAudioInterfaceCompletionHandler methods ***/
|
---|
| 928 | #define IActivateAudioInterfaceCompletionHandler_ActivateCompleted(This,op) (This)->lpVtbl->ActivateCompleted(This,op)
|
---|
| 929 | #else
|
---|
| 930 | /*** IUnknown methods ***/
|
---|
| 931 | static FORCEINLINE HRESULT IActivateAudioInterfaceCompletionHandler_QueryInterface(IActivateAudioInterfaceCompletionHandler* This,REFIID riid,void **ppvObject) {
|
---|
| 932 | return This->lpVtbl->QueryInterface(This,riid,ppvObject);
|
---|
| 933 | }
|
---|
| 934 | static FORCEINLINE ULONG IActivateAudioInterfaceCompletionHandler_AddRef(IActivateAudioInterfaceCompletionHandler* This) {
|
---|
| 935 | return This->lpVtbl->AddRef(This);
|
---|
| 936 | }
|
---|
| 937 | static FORCEINLINE ULONG IActivateAudioInterfaceCompletionHandler_Release(IActivateAudioInterfaceCompletionHandler* This) {
|
---|
| 938 | return This->lpVtbl->Release(This);
|
---|
| 939 | }
|
---|
| 940 | /*** IActivateAudioInterfaceCompletionHandler methods ***/
|
---|
| 941 | static FORCEINLINE HRESULT IActivateAudioInterfaceCompletionHandler_ActivateCompleted(IActivateAudioInterfaceCompletionHandler* This,IActivateAudioInterfaceAsyncOperation *op) {
|
---|
| 942 | return This->lpVtbl->ActivateCompleted(This,op);
|
---|
| 943 | }
|
---|
| 944 | #endif
|
---|
| 945 | #endif
|
---|
| 946 |
|
---|
| 947 | #endif
|
---|
| 948 |
|
---|
| 949 |
|
---|
| 950 | #endif /* __IActivateAudioInterfaceCompletionHandler_INTERFACE_DEFINED__ */
|
---|
| 951 |
|
---|
| 952 | HRESULT WINAPI ActivateAudioInterfaceAsync(
|
---|
| 953 | const WCHAR *path, REFIID riid, PROPVARIANT *params,
|
---|
| 954 | IActivateAudioInterfaceCompletionHandler *done_handler,
|
---|
| 955 | IActivateAudioInterfaceAsyncOperation **op);
|
---|
| 956 | #ifndef __MMDeviceAPILib_LIBRARY_DEFINED__
|
---|
| 957 | #define __MMDeviceAPILib_LIBRARY_DEFINED__
|
---|
| 958 |
|
---|
| 959 | DEFINE_GUID(LIBID_MMDeviceAPILib, 0x2fdaafa3, 0x7523, 0x4f66, 0x99,0x57, 0x9d,0x5e,0x7f,0xe6,0x98,0xf6);
|
---|
| 960 |
|
---|
| 961 | /*****************************************************************************
|
---|
| 962 | * MMDeviceEnumerator coclass
|
---|
| 963 | */
|
---|
| 964 |
|
---|
| 965 | DEFINE_GUID(CLSID_MMDeviceEnumerator, 0xbcde0395, 0xe52f, 0x467c, 0x8e,0x3d, 0xc4,0x57,0x92,0x91,0x69,0x2e);
|
---|
| 966 |
|
---|
| 967 | #ifdef __cplusplus
|
---|
| 968 | class DECLSPEC_UUID("bcde0395-e52f-467c-8e3d-c4579291692e") MMDeviceEnumerator;
|
---|
| 969 | #ifdef __CRT_UUID_DECL
|
---|
| 970 | __CRT_UUID_DECL(MMDeviceEnumerator, 0xbcde0395, 0xe52f, 0x467c, 0x8e,0x3d, 0xc4,0x57,0x92,0x91,0x69,0x2e)
|
---|
| 971 | #endif
|
---|
| 972 | #endif
|
---|
| 973 |
|
---|
| 974 | #endif /* __MMDeviceAPILib_LIBRARY_DEFINED__ */
|
---|
| 975 | /* Begin additional prototypes for all interfaces */
|
---|
| 976 |
|
---|
| 977 |
|
---|
| 978 | /* End additional prototypes */
|
---|
| 979 |
|
---|
| 980 | #ifdef __cplusplus
|
---|
| 981 | }
|
---|
| 982 | #endif
|
---|
| 983 |
|
---|
| 984 | #endif /* __mmdeviceapi_h__ */
|
---|