1 /*author: Adrian Sandor
7 #pragma GCC system_header
14 typedef HANDLE HACMDRIVERID
, HACMDRIVER
, *LPHACMDRIVER
; /*they're handles, right?*/
16 /*found through experimentation*/
17 #define ACMDRIVERDETAILS_SHORTNAME_CHARS 32
18 #define ACMDRIVERDETAILS_LONGNAME_CHARS 128
19 #define ACMDRIVERDETAILS_COPYRIGHT_CHARS 80
20 #define ACMDRIVERDETAILS_LICENSING_CHARS 128
22 /*I don't know the right values for these macros*/
23 #define ACMFORMATDETAILS_FORMAT_CHARS 256
24 #define ACMFORMATTAGDETAILS_FORMATTAG_CHARS 256
25 #define ACMDRIVERDETAILS_FEATURES_CHARS 256
27 /*msdn.microsoft.com/library/default.asp?url=/library/en-us/multimed/htm/_win32_acmformatdetails_str.asp*/
35 char szFormat
[ACMFORMATDETAILS_FORMAT_CHARS
];
36 } ACMFORMATDETAILSA
, *LPACMFORMATDETAILSA
;
44 WCHAR szFormat
[ACMFORMATDETAILS_FORMAT_CHARS
];
45 } ACMFORMATDETAILSW
, *LPACMFORMATDETAILSW
;
47 /*msdn.microsoft.com/library/default.asp?url=/library/en-us/multimed/htm/_win32_acmformattagdetails_str.asp*/
50 DWORD dwFormatTagIndex
;
54 DWORD cStandardFormats
;
55 char szFormatTag
[ACMFORMATTAGDETAILS_FORMATTAG_CHARS
];
56 } ACMFORMATTAGDETAILSA
, *LPACMFORMATTAGDETAILSA
;
59 DWORD dwFormatTagIndex
;
63 DWORD cStandardFormats
;
64 WCHAR szFormatTag
[ACMFORMATTAGDETAILS_FORMATTAG_CHARS
];
65 } ACMFORMATTAGDETAILSW
, *LPACMFORMATTAGDETAILSW
;
67 /*msdn.microsoft.com/library/default.asp?url=/library/en-us/multimed/htm/_win32_acmdriverdetails_str.asp*/
80 char szShortName
[ACMDRIVERDETAILS_SHORTNAME_CHARS
];
81 char szLongName
[ACMDRIVERDETAILS_LONGNAME_CHARS
];
82 char szCopyright
[ACMDRIVERDETAILS_COPYRIGHT_CHARS
];
83 char szLicensing
[ACMDRIVERDETAILS_LICENSING_CHARS
];
84 char szFeatures
[ACMDRIVERDETAILS_FEATURES_CHARS
];
85 } ACMDRIVERDETAILSA
, *LPACMDRIVERDETAILSA
;
98 WCHAR szShortName
[ACMDRIVERDETAILS_SHORTNAME_CHARS
];
99 WCHAR szLongName
[ACMDRIVERDETAILS_LONGNAME_CHARS
];
100 WCHAR szCopyright
[ACMDRIVERDETAILS_COPYRIGHT_CHARS
];
101 WCHAR szLicensing
[ACMDRIVERDETAILS_LICENSING_CHARS
];
102 WCHAR szFeatures
[ACMDRIVERDETAILS_FEATURES_CHARS
];
103 } ACMDRIVERDETAILSW
, *LPACMDRIVERDETAILSW
;
105 /*msdn.microsoft.com/library/default.asp?url=/library/en-us/multimed/htm/_win32_acmformatenumcallback.asp*/
106 typedef BOOL (CALLBACK
*ACMFORMATENUMCBA
) (
108 LPACMFORMATDETAILSA pafd
,
109 DWORD_PTR dwInstance
,
112 typedef BOOL (CALLBACK
*ACMFORMATENUMCBW
) (
114 LPACMFORMATDETAILSW pafd
,
115 DWORD_PTR dwInstance
,
119 /*msdn.microsoft.com/library/default.asp?url=/library/en-us/multimed/htm/_win32_acmformattagenumcallback.asp*/
120 typedef BOOL (CALLBACK
*ACMFORMATTAGENUMCBA
) (
122 LPACMFORMATTAGDETAILSA paftd
,
123 DWORD_PTR dwInstance
,
126 typedef BOOL (CALLBACK
*ACMFORMATTAGENUMCBW
) (
128 LPACMFORMATTAGDETAILSW paftd
,
129 DWORD_PTR dwInstance
,
133 /*msdn.microsoft.com/library/default.asp?url=/library/en-us/multimed/htm/_win32_acmdriverenumcallback.asp*/
134 typedef BOOL (CALLBACK
*ACMDRIVERENUMCB
) (
136 DWORD_PTR dwInstance
,
140 /*and now the functions...*/
142 /*msdn.microsoft.com/library/default.asp?url=/library/en-us/multimed/htm/_win32_acmdriveropen.asp*/
143 MMRESULT WINAPI
acmDriverOpen(LPHACMDRIVER phad
, HACMDRIVERID hadid
, DWORD fdwOpen
);
144 /*msdn.microsoft.com/library/default.asp?url=/library/en-us/multimed/htm/_win32_acmdriverenum.asp*/
145 MMRESULT WINAPI
acmDriverEnum(ACMDRIVERENUMCB fnCallback
, DWORD_PTR dwInstance
, DWORD fdwEnum
);
146 /*msdn.microsoft.com/library/default.asp?url=/library/en-us/multimed/htm/_win32_acmformatenum.asp*/
147 MMRESULT WINAPI
acmFormatEnumA(HACMDRIVER had
, LPACMFORMATDETAILSA pafd
, ACMFORMATENUMCBA fnCallback
, DWORD_PTR dwInstance
, DWORD fdwEnum
);
148 MMRESULT WINAPI
acmFormatEnumW(HACMDRIVER had
, LPACMFORMATDETAILSW pafd
, ACMFORMATENUMCBW fnCallback
, DWORD_PTR dwInstance
, DWORD fdwEnum
);
149 /*msdn.microsoft.com/library/default.asp?url=/library/en-us/multimed/htm/_win32_acmdriverclose.asp*/
150 MMRESULT WINAPI
acmDriverClose(HACMDRIVER had
, DWORD fdwClose
);
151 /*msdn.microsoft.com/library/default.asp?url=/library/en-us/multimed/htm/_win32_acmdriverdetails.asp*/
152 MMRESULT WINAPI
acmDriverDetailsA(HACMDRIVERID hadid
, LPACMDRIVERDETAILSA padd
, DWORD fdwDetails
);
153 MMRESULT WINAPI
acmDriverDetailsW(HACMDRIVERID hadid
, LPACMDRIVERDETAILSW padd
, DWORD fdwDetails
);
154 /*msdn.microsoft.com/library/default.asp?url=/library/en-us/multimed/htm/_win32_acmformattagenum.asp*/
155 MMRESULT WINAPI
acmFormatTagEnumA(HACMDRIVER had
, LPACMFORMATTAGDETAILSA paftd
, ACMFORMATTAGENUMCBA fnCallback
, DWORD_PTR dwInstance
, DWORD fdwEnum
);
156 MMRESULT WINAPI
acmFormatTagEnumW(HACMDRIVER had
, LPACMFORMATTAGDETAILSW paftd
, ACMFORMATTAGENUMCBW fnCallback
, DWORD_PTR dwInstance
, DWORD fdwEnum
);
160 typedef ACMFORMATDETAILSW ACMFORMATDETAILS
, *LPACMFORMATDETAILS
;
161 typedef ACMFORMATTAGDETAILSW ACMFORMATTAGDETAILS
, *LPACMFORMATTAGDETAILS
;
162 typedef ACMDRIVERDETAILSW ACMDRIVERDETAILS
, *LPACMDRIVERDETAILS
;
163 typedef ACMFORMATENUMCBW ACMFORMATENUMCB
;
164 typedef ACMFORMATTAGENUMCBW ACMFORMATTAGENUMCB
;
165 #define acmFormatEnum acmFormatEnumW
166 #define acmDriverDetails acmDriverDetailsW
167 #define acmFormatTagEnum acmFormatTagEnumW
169 #else /*ifdef UNICODE*/
171 typedef ACMFORMATDETAILSA ACMFORMATDETAILS
, *LPACMFORMATDETAILS
;
172 typedef ACMFORMATTAGDETAILSA ACMFORMATTAGDETAILS
, *LPACMFORMATTAGDETAILS
;
173 typedef ACMDRIVERDETAILSA ACMDRIVERDETAILS
, *LPACMDRIVERDETAILS
;
174 typedef ACMFORMATENUMCBA ACMFORMATENUMCB
;
175 typedef ACMFORMATTAGENUMCBA ACMFORMATTAGENUMCB
;
176 #define acmFormatEnum acmFormatEnumA
177 #define acmDriverDetails acmDriverDetailsA
178 #define acmFormatTagEnum acmFormatTagEnumA
180 #endif /*ifdef UNICODE*/