Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

470 lines
21 KiB

  1. /*==========================================================================;
  2. *
  3. * Copyright (C) 1995-1998 Microsoft Corporation. All Rights Reserved.
  4. *
  5. * File: dsprv.h
  6. * Content: DirectSound include file
  7. *@@BEGIN_MSINTERNAL
  8. * History:
  9. * Date By Reason
  10. * ==== == ======
  11. * 8/19/98 dereks Created.
  12. *@@END_MSINTERNAL
  13. *
  14. **************************************************************************/
  15. #ifndef __DSPRV_INCLUDED__
  16. #define __DSPRV_INCLUDED__
  17. #ifndef __DSOUND_INCLUDED__
  18. #error dsound.h not included
  19. #endif // __DSOUND_INCLUDED__
  20. #ifdef __cplusplus
  21. extern "C" {
  22. #endif // __cplusplus
  23. // DirectSound Private Component GUID {11AB3EC0-25EC-11d1-A4D8-00C04FC28ACA}
  24. DEFINE_GUID(CLSID_DirectSoundPrivate, 0x11ab3ec0, 0x25ec, 0x11d1, 0xa4, 0xd8, 0x0, 0xc0, 0x4f, 0xc2, 0x8a, 0xca);
  25. //
  26. // DirectSound Mixer Properties {84624F80-25EC-11d1-A4D8-00C04FC28ACA}
  27. //
  28. DEFINE_GUID(DSPROPSETID_DirectSoundMixer, 0x84624f80, 0x25ec, 0x11d1, 0xa4, 0xd8, 0x0, 0xc0, 0x4f, 0xc2, 0x8a, 0xca);
  29. typedef enum
  30. {
  31. DSPROPERTY_DIRECTSOUNDMIXER_SRCQUALITY,
  32. DSPROPERTY_DIRECTSOUNDMIXER_ACCELERATION,
  33. } DSPROPERTY_DIRECTSOUNDMIXER;
  34. typedef enum
  35. {
  36. DIRECTSOUNDMIXER_SRCQUALITY_WORST,
  37. DIRECTSOUNDMIXER_SRCQUALITY_PC,
  38. DIRECTSOUNDMIXER_SRCQUALITY_BASIC,
  39. DIRECTSOUNDMIXER_SRCQUALITY_ADVANCED,
  40. } DIRECTSOUNDMIXER_SRCQUALITY;
  41. #define DIRECTSOUNDMIXER_SRCQUALITY_DEFAULT DIRECTSOUNDMIXER_SRCQUALITY_ADVANCED
  42. typedef struct _DSPROPERTY_DIRECTSOUNDMIXER_SRCQUALITY_DATA
  43. {
  44. GUID DeviceId; // DirectSound device id
  45. DIRECTSOUNDMIXER_SRCQUALITY Quality; // SRC quality
  46. } DSPROPERTY_DIRECTSOUNDMIXER_SRCQUALITY_DATA, *PDSPROPERTY_DIRECTSOUNDMIXER_SRCQUALITY_DATA;
  47. #define DIRECTSOUNDMIXER_ACCELERATIONF_NORING0MIX 0x00000001
  48. #define DIRECTSOUNDMIXER_ACCELERATIONF_NOHWBUFFERS 0x00000002
  49. #define DIRECTSOUNDMIXER_ACCELERATIONF_NOHW3D 0x00000004
  50. #define DIRECTSOUNDMIXER_ACCELERATIONF_NOHWPROPSETS 0x00000008
  51. #define DIRECTSOUNDMIXER_ACCELERATIONF_FULL 0x00000000
  52. #define DIRECTSOUNDMIXER_ACCELERATIONF_STANDARD 0x00000008
  53. #define DIRECTSOUNDMIXER_ACCELERATIONF_NONE 0x0000000F
  54. #ifdef WINNT
  55. #define DIRECTSOUNDMIXER_ACCELERATIONF_DEFAULT DIRECTSOUNDMIXER_ACCELERATIONF_STANDARD
  56. #else // WINNT
  57. #define DIRECTSOUNDMIXER_ACCELERATIONF_DEFAULT DIRECTSOUNDMIXER_ACCELERATIONF_FULL
  58. #endif // WINNT
  59. typedef struct _DSPROPERTY_DIRECTSOUNDMIXER_ACCELERATION_DATA
  60. {
  61. GUID DeviceId; // DirectSound device id
  62. ULONG Flags; // Acceleration flags
  63. } DSPROPERTY_DIRECTSOUNDMIXER_ACCELERATION_DATA, *PDSPROPERTY_DIRECTSOUNDMIXER_ACCELERATION_DATA;
  64. //
  65. // DirectSound Device Properties {84624F82-25EC-11d1-A4D8-00C04FC28ACA}
  66. //
  67. DEFINE_GUID(DSPROPSETID_DirectSoundDevice, 0x84624f82, 0x25ec, 0x11d1, 0xa4, 0xd8, 0x0, 0xc0, 0x4f, 0xc2, 0x8a, 0xca);
  68. typedef enum
  69. {
  70. DSPROPERTY_DIRECTSOUNDDEVICE_PRESENCE_1,
  71. DSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_A,
  72. DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_1,
  73. DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_1,
  74. DSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_W,
  75. DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_A,
  76. DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_W,
  77. DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_A,
  78. DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_W,
  79. DSPROPERTY_DIRECTSOUNDDEVICE_PRESENCE
  80. } DSPROPERTY_DIRECTSOUNDDEVICE;
  81. #if DIRECTSOUND_VERSION >= 0x0700
  82. #ifdef UNICODE
  83. #define DSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING DSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_W
  84. #define DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_W
  85. #define DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_W
  86. #else // UNICODE
  87. #define DSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING DSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_A
  88. #define DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_A
  89. #define DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_A
  90. #endif // UNICODE
  91. #else // DIRECTSOUND_VERSION >= 0x0700
  92. #define DSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING DSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_A
  93. #define DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_1
  94. #define DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_1
  95. #define DSPROPERTY_DIRECTSOUNDDEVICE_PRESENCE DSPROPERTY_DIRECTSOUNDDEVICE_PRESENCE_1
  96. #endif // DIRECTSOUND_VERSION >= 0x0700
  97. typedef enum
  98. {
  99. DIRECTSOUNDDEVICE_TYPE_EMULATED,
  100. DIRECTSOUNDDEVICE_TYPE_VXD,
  101. DIRECTSOUNDDEVICE_TYPE_WDM
  102. } DIRECTSOUNDDEVICE_TYPE;
  103. typedef enum
  104. {
  105. DIRECTSOUNDDEVICE_DATAFLOW_RENDER,
  106. DIRECTSOUNDDEVICE_DATAFLOW_CAPTURE
  107. } DIRECTSOUNDDEVICE_DATAFLOW;
  108. typedef struct _DSPROPERTY_DIRECTSOUNDDEVICE_PRESENCE_1_DATA
  109. {
  110. GUID DeviceId; // DirectSound device id
  111. BOOL Present; // Presence switch
  112. } DSPROPERTY_DIRECTSOUNDDEVICE_PRESENCE_1_DATA, *PDSPROPERTY_DIRECTSOUNDDEVICE_PRESENCE_1_DATA;
  113. typedef struct _DSPROPERTY_DIRECTSOUNDDEVICE_PRESENCE_DATA
  114. {
  115. GUID DeviceId; // DirectSound device id
  116. DIRECTSOUNDDEVICE_TYPE DeviceType; // Device type
  117. BOOL Present; // Presence switch
  118. } DSPROPERTY_DIRECTSOUNDDEVICE_PRESENCE_DATA, *PDSPROPERTY_DIRECTSOUNDDEVICE_PRESENCE_DATA;
  119. #if DIRECTSOUND_VERSION < 0x0700
  120. #define DSPROPERTY_DIRECTSOUNDDEVICE_PRESENCE_DATA DSPROPERTY_DIRECTSOUNDDEVICE_PRESENCE_1_DATA
  121. #define PDSPROPERTY_DIRECTSOUNDDEVICE_PRESENCE_DATA PDSPROPERTY_DIRECTSOUNDDEVICE_PRESENCE_1_DATA
  122. #endif // DIRECTSOUND_VERSION < 0x0700
  123. typedef struct _DSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_A_DATA
  124. {
  125. LPSTR DeviceName; // waveIn/waveOut device name
  126. DIRECTSOUNDDEVICE_DATAFLOW DataFlow; // Data flow (i.e. waveIn or waveOut)
  127. GUID DeviceId; // DirectSound device id
  128. } DSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_A_DATA, *PDSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_A_DATA;
  129. typedef struct _DSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_W_DATA
  130. {
  131. LPWSTR DeviceName; // waveIn/waveOut device name
  132. DIRECTSOUNDDEVICE_DATAFLOW DataFlow; // Data flow (i.e. waveIn or waveOut)
  133. GUID DeviceId; // DirectSound device id
  134. } DSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_W_DATA, *PDSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_W_DATA;
  135. #ifdef UNICODE
  136. #define DSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_DATA DSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_W_DATA
  137. #define PDSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_DATA PDSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_W_DATA
  138. #else // UNICODE
  139. #define DSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_DATA DSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_A_DATA
  140. #define PDSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_DATA PDSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_A_DATA
  141. #endif // UNICODE
  142. typedef struct _DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_1_DATA
  143. {
  144. GUID DeviceId; // DirectSound device id
  145. CHAR DescriptionA[0x100]; // Device description (ANSI)
  146. WCHAR DescriptionW[0x100]; // Device description (Unicode)
  147. CHAR ModuleA[MAX_PATH]; // Device driver module (ANSI)
  148. WCHAR ModuleW[MAX_PATH]; // Device driver module (Unicode)
  149. DIRECTSOUNDDEVICE_TYPE Type; // Device type
  150. DIRECTSOUNDDEVICE_DATAFLOW DataFlow; // Device dataflow
  151. ULONG WaveDeviceId; // Wave device id
  152. ULONG Devnode; // Devnode (or DevInst)
  153. } DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_1_DATA, *PDSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_1_DATA;
  154. typedef struct _DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_A_DATA
  155. {
  156. DIRECTSOUNDDEVICE_TYPE Type; // Device type
  157. DIRECTSOUNDDEVICE_DATAFLOW DataFlow; // Device dataflow
  158. GUID DeviceId; // DirectSound device id
  159. LPSTR Description; // Device description
  160. LPSTR Module; // Device driver module
  161. LPSTR Interface; // Device interface
  162. ULONG WaveDeviceId; // Wave device id
  163. } DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_A_DATA, *PDSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_A_DATA;
  164. typedef struct _DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_W_DATA
  165. {
  166. DIRECTSOUNDDEVICE_TYPE Type; // Device type
  167. DIRECTSOUNDDEVICE_DATAFLOW DataFlow; // Device dataflow
  168. GUID DeviceId; // DirectSound device id
  169. LPWSTR Description; // Device description
  170. LPWSTR Module; // Device driver module
  171. LPWSTR Interface; // Device interface
  172. ULONG WaveDeviceId; // Wave device id
  173. } DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_W_DATA, *PDSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_W_DATA;
  174. #if DIRECTSOUND_VERSION >= 0x0700
  175. #ifdef UNICODE
  176. #define DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_DATA DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_W_DATA
  177. #define PDSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_DATA PDSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_W_DATA
  178. #else // UNICODE
  179. #define DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_DATA DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_A_DATA
  180. #define PDSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_DATA PDSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_A_DATA
  181. #endif // UNICODE
  182. #else // DIRECTSOUND_VERSION >= 0x0700
  183. #define DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_DATA DSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_1_DATA
  184. #define PDSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_DATA PDSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_1_DATA
  185. #endif // DIRECTSOUND_VERSION >= 0x0700
  186. typedef BOOL (CALLBACK *LPFNDIRECTSOUNDDEVICEENUMERATECALLBACK1)(PDSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_1_DATA, LPVOID);
  187. typedef BOOL (CALLBACK *LPFNDIRECTSOUNDDEVICEENUMERATECALLBACKA)(PDSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_A_DATA, LPVOID);
  188. typedef BOOL (CALLBACK *LPFNDIRECTSOUNDDEVICEENUMERATECALLBACKW)(PDSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_W_DATA, LPVOID);
  189. #if DIRECTSOUND_VERSION >= 0x0700
  190. #ifdef UNICODE
  191. #define LPFNDIRECTSOUNDDEVICEENUMERATECALLBACK LPFNDIRECTSOUNDDEVICEENUMERATECALLBACKW
  192. #else // UNICODE
  193. #define LPFNDIRECTSOUNDDEVICEENUMERATECALLBACK LPFNDIRECTSOUNDDEVICEENUMERATECALLBACKA
  194. #endif // UNICODE
  195. #else // DIRECTSOUND_VERSION >= 0x0700
  196. #define LPFNDIRECTSOUNDDEVICEENUMERATECALLBACK LPFNDIRECTSOUNDDEVICEENUMERATECALLBACK1
  197. #endif // DIRECTSOUND_VERSION >= 0x0700
  198. typedef struct _DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_1_DATA
  199. {
  200. LPFNDIRECTSOUNDDEVICEENUMERATECALLBACK1 Callback; // Callback function pointer
  201. LPVOID Context; // Callback function context argument
  202. } DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_1_DATA, *PDSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_1_DATA;
  203. typedef struct _DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_A_DATA
  204. {
  205. LPFNDIRECTSOUNDDEVICEENUMERATECALLBACKA Callback; // Callback function pointer
  206. LPVOID Context; // Callback function context argument
  207. } DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_A_DATA, *PDSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_A_DATA;
  208. typedef struct _DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_W_DATA
  209. {
  210. LPFNDIRECTSOUNDDEVICEENUMERATECALLBACKW Callback; // Callback function pointer
  211. LPVOID Context; // Callback function context argument
  212. } DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_W_DATA, *PDSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_W_DATA;
  213. #if DIRECTSOUND_VERSION >= 0x0700
  214. #ifdef UNICODE
  215. #define DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_DATA DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_W_DATA
  216. #define PDSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_DATA PDSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_W_DATA
  217. #else // UNICODE
  218. #define DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_DATA DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_A_DATA
  219. #define PDSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_DATA PDSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_A_DATA
  220. #endif // UNICODE
  221. #else // DIRECTSOUND_VERSION >= 0x0700
  222. #define DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_DATA DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_1_DATA
  223. #define PDSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_DATA PDSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_1_DATA
  224. #endif // DIRECTSOUND_VERSION >= 0x0700
  225. //
  226. // Basic DirectSound Acceleration Properties {1AEAA606-35F0-11D1-B161-00C04FC28ACA}
  227. //
  228. DEFINE_GUID(DSPROPSETID_DirectSoundBasicAcceleration, 0x1aeaa606, 0x35f0, 0x11d1, 0xb1, 0x61, 0x0, 0xc0, 0x4f, 0xc2, 0x8a, 0xca);
  229. typedef enum
  230. {
  231. DSPROPERTY_DIRECTSOUNDBASICACCELERATION_ACCELERATION,
  232. DSPROPERTY_DIRECTSOUNDBASICACCELERATION_DEFAULT,
  233. } DSPROPERTY_DIRECTSOUNDBASICACCELERATION;
  234. typedef enum
  235. {
  236. DIRECTSOUNDBASICACCELERATION_NONE,
  237. DIRECTSOUNDBASICACCELERATION_SAFE,
  238. DIRECTSOUNDBASICACCELERATION_STANDARD,
  239. DIRECTSOUNDBASICACCELERATION_FULL,
  240. } DIRECTSOUNDBASICACCELERATION_LEVEL;
  241. typedef struct _DSPROPERTY_DIRECTSOUNDBASICACCELERATION_ACCELERATION_DATA
  242. {
  243. GUID DeviceId; // DirectSound device id
  244. DIRECTSOUNDBASICACCELERATION_LEVEL Level; // Basic acceleration level
  245. } DSPROPERTY_DIRECTSOUNDBASICACCELERATION_ACCELERATION_DATA, *PDSPROPERTY_DIRECTSOUNDBASICACCELERATION_ACCELERATION_DATA,
  246. DSPROPERTY_DIRECTSOUNDBASICACCELERATION_DEFAULT_DATA, *PDSPROPERTY_DIRECTSOUNDBASICACCELERATION_DEFAULT_DATA;
  247. //
  248. // DirectSound Debug Properties {F2957840-260C-11d1-A4D8-00C04FC28ACA}
  249. //
  250. DEFINE_GUID(DSPROPSETID_DirectSoundDebug, 0xf2957840, 0x260c, 0x11d1, 0xa4, 0xd8, 0x0, 0xc0, 0x4f, 0xc2, 0x8a, 0xca);
  251. typedef enum
  252. {
  253. DSPROPERTY_DIRECTSOUNDDEBUG_DPFINFO_A,
  254. DSPROPERTY_DIRECTSOUNDDEBUG_DPFINFO_W,
  255. DSPROPERTY_DIRECTSOUNDDEBUG_TRANSLATERESULTCODE_A,
  256. DSPROPERTY_DIRECTSOUNDDEBUG_TRANSLATERESULTCODE_W,
  257. } DSPROPERTY_DIRECTSOUNDDEBUG;
  258. #ifdef UNICODE
  259. #define DSPROPERTY_DIRECTSOUNDDEBUG_DPFINFO DSPROPERTY_DIRECTSOUNDDEBUG_DPFINFO_W
  260. #define DSPROPERTY_DIRECTSOUNDDEBUG_TRANSLATERESULTCODE DSPROPERTY_DIRECTSOUNDDEBUG_TRANSLATERESULTCODE_W
  261. #else // UNICODE
  262. #define DSPROPERTY_DIRECTSOUNDDEBUG_DPFINFO DSPROPERTY_DIRECTSOUNDDEBUG_DPFINFO_A
  263. #define DSPROPERTY_DIRECTSOUNDDEBUG_TRANSLATERESULTCODE DSPROPERTY_DIRECTSOUNDDEBUG_TRANSLATERESULTCODE_A
  264. #endif // UNICODE
  265. #define DIRECTSOUNDDEBUG_DPFINFOF_PRINTFUNCTIONNAME 0x00000001
  266. #define DIRECTSOUNDDEBUG_DPFINFOF_PRINTPROCESSTHREADID 0x00000002
  267. #define DIRECTSOUNDDEBUG_DPFINFOF_PRINTFILELINE 0x00000004
  268. #define DIRECTSOUNDDEBUG_DPFINFOF_LOGTOFILEONLY 0x00000008
  269. #define DIRECTSOUNDDEBUG_DPFINFOF_DEFAULT DIRECTSOUNDDEBUG_DPFINFOF_PRINTFUNCTIONNAME
  270. typedef struct _DSPROPERTY_DIRECTSOUNDDEBUG_DPFINFO_A_DATA
  271. {
  272. ULONG Flags; // DPF flags
  273. ULONG DpfLevel; // DPF level
  274. ULONG BreakLevel; // Break level
  275. CHAR LogFile[MAX_PATH]; // Log file
  276. } DSPROPERTY_DIRECTSOUNDDEBUG_DPFINFO_A_DATA, *PDSPROPERTY_DIRECTSOUNDDEBUG_DPFINFO_A_DATA;
  277. typedef struct _DSPROPERTY_DIRECTSOUNDDEBUG_DPFINFO_W_DATA
  278. {
  279. ULONG Flags; // DPF flags
  280. ULONG DpfLevel; // DPF level
  281. ULONG BreakLevel; // Break level
  282. WCHAR LogFile[MAX_PATH]; // Log file
  283. } DSPROPERTY_DIRECTSOUNDDEBUG_DPFINFO_W_DATA, *PDSPROPERTY_DIRECTSOUNDDEBUG_DPFINFO_W_DATA;
  284. typedef struct _DSPROPERTY_DIRECTSOUNDDEBUG_TRANSLATERESULTCODE_A_DATA
  285. {
  286. HRESULT ResultCode; // Result code
  287. LPSTR String; // Result code in string form
  288. LPSTR Explanation; // Result code description
  289. } DSPROPERTY_DIRECTSOUNDDEBUG_TRANSLATERESULTCODE_A_DATA, *PDSPROPERTY_DIRECTSOUNDDEBUG_TRANSLATERESULTCODE_A_DATA;
  290. typedef struct _DSPROPERTY_DIRECTSOUNDDEBUG_TRANSLATERESULTCODE_W_DATA
  291. {
  292. HRESULT ResultCode; // Result code
  293. LPWSTR String; // Result code in string form
  294. LPWSTR Explanation; // Result code description
  295. } DSPROPERTY_DIRECTSOUNDDEBUG_TRANSLATERESULTCODE_W_DATA, *PDSPROPERTY_DIRECTSOUNDDEBUG_TRANSLATERESULTCODE_W_DATA;
  296. #ifdef UNICODE
  297. #define DSPROPERTY_DIRECTSOUNDDEBUG_DPFINFO_DATA DSPROPERTY_DIRECTSOUNDDEBUG_DPFINFO_W_DATA
  298. #define PDSPROPERTY_DIRECTSOUNDDEBUG_DPFINFO_DATA PDSPROPERTY_DIRECTSOUNDDEBUG_DPFINFO_W_DATA
  299. #define DSPROPERTY_DIRECTSOUNDDEBUG_TRANSLATERESULTCODE_DATA DSPROPERTY_DIRECTSOUNDDEBUG_TRANSLATERESULTCODE_W_DATA
  300. #define PDSPROPERTY_DIRECTSOUNDDEBUG_TRANSLATERESULTCODE_DATA PDSPROPERTY_DIRECTSOUNDDEBUG_TRANSLATERESULTCODE_W_DATA
  301. #else // UNICODE
  302. #define DSPROPERTY_DIRECTSOUNDDEBUG_DPFINFO_DATA DSPROPERTY_DIRECTSOUNDDEBUG_DPFINFO_A_DATA
  303. #define PDSPROPERTY_DIRECTSOUNDDEBUG_DPFINFO_DATA PDSPROPERTY_DIRECTSOUNDDEBUG_DPFINFO_A_DATA
  304. #define DSPROPERTY_DIRECTSOUNDDEBUG_TRANSLATERESULTCODE_DATA DSPROPERTY_DIRECTSOUNDDEBUG_TRANSLATERESULTCODE_A_DATA
  305. #define PDSPROPERTY_DIRECTSOUNDDEBUG_TRANSLATERESULTCODE_DATA PDSPROPERTY_DIRECTSOUNDDEBUG_TRANSLATERESULTCODE_A_DATA
  306. #endif // UNICODE
  307. #define DIRECTSOUNDDEBUG_DPFLEVEL_DEFAULT 0
  308. #define DIRECTSOUNDDEBUG_BREAKLEVEL_DEFAULT 0
  309. //
  310. // DirectSound Persistent Data {1BE55C3E-36AB-11d1-B162-00C04FC28ACA}
  311. //
  312. DEFINE_GUID(DSPROPSETID_DirectSoundPersistentData, 0x1be55c3e, 0x36ab, 0x11d1, 0xb1, 0x62, 0x0, 0xc0, 0x4f, 0xc2, 0x8a, 0xca);
  313. typedef enum
  314. {
  315. DSPROPERTY_DIRECTSOUNDPERSISTENTDATA_PERSISTDATA_A,
  316. DSPROPERTY_DIRECTSOUNDPERSISTENTDATA_PERSISTDATA_W,
  317. } DSPROPERTY_DIRECTSOUNDPERSISTENTDATA;
  318. #ifdef UNICODE
  319. #define DSPROPERTY_DIRECTSOUNDPERSISTENTDATA_PERSISTDATA DSPROPERTY_DIRECTSOUNDPERSISTENTDATA_PERSISTDATA_W
  320. #else // UNICODE
  321. #define DSPROPERTY_DIRECTSOUNDPERSISTENTDATA_PERSISTDATA DSPROPERTY_DIRECTSOUNDPERSISTENTDATA_PERSISTDATA_A
  322. #endif // UNICODE
  323. typedef struct _DSPROPERTY_DIRECTSOUNDPERSISTENTDATA_PERSISTDATA_A_DATA
  324. {
  325. GUID DeviceId; // DirectSound device id
  326. LPSTR SubKeyName; // Optional subkey name
  327. LPSTR ValueName; // Value name
  328. ULONG RegistryDataType; // Data type
  329. LPVOID Data; // Data pointer
  330. ULONG DataSize; // Size of data buffer, in bytes
  331. } DSPROPERTY_DIRECTSOUNDPERSISTENTDATA_PERSISTDATA_A_DATA, *PDSPROPERTY_DIRECTSOUNDPERSISTENTDATA_PERSISTDATA_A_DATA;
  332. typedef struct _DSPROPERTY_DIRECTSOUNDPERSISTENTDATA_PERSISTDATA_W_DATA
  333. {
  334. GUID DeviceId; // DirectSound device id
  335. LPWSTR SubKeyName; // Optional subkey name
  336. LPWSTR ValueName; // Value name
  337. ULONG RegistryDataType; // Data type
  338. LPVOID Data; // Data pointer
  339. ULONG DataSize; // Size of data buffer, in bytes
  340. } DSPROPERTY_DIRECTSOUNDPERSISTENTDATA_PERSISTDATA_W_DATA, *PDSPROPERTY_DIRECTSOUNDPERSISTENTDATA_PERSISTDATA_W_DATA;
  341. #ifdef UNICODE
  342. #define DSPROPERTY_DIRECTSOUNDPERSISTENTDATA_PERSISTDATA_DATA DSPROPERTY_DIRECTSOUNDPERSISTENTDATA_PERSISTDATA_W_DATA
  343. #define PDSPROPERTY_DIRECTSOUNDPERSISTENTDATA_PERSISTDATA_DATA PDSPROPERTY_DIRECTSOUNDPERSISTENTDATA_PERSISTDATA_W_DATA
  344. #else // UNICODE
  345. #define DSPROPERTY_DIRECTSOUNDPERSISTENTDATA_PERSISTDATA_DATA DSPROPERTY_DIRECTSOUNDPERSISTENTDATA_PERSISTDATA_A_DATA
  346. #define PDSPROPERTY_DIRECTSOUNDPERSISTENTDATA_PERSISTDATA_DATA PDSPROPERTY_DIRECTSOUNDPERSISTENTDATA_PERSISTDATA_A_DATA
  347. #endif // UNICODE
  348. //
  349. // DirectSound Buffer Properties {50393DEA-51AD-11d2-91B2-00C04FC28ACA}
  350. //
  351. DEFINE_GUID(DSPROPSETID_DirectSoundBuffer, 0x50393dea, 0x51ad, 0x11d2, 0x91, 0xb2, 0x0, 0xc0, 0x4f, 0xc2, 0x8a, 0xca);
  352. typedef enum
  353. {
  354. DSPROPERTY_DIRECTSOUNDBUFFER_DEVICEID,
  355. } DSPROPERTY_DIRECTSOUNDBUFFER;
  356. typedef struct _DSPROPERTY_DIRECTSOUNDBUFFER_DEVICEID_DATA
  357. {
  358. LPDIRECTSOUNDBUFFER Buffer; // Buffer object pointer
  359. GUID DeviceId; // DirectSound device ID
  360. } DSPROPERTY_DIRECTSOUNDBUFFER_DEVICEID_DATA, *PDSPROPERTY_DIRECTSOUNDBUFFER_DEVICEID_DATA;
  361. //
  362. // DirectSound Object Properties {4BE334F0-1C8E-4D91-8C17-5889D6F0B154}
  363. //
  364. DEFINE_GUID(DSPROPSETID_DirectSound, 0x4be334f0, 0x1c8e, 0x4d91, 0x8c, 0x17, 0x58, 0x89, 0xd6, 0xf0, 0xb1, 0x54);
  365. typedef enum
  366. {
  367. DSPROPERTY_DIRECTSOUND_OBJECTS,
  368. DSPROPERTY_DIRECTSOUNDCAPTURE_OBJECTS
  369. } DSPROPERTY_DIRECTSOUND;
  370. #pragma warning(disable:4200) // Disable the nag about the Objects[0] arrays below
  371. typedef struct _DIRECTSOUND_INFO
  372. {
  373. LPDIRECTSOUND DirectSound;
  374. GUID DeviceId;
  375. } DIRECTSOUND_INFO;
  376. typedef struct _DSPROPERTY_DIRECTSOUND_OBJECTS_DATA
  377. {
  378. GUID DeviceId; // [in] DirectSound device ID (or GUID_NULL for all DS objects)
  379. ULONG Count; // [out] Count of DirectSound objects matching this DeviceId
  380. DIRECTSOUND_INFO Objects[0]; // [out] Information about each DirectSound object
  381. } DSPROPERTY_DIRECTSOUND_OBJECTS_DATA, *PDSPROPERTY_DIRECTSOUND_OBJECTS_DATA;
  382. typedef struct _DIRECTSOUNDCAPTURE_INFO
  383. {
  384. LPDIRECTSOUNDCAPTURE DirectSoundCapture;
  385. GUID DeviceId;
  386. } DIRECTSOUNDCAPTURE_INFO;
  387. typedef struct _DSPROPERTY_DIRECTSOUNDCAPTURE_OBJECTS_DATA
  388. {
  389. GUID DeviceId; // [in] DirectSoundCapture device ID (or GUID_NULL for all DSC objects)
  390. ULONG Count; // [out] Count of DirectSoundCapture objects matching this DeviceId
  391. DIRECTSOUNDCAPTURE_INFO Objects[0]; // [out] Information about each DirectSoundCapture object
  392. } DSPROPERTY_DIRECTSOUNDCAPTURE_OBJECTS_DATA, *PDSPROPERTY_DIRECTSOUNDCAPTURE_OBJECTS_DATA;
  393. #ifdef __cplusplus
  394. }
  395. #endif // __cplusplus
  396. #endif // __DSPRV_INCLUDED__