Leaked source code of windows server 2003
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.

209 lines
7.6 KiB

  1. /////////////////////////////////////////////////////////////////////////////////////////
  2. //
  3. // Copyright (c) 1998 Active Voice Corporation. All Rights Reserved.
  4. //
  5. // Active Agent(r) and Unified Communications(tm) are trademarks of Active Voice Corporation.
  6. //
  7. // Other brand and product names used herein are trademarks of their respective owners.
  8. //
  9. // The entire program and user interface including the structure, sequence, selection,
  10. // and arrangement of the dialog, the exclusively "yes" and "no" choices represented
  11. // by "1" and "2," and each dialog message are protected by copyrights registered in
  12. // the United States and by international treaties.
  13. //
  14. // Protected by one or more of the following United States patents: 5,070,526, 5,488,650,
  15. // 5,434,906, 5,581,604, 5,533,102, 5,568,540, 5,625,676, 5,651,054.
  16. //
  17. // Active Voice Corporation
  18. // Seattle, Washington
  19. // USA
  20. //
  21. /////////////////////////////////////////////////////////////////////////////////////////
  22. ////
  23. // awav.h - interface for command line awavument functions in awav.c
  24. ////
  25. #ifndef __AWAV_H__
  26. #define __AWAV_H__
  27. #include "winlocal.h"
  28. #include "wav.h"
  29. #define AWAV_VERSION 0x00000100
  30. // handle to awav engine
  31. //
  32. DECLARE_HANDLE32(HAWAV);
  33. #ifdef __cplusplus
  34. extern "C" {
  35. #endif
  36. // AWavOpen - initialize array of open wav files
  37. // <dwVersion> (i) must be AWAV_VERSION
  38. // <hInst> (i) instance handle of calling module
  39. // <lpahWav> (i) pointer to array of HWAVs
  40. // <chWav> (i) count of HWAVs pointed to by lpahWav
  41. // <dwFlags> (i) control flags
  42. // 0 reserved; must be zero
  43. // return handle (NULL if error)
  44. //
  45. HAWAV DLLEXPORT WINAPI AWavOpen(DWORD dwVersion, HINSTANCE hInst, HWAV FAR *lpahWav, int chWav, DWORD dwFlags);
  46. // AWavClose - shut down array of open wav files
  47. // <hAWav> (i) handle returned from AWavOpen
  48. // return 0 if success
  49. //
  50. int DLLEXPORT WINAPI AWavClose(HAWAV hAWav);
  51. // AWavPlayEx - play array of wav files
  52. // <hAWav> (i) handle returned from AWavOpen
  53. // see WavPlayEx() for further description
  54. // return 0 if success
  55. //
  56. int DLLEXPORT WINAPI AWavPlayEx(HAWAV hAWav, int idDev,
  57. PLAYSTOPPEDPROC lpfnPlayStopped, HANDLE hUserPlayStopped,
  58. DWORD dwReserved, DWORD dwFlags);
  59. // AWavStop - stop playing wav array
  60. // <hAWav> (i) handle returned from AWavOpen
  61. // see WavStop() for further description
  62. // return 0 if success
  63. //
  64. int DLLEXPORT WINAPI AWavStop(HAWAV hAWav);
  65. // AWavGetState - return current wav state
  66. // <hAWav> (i) handle returned from AWavOpen
  67. // see WavGetState() for further description
  68. // return WAV_STOPPED, WAV_PLAYING, WAV_RECORDING, or 0 if error
  69. //
  70. WORD DLLEXPORT WINAPI AWavGetState(HAWAV hAWav);
  71. // AWavGetLength - get current wav data length in milleseconds
  72. // <hAWav> (i) handle returned from AWavOpen
  73. // see WavGetState() for further description
  74. // return milleseconds if success, otherwise -1
  75. //
  76. long DLLEXPORT WINAPI AWavGetLength(HAWAV hAWav);
  77. // AWavGetPosition - get current wav data position in milleseconds
  78. // <hAWav> (i) handle returned from AWavOpen
  79. // see WavGetPosition() for further description
  80. // return milleseconds if success, otherwise -1
  81. //
  82. long DLLEXPORT WINAPI AWavGetPosition(HAWAV hAWav);
  83. // AWavSetPosition - set current wav data position in milleseconds
  84. // <hAWav> (i) handle returned from AWavOpen
  85. // see WavSetPosition() for further description
  86. // return new position in milleseconds if success, otherwise -1
  87. //
  88. long DLLEXPORT WINAPI AWavSetPosition(HAWAV hAWav, long msPosition);
  89. // AWavGetFormat - get wav format of current element in wav array
  90. // <hAWav> (i) handle returned from AWavOpen
  91. // see WavGetFormat() for further description
  92. // return pointer to specified format, NULL if error
  93. //
  94. LPWAVEFORMATEX DLLEXPORT WINAPI AWavGetFormat(HAWAV hAWav, DWORD dwFlags);
  95. // AWavSetFormat - set wav format for all elements in wav array
  96. // <hAWav> (i) handle returned from AWavOpen
  97. // see WavSetFormat() for further description
  98. // return 0 if success
  99. //
  100. int DLLEXPORT WINAPI AWavSetFormat(HAWAV hAWav,
  101. LPWAVEFORMATEX lpwfx, DWORD dwFlags);
  102. // AWavChooseFormat - choose and set audio format from dialog box
  103. // <hAWav> (i) handle returned from AWavOpen
  104. // see WavChooseFormat() for further description
  105. // return 0 if success
  106. //
  107. int DLLEXPORT WINAPI AWavChooseFormat(HAWAV hAWav, HWND hwndOwner, LPCTSTR lpszTitle, DWORD dwFlags);
  108. // AWavGetVolume - get current volume level
  109. // <hAWav> (i) handle returned from AWavOpen
  110. // see WavGetVolume() for further description
  111. // return volume level (0 minimum through 100 maximum, -1 if error)
  112. //
  113. int DLLEXPORT WINAPI AWavGetVolume(HAWAV hAWav, int idDev, DWORD dwFlags);
  114. // AWavSetVolume - set current volume level
  115. // <hAWav> (i) handle returned from AWavOpen
  116. // see WavGetVolume() for further description
  117. // return 0 if success
  118. //
  119. int DLLEXPORT WINAPI AWavSetVolume(HAWAV hAWav, int idDev, int nLevel, DWORD dwFlags);
  120. // AWavSupportsVolume - check if audio can be played at specified volume
  121. // <hAWav> (i) handle returned from AWavOpen
  122. // see WavSupportsVolume() for further description
  123. // return TRUE if supported
  124. //
  125. BOOL DLLEXPORT WINAPI AWavSupportsVolume(HAWAV hAWav, int idDev, int nLevel, DWORD dwFlags);
  126. // AWavGetSpeed - get current speed level
  127. // <hAWav> (i) handle returned from AWavOpen
  128. // see WavGetSpeed() for further description
  129. // return speed level (100 is normal, 50 is half, 200 is double, -1 if error)
  130. //
  131. int DLLEXPORT WINAPI AWavGetSpeed(HAWAV hAWav, int idDev, DWORD dwFlags);
  132. // AWavSetSpeed - set current speed level
  133. // <hAWav> (i) handle returned from AWavOpen
  134. // see WavSetSpeed() for further description
  135. // return 0 if success
  136. //
  137. int DLLEXPORT WINAPI AWavSetSpeed(HAWAV hAWav, int idDev, int nLevel, DWORD dwFlags);
  138. // AWavSupportsSpeed - check if audio can be played at specified speed
  139. // <hAWav> (i) handle returned from AWavOpen
  140. // see WavSupportsSpeed() for further description
  141. // return TRUE if supported
  142. //
  143. BOOL DLLEXPORT WINAPI AWavSupportsSpeed(HAWAV hAWav, int idDev, int nLevel, DWORD dwFlags);
  144. // AWavGetChunks - get chunk count and size of current element in wav array
  145. // <hAWav> (i) handle returned from AWavOpen
  146. // see WavGetChunks() for further description
  147. // return 0 if success
  148. //
  149. int DLLEXPORT WINAPI AWavGetChunks(HAWAV hAWav,
  150. int FAR *lpcChunks, long FAR *lpmsChunkSize, BOOL fWavOut);
  151. // AWavSetChunks - set chunk count and size of all elements in wav array
  152. // <hAWav> (i) handle returned from WavOpen
  153. // see WavSetChunks() for further description
  154. // return 0 if success
  155. //
  156. int DLLEXPORT WINAPI AWavSetChunks(HAWAV hAWav, int cChunks, long msChunkSize, BOOL fWavOut);
  157. // AWavCopy - copy data from wav array to wav file
  158. // <hAWavSrc> (i) source handle returned from AWavOpen
  159. // see WavCopy() for further description
  160. // return 0 if success (-1 if error, +1 if user abort)
  161. //
  162. int DLLEXPORT WINAPI AWavCopy(HAWAV hAWavSrc, HWAV hWavDst,
  163. void _huge *hpBuf, long sizBuf, USERABORTPROC lpfnUserAbort, DWORD dwUser, DWORD dwFlags);
  164. // AWavGetOutputDevice - get handle to open wav output device
  165. // <hAWav> (i) handle returned from AWavOpen
  166. // see WavGetOutputDevice() for further description
  167. // return handle to wav output device (NULL if device not open or error)
  168. //
  169. HWAVOUT DLLEXPORT WINAPI AWavGetOutputDevice(HAWAV hAWav);
  170. // AWavGetInputDevice - get handle to open wav input device
  171. // <hAWav> (i) handle returned from AWavOpen
  172. // return handle to wav input device (NULL if device not open or error)
  173. //
  174. HWAVIN DLLEXPORT WINAPI AWavGetInputDevice(HAWAV hAWav);
  175. #ifdef __cplusplus
  176. }
  177. #endif
  178. #endif // __AWAV_H__