ReactOS  0.4.14-dev-317-g96040ec
mmdevapi.h
Go to the documentation of this file.
1 /*
2  * Copyright 2009 Maarten Lankhorst
3  *
4  * This library is free software; you can redistribute it and/or
5  * modify it under the terms of the GNU Lesser General Public
6  * License as published by the Free Software Foundation; either
7  * version 2.1 of the License, or (at your option) any later version.
8  *
9  * This library is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12  * Lesser General Public License for more details.
13  *
14  * You should have received a copy of the GNU Lesser General Public
15  * License along with this library; if not, write to the Free Software
16  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
17  */
18 
19 #pragma once
20 
22 extern void MMDevEnum_Free(void) DECLSPEC_HIDDEN;
23 
24 
25 /* Changes to this enum must be synced in drivers. */
27  Priority_Unavailable = 0, /* driver won't work */
28  Priority_Low, /* driver may work, but unlikely */
29  Priority_Neutral, /* driver makes no judgment */
30  Priority_Preferred /* driver thinks it's correct */
31 };
32 
33 typedef struct _DriverFuncs {
36  int priority;
37 
38  /* Returns a "priority" value for the driver. Highest priority wins.
39  * If multiple drivers think they are valid, they will return a
40  * priority value reflecting the likelihood that they are actually
41  * valid. See enum _DriverPriority. */
42  int (WINAPI *pGetPriority)(void);
43 
44  /* ids gets an array of human-friendly endpoint names
45  * keys gets an array of driver-specific stuff that is used
46  * in GetAudioEndpoint to identify the endpoint
47  * it is the caller's responsibility to free both arrays, and
48  * all of the elements in both arrays with HeapFree() */
49  HRESULT (WINAPI *pGetEndpointIDs)(EDataFlow flow, WCHAR ***ids,
51  HRESULT (WINAPI *pGetAudioEndpoint)(void *key, IMMDevice *dev,
52  IAudioClient **out);
53  HRESULT (WINAPI *pGetAudioSessionManager)(IMMDevice *device,
55  HRESULT (WINAPI *pGetPropValue)(GUID *guid,
56  const PROPERTYKEY *prop, PROPVARIANT *out);
57 } DriverFuncs;
58 
60 
61 typedef struct MMDevice {
65 
67 
72 } MMDevice;
73 
76 
IMMEndpoint IMMEndpoint_iface
Definition: mmdevapi.h:63
#define REFIID
Definition: guiddef.h:118
struct png_info_def **typedef void(__cdecl typeof(png_destroy_read_struct))(struct png_struct_def **
Definition: typeof.h:49
REFIID riid
Definition: precomp.h:44
IMMDevice IMMDevice_iface
Definition: mmdevapi.h:62
DriverFuncs drvs DECLSPEC_HIDDEN
Definition: mmdevapi.h:77
REFIID LPVOID * ppv
Definition: atlbase.h:39
HRESULT MMDevEnum_Create(REFIID riid, void **ppv) DECLSPEC_HIDDEN
Definition: devenum.c:881
IMMDevice * dev
Definition: mmdevapi.h:51
const GUID * guid
long LONG
Definition: pedump.c:60
Definition: devices.h:37
WCHAR GUID ** guids
Definition: mmdevapi.h:49
enum _EDataFlow EDataFlow
struct MMDevice MMDevice
HRESULT AudioClient_Create(MMDevice *parent, IAudioClient **ppv) DECLSPEC_HIDDEN
_DriverPriority
Definition: mmdevapi.h:26
int priority
Definition: mmdevapi.h:36
int(WINAPI *pGetPriority)(void)
r parent
Definition: btrfs.c:2869
WCHAR * drv_id
Definition: mmdevapi.h:71
__wchar_t WCHAR
Definition: xmlstorage.h:180
LONG HRESULT
Definition: typedefs.h:77
struct _DriverFuncs DriverFuncs
#define WINAPI
Definition: msvc.h:8
unsigned long DWORD
Definition: ntddk_ex.h:95
DWORD state
Definition: mmdevapi.h:69
void MMDevEnum_Free(void) DECLSPEC_HIDDEN
Definition: devenum.c:902
HKEY key
Definition: reg.c:42
const WCHAR drv_keyW[]
Definition: main.c:50
CRITICAL_SECTION crst
Definition: mmdevapi.h:66
DriverFuncs drvs
Definition: main.c:48
WCHAR *** ids
Definition: mmdevapi.h:49
unsigned int UINT
Definition: ndis.h:50
EDataFlow flow
Definition: mmdevapi.h:68
HRESULT(WINAPI *pGetEndpointIDs)(EDataFlow flow
const PROPERTYKEY * prop
Definition: mmdevapi.h:56
LONG ref
Definition: mmdevapi.h:64
WCHAR module_name[64]
Definition: mmdevapi.h:35
IAudioSessionManager2 ** out
Definition: mmdevapi.h:54
HMODULE module
Definition: mmdevapi.h:34
HRESULT AudioEndpointVolume_Create(MMDevice *parent, IAudioEndpointVolumeEx **ppv) DECLSPEC_HIDDEN
Definition: audiovolume.c:305
WCHAR GUID UINT UINT * default_index
Definition: mmdevapi.h:49
GUID devguid
Definition: mmdevapi.h:70
WCHAR GUID UINT * num
Definition: mmdevapi.h:49
IMMDevice IAudioClient ** out
Definition: mmdevapi.h:51