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.

176 lines
3.7 KiB

  1. //==========================================================================;
  2. //
  3. // THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY
  4. // KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
  5. // IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A PARTICULAR
  6. // PURPOSE.
  7. //
  8. // Copyright (c) 1992 - 1994 Microsoft Corporation. All Rights Reserved.
  9. //
  10. //--------------------------------------------------------------------------;
  11. //
  12. // waveio.h
  13. //
  14. // Description:
  15. //
  16. //
  17. //
  18. //==========================================================================;
  19. #ifndef _INC_WAVEIO
  20. #define _INC_WAVEIO // #defined if file has been included
  21. #ifndef RC_INVOKED
  22. #pragma pack(1) // assume byte packing throughout
  23. #endif
  24. #ifndef EXTERN_C
  25. #ifdef __cplusplus
  26. #define EXTERN_C extern "C"
  27. #else
  28. #define EXTERN_C extern
  29. #endif
  30. #endif
  31. #ifdef __cplusplus
  32. extern "C" // assume C declarations for C++
  33. {
  34. #endif
  35. #ifdef WIN32
  36. //
  37. // for compiling Unicode
  38. //
  39. #ifndef SIZEOF
  40. #ifdef UNICODE
  41. #define SIZEOF(x) (sizeof(x)/sizeof(WCHAR))
  42. #else
  43. #define SIZEOF(x) sizeof(x)
  44. #endif
  45. #endif
  46. #else
  47. //
  48. // stuff for Unicode in Win 32--make it a noop in Win 16
  49. //
  50. #ifndef TEXT
  51. #define TEXT(a) a
  52. #endif
  53. #ifndef SIZEOF
  54. #define SIZEOF(x) sizeof(x)
  55. #endif
  56. #ifndef _TCHAR_DEFINED
  57. #define _TCHAR_DEFINED
  58. typedef char TCHAR, *PTCHAR;
  59. typedef unsigned char TBYTE, *PTUCHAR;
  60. typedef PSTR PTSTR, PTCH;
  61. typedef LPSTR LPTSTR, LPTCH;
  62. typedef LPCSTR LPCTSTR;
  63. #endif
  64. #endif
  65. //
  66. //
  67. //
  68. //
  69. //
  70. #ifdef WIN32
  71. #define WIOAPI _stdcall
  72. #else
  73. #ifdef _WINDLL
  74. #define WIOAPI FAR PASCAL _loadds
  75. #else
  76. #define WIOAPI FAR PASCAL
  77. #endif
  78. #endif
  79. //
  80. //
  81. //
  82. typedef UINT WIOERR;
  83. //
  84. //
  85. //
  86. //
  87. typedef struct tWAVEIOCB
  88. {
  89. DWORD dwFlags;
  90. HMMIO hmmio;
  91. DWORD dwDataOffset;
  92. DWORD dwDataBytes;
  93. DWORD dwDataSamples;
  94. LPWAVEFORMATEX pwfx;
  95. #if 0
  96. HWAVEOUT hwo;
  97. DWORD dwBytesLeft;
  98. DWORD dwBytesPerBuffer;
  99. DISP FAR * pDisp;
  100. INFOCHUNK FAR * pInfo;
  101. #endif
  102. } WAVEIOCB, *PWAVEIOCB, FAR *LPWAVEIOCB;
  103. //
  104. // error returns from waveio functions
  105. //
  106. #define WIOERR_BASE (0)
  107. #define WIOERR_NOERROR (0)
  108. #define WIOERR_ERROR (WIOERR_BASE+1)
  109. #define WIOERR_BADHANDLE (WIOERR_BASE+2)
  110. #define WIOERR_BADFLAGS (WIOERR_BASE+3)
  111. #define WIOERR_BADPARAM (WIOERR_BASE+4)
  112. #define WIOERR_BADSIZE (WIOERR_BASE+5)
  113. #define WIOERR_FILEERROR (WIOERR_BASE+6)
  114. #define WIOERR_NOMEM (WIOERR_BASE+7)
  115. #define WIOERR_BADFILE (WIOERR_BASE+8)
  116. #define WIOERR_NODEVICE (WIOERR_BASE+9)
  117. #define WIOERR_BADFORMAT (WIOERR_BASE+10)
  118. #define WIOERR_ALLOCATED (WIOERR_BASE+11)
  119. #define WIOERR_NOTSUPPORTED (WIOERR_BASE+12)
  120. //
  121. // function prototypes and flag definitions
  122. //
  123. WIOERR WIOAPI wioFileClose
  124. (
  125. LPWAVEIOCB pwio,
  126. DWORD fdwClose
  127. );
  128. WIOERR WIOAPI wioFileOpen
  129. (
  130. LPWAVEIOCB pwio,
  131. LPCTSTR pszFilePath,
  132. DWORD fdwOpen
  133. );
  134. //- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ;
  135. //
  136. //
  137. //
  138. //- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ;
  139. #ifndef RC_INVOKED
  140. #pragma pack() // revert to default packing
  141. #endif
  142. #ifdef __cplusplus
  143. } // end of extern "C" {
  144. #endif
  145. #endif // _INC_WAVEIO