home *** CD-ROM | disk | FTP | other *** search
/ Team Palmtops 7 / Palmtops_numero07.iso / WinCE / SDKWindowsCE / AutoPC / apcsdk10.exe / data1.cab / Emulation_Include_Files / msacmdrv.h < prev    next >
Encoding:
C/C++ Source or Header  |  1999-05-13  |  8.4 KB  |  264 lines

  1. // -----------------------------------------------------------------------------
  2. //
  3. //  THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF
  4. //  ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO
  5. //  THE IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A
  6. //  PARTICULAR PURPOSE.
  7. //  Copyright (c) 1995, 1996, 1997  Microsoft Corporation
  8. //  
  9. // -----------------------------------------------------------------------------
  10. //
  11. //  msacmdrv.h     Audio Compression Manager Public Header File for Drivers
  12. //
  13. // -----------------------------------------------------------------------------
  14.  
  15. #ifndef _INC_ACMDRV
  16. #define _INC_ACMDRV         /* #defined if msacmdrv.h has been included */
  17.  
  18. #if !defined(_INC_ACM)
  19. #ifndef RC_INVOKED
  20. #error MSACM.H to be included first
  21. #endif
  22. #endif
  23.  
  24. #ifndef RC_INVOKED
  25. #pragma pack(1)             /* Assume byte packing throughout */
  26. #endif  /* RC_INVOKED */
  27.  
  28. #ifdef __cplusplus
  29. extern "C" {                /* Assume C declarations for C++ */
  30. #endif  /* __cplusplus */
  31.  
  32.  
  33.  
  34. #ifndef MMNODRV
  35.  
  36. #ifndef DRV_LOAD
  37.  
  38. /* Driver messages */
  39. #define DRV_LOAD                0x0001
  40. #define DRV_ENABLE              0x0002
  41. #define DRV_OPEN                0x0003
  42. #define DRV_CLOSE               0x0004
  43. #define DRV_DISABLE             0x0005
  44. #define DRV_FREE                0x0006
  45. #define DRV_CONFIGURE           0x0007
  46. #define DRV_QUERYCONFIGURE      0x0008
  47. #define DRV_INSTALL             0x0009
  48. #define DRV_REMOVE              0x000A
  49. #define DRV_EXITSESSION         0x000B
  50. #define DRV_POWER               0x000F
  51. #define DRV_RESERVED            0x0800
  52. #define DRV_USER                0x4000
  53.  
  54. typedef struct DRVCONFIGINFOEX {
  55.     DWORD   dwDCISize;
  56.     LPCWSTR  lpszDCISectionName;
  57.     LPCWSTR  lpszDCIAliasName;
  58.     DWORD    dnDevNode;
  59. } DRVCONFIGINFOEX, *PDRVCONFIGINFOEX, NEAR *NPDRVCONFIGINFOEX, FAR *LPDRVCONFIGINFOEX;
  60.  
  61. /* LPARAM of DRV_CONFIGURE message */
  62. typedef struct tagDRVCONFIGINFO {
  63.     DWORD   dwDCISize;
  64.     LPCWSTR  lpszDCISectionName;
  65.     LPCWSTR  lpszDCIAliasName;
  66. } DRVCONFIGINFO, *PDRVCONFIGINFO, NEAR *NPDRVCONFIGINFO, FAR *LPDRVCONFIGINFO;
  67.  
  68. /* Supported return values for DRV_CONFIGURE message */
  69. #define DRVCNF_CANCEL           0x0000
  70. #define DRVCNF_OK               0x0001
  71. #define DRVCNF_RESTART          0x0002
  72.  
  73. /* return values from DriverProc() function */
  74. #define DRV_CANCEL             DRVCNF_CANCEL
  75. #define DRV_OK                 DRVCNF_OK
  76. #define DRV_RESTART            DRVCNF_RESTART
  77.  
  78. #endif  // ifndef DRV_LOAD
  79.  
  80. #endif  /* ifndef MMNODRV */
  81.  
  82.  
  83.  
  84.  
  85. //- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ;
  86. //
  87. //  ACM Driver Version:
  88. //
  89. //  the version is a 32 bit number that is broken into three parts as 
  90. //  follows:
  91. //
  92. //      bits 24 - 31:   8 bit _major_ version number
  93. //      bits 16 - 23:   8 bit _minor_ version number
  94. //      bits  0 - 15:   16 bit build number
  95. //
  96. //  this is then displayed as follows:
  97. //
  98. //      bMajor = (BYTE)(dwVersion >> 24)
  99. //      bMinor = (BYTE)(dwVersion >> 16) & 
  100. //      wBuild = LOWORD(dwVersion)
  101. //
  102. //- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ;
  103.  
  104. #define MAKE_ACM_VERSION(mjr, mnr, bld) (((long)(mjr)<<24)| \
  105.                                          ((long)(mnr)<<16)| \
  106.                                          ((long)bld))
  107.  
  108.  
  109.  
  110. //
  111. //
  112. //
  113. //
  114. //
  115. #define ACMDRVOPENDESC_SECTIONNAME_CHARS    
  116.  
  117. typedef struct tACMDRVOPENDESC
  118. {
  119.     DWORD           cbStruct;       // sizeof(ACMDRVOPENDESC)
  120.     FOURCC          fccType;        // 'audc'
  121.     FOURCC          fccComp;        // sub-type (not used--must be 0)
  122.     DWORD           dwVersion;      // current version of ACM opening you
  123.     DWORD           dwFlags;        //
  124.     DWORD           dwError;        // result from DRV_OPEN request
  125.     LPCTSTR         pszSectionName; // see DRVCONFIGINFO.lpszDCISectionName
  126.     LPCTSTR         pszAliasName;   // see DRVCONFIGINFO.lpszDCIAliasName
  127.     DWORD           dnDevNode;      // devnode id for pnp drivers.
  128.  
  129. } ACMDRVOPENDESC, *PACMDRVOPENDESC, FAR *LPACMDRVOPENDESC;
  130.  
  131.  
  132. //
  133. //
  134. //
  135. //
  136. //
  137. typedef struct tACMDRVSTREAMINSTANCE
  138. {
  139.     DWORD               cbStruct;
  140.     LPWAVEFORMATEX      pwfxSrc;
  141.     LPWAVEFORMATEX      pwfxDst;
  142.     LPWAVEFILTER        pwfltr;
  143.     DWORD               dwCallback;
  144.     DWORD               dwInstance;
  145.     DWORD               fdwOpen;
  146.     DWORD               fdwDriver;
  147.     DWORD               dwDriver;
  148.     HACMSTREAM          has;
  149.  
  150. } ACMDRVSTREAMINSTANCE, *PACMDRVSTREAMINSTANCE, FAR *LPACMDRVSTREAMINSTANCE;
  151.  
  152.  
  153. //
  154. //  NOTE! this structure must match the ACMSTREAMHEADER in msacm.h but
  155. //  defines more information for the driver writing convenience
  156. //
  157. typedef struct tACMDRVSTREAMHEADER FAR *LPACMDRVSTREAMHEADER;
  158. typedef struct tACMDRVSTREAMHEADER
  159. {
  160.     DWORD                   cbStruct;
  161.     DWORD                   fdwStatus;
  162.     DWORD                   dwUser;
  163.     LPBYTE                  pbSrc;
  164.     DWORD                   cbSrcLength;
  165.     DWORD                   cbSrcLengthUsed;
  166.     DWORD                   dwSrcUser;
  167.     LPBYTE                  pbDst;
  168.     DWORD                   cbDstLength;
  169.     DWORD                   cbDstLengthUsed;
  170.     DWORD                   dwDstUser;
  171.  
  172.     DWORD                   fdwConvert;     // flags passed from convert func
  173.     LPACMDRVSTREAMHEADER    padshNext;      // for async driver queueing
  174.     DWORD                   fdwDriver;      // driver instance flags
  175.     DWORD                   dwDriver;       // driver instance data
  176.  
  177.     //
  178.     //  all remaining fields are used by the ACM for bookkeeping purposes.
  179.     //  an ACM driver should never use these fields (though than can be
  180.     //  helpful for debugging)--note that the meaning of these fields
  181.     //  may change, so do NOT rely on them in shipping code.
  182.     //
  183.     DWORD                   fdwPrepared;
  184.     DWORD                   dwPrepared;
  185.     LPBYTE                  pbPreparedSrc;
  186.     DWORD                   cbPreparedSrcLength;
  187.     LPBYTE                  pbPreparedDst;
  188.     DWORD                   cbPreparedDstLength;
  189.  
  190. } ACMDRVSTREAMHEADER, *PACMDRVSTREAMHEADER;
  191.  
  192.  
  193. //
  194. //  structure for ACMDM_STREAM_SIZE message
  195. //
  196. //
  197. typedef struct tACMDRVSTREAMSIZE
  198. {
  199.     DWORD               cbStruct;
  200.     DWORD               fdwSize;
  201.     DWORD               cbSrcLength;
  202.     DWORD               cbDstLength;
  203.  
  204. } ACMDRVSTREAMSIZE, *PACMDRVSTREAMSIZE, FAR *LPACMDRVSTREAMSIZE;
  205.  
  206.  
  207.  
  208. //
  209. //  structure containing the information for the ACMDM_FORMAT_SUGGEST message
  210. //
  211. //
  212. typedef struct tACMDRVFORMATSUGGEST
  213. {
  214.     DWORD               cbStruct;           // sizeof(ACMDRVFORMATSUGGEST)
  215.     DWORD               fdwSuggest;         // Suggest flags
  216.     LPWAVEFORMATEX      pwfxSrc;            // Source Format
  217.     DWORD               cbwfxSrc;           // Source Size
  218.     LPWAVEFORMATEX      pwfxDst;            // Dest format
  219.     DWORD               cbwfxDst;           // Dest Size
  220.  
  221. } ACMDRVFORMATSUGGEST, *PACMDRVFORMATSUGGEST, FAR *LPACMDRVFORMATSUGGEST;
  222.  
  223.  
  224. //- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ;
  225. //
  226. //  ACM Driver Messages
  227. //
  228. //
  229. //
  230. //- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ;
  231.  
  232. #define ACMDM_DRIVER_NOTIFY             (ACMDM_BASE + 1)
  233. #define ACMDM_DRIVER_DETAILS            (ACMDM_BASE + 10)
  234.  
  235. #define ACMDM_HARDWARE_WAVE_CAPS_INPUT  (ACMDM_BASE + 20)
  236. #define ACMDM_HARDWARE_WAVE_CAPS_OUTPUT (ACMDM_BASE + 21)
  237.  
  238. #define ACMDM_FORMATTAG_DETAILS         (ACMDM_BASE + 25)
  239. #define ACMDM_FORMAT_DETAILS            (ACMDM_BASE + 26)
  240. #define ACMDM_FORMAT_SUGGEST            (ACMDM_BASE + 27)
  241.  
  242. #define ACMDM_FILTERTAG_DETAILS         (ACMDM_BASE + 50)
  243. #define ACMDM_FILTER_DETAILS            (ACMDM_BASE + 51)
  244.  
  245. #define ACMDM_STREAM_OPEN               (ACMDM_BASE + 76)
  246. #define ACMDM_STREAM_CLOSE              (ACMDM_BASE + 77)
  247. #define ACMDM_STREAM_SIZE               (ACMDM_BASE + 78)
  248. #define ACMDM_STREAM_CONVERT            (ACMDM_BASE + 79)
  249. #define ACMDM_STREAM_RESET              (ACMDM_BASE + 80)
  250. #define ACMDM_STREAM_PREPARE            (ACMDM_BASE + 81)
  251. #define ACMDM_STREAM_UNPREPARE          (ACMDM_BASE + 82)
  252. #define ACMDM_STREAM_UPDATE             (ACMDM_BASE + 83)
  253.  
  254.  
  255. #ifndef RC_INVOKED
  256. #pragma pack()          /* Revert to default packing */
  257. #endif  /* RC_INVOKED */
  258.  
  259. #ifdef __cplusplus
  260. }                       /* End of extern "C" { */
  261. #endif  /* __cplusplus */
  262.  
  263. #endif  /* _INC_ACMDRV */
  264.