The OpenD Programming Language

1 /**
2  * Windows API header module
3  *
4  * Translated from MinGW Windows headers
5  *
6  * License: $(LINK2 http://www.boost.org/LICENSE_1_0.txt, Boost License 1.0)
7  * Source: $(DRUNTIMESRC core/sys/windows/_mmsystem.d)
8  */
9 module core.sys.windows.mmsystem;
10 version (Windows):
11 
12 version (ANSI) {} else version = Unicode;
13 pragma(lib, "winmm");
14 
15 /*  The #defines MAKEFOURCC, mmioFOURCC, sndAlias are used to define
16  *  compile-time constants, so they are implemented as templates.
17  */
18 
19 import core.sys.windows.w32api, core.sys.windows.windef, core.sys.windows.winver;
20 
21 align(1):
22 
23 enum MAXPNAMELEN = 32;
24 enum MAXERRORLENGTH = 256;
25 enum MAX_JOYSTICKOEMVXDNAME = 260;
26 
27 enum TIME_MS      = 1;
28 enum TIME_SAMPLES = 2;
29 enum TIME_BYTES   = 4;
30 enum TIME_SMPTE   = 8;
31 enum TIME_MIDI    = 16;
32 enum TIME_TICKS   = 32;
33 
34 template MAKEFOURCC(char c0, char c1, char c2, char c3)
35 {
36 enum DWORD MAKEFOURCC = c0 | (c1<<8) | (c2<<16) | (cast(DWORD)c3 <<24);
37 }
38 
39 template mmioFOURCC(char c0, char c1, char c2, char c3)
40 {
41 enum DWORD mmioFOURCC = c0 | (c1<<8) | (c2<<16) | (cast(DWORD)c3 <<24);
42 }
43 
44 enum {
45     MM_JOY1MOVE            = 0x3A0,
46     MM_JOY2MOVE,
47     MM_JOY1ZMOVE,
48     MM_JOY2ZMOVE,       // = 0x3A3
49     MM_JOY1BUTTONDOWN      = 0x3B5,
50     MM_JOY2BUTTONDOWN,
51     MM_JOY1BUTTONUP,
52     MM_JOY2BUTTONUP,
53     MM_MCINOTIFY,       // = 0x3B9
54     MM_WOM_OPEN            = 0x3BB,
55     MM_WOM_CLOSE,
56     MM_WOM_DONE,
57     MM_WIM_OPEN,
58     MM_WIM_CLOSE,
59     MM_WIM_DATA,
60     MM_MIM_OPEN,
61     MM_MIM_CLOSE,
62     MM_MIM_DATA,
63     MM_MIM_LONGDATA,
64     MM_MIM_ERROR,
65     MM_MIM_LONGERROR,
66     MM_MOM_OPEN,
67     MM_MOM_CLOSE,
68     MM_MOM_DONE,        // = 0x3C9
69     MM_DRVM_OPEN           = 0x3D0,
70     MM_DRVM_CLOSE,
71     MM_DRVM_DATA,
72     MM_DRVM_ERROR,
73     MM_STREAM_OPEN,
74     MM_STREAM_CLOSE,
75     MM_STREAM_DONE,
76     MM_STREAM_ERROR,    // = 0x3D7
77     MM_MOM_POSITIONCB      = 0x3CA,
78     MM_MCISIGNAL,
79     MM_MIM_MOREDATA,    // = 0x3CC
80     MM_MIXM_LINE_CHANGE    = 0x3D0,
81     MM_MIXM_CONTROL_CHANGE = 0x3D1
82 }
83 
84 enum MMSYSERR_BASE     =    0;
85 enum WAVERR_BASE       =   32;
86 enum MIDIERR_BASE      =   64;
87 enum TIMERR_BASE       =   96;
88 enum JOYERR_BASE       =  160;
89 enum MCIERR_BASE       =  256;
90 enum MIXERR_BASE       = 1024;
91 enum MCI_STRING_OFFSET =  512;
92 enum MCI_VD_OFFSET     = 1024;
93 enum MCI_CD_OFFSET     = 1088;
94 enum MCI_WAVE_OFFSET   = 1152;
95 enum MCI_SEQ_OFFSET    = 1216;
96 
97 enum {
98     MMSYSERR_NOERROR        = 0,
99     MMSYSERR_ERROR          = MMSYSERR_BASE+1,
100     MMSYSERR_BADDEVICEID,
101     MMSYSERR_NOTENABLED,
102     MMSYSERR_ALLOCATED,
103     MMSYSERR_INVALHANDLE,
104     MMSYSERR_NODRIVER,
105     MMSYSERR_NOMEM,
106     MMSYSERR_NOTSUPPORTED,
107     MMSYSERR_BADERRNUM,
108     MMSYSERR_INVALFLAG,
109     MMSYSERR_INVALPARAM,
110     MMSYSERR_HANDLEBUSY,
111     MMSYSERR_INVALIDALIAS,
112     MMSYSERR_BADDB,
113     MMSYSERR_KEYNOTFOUND,
114     MMSYSERR_READERROR,
115     MMSYSERR_WRITEERROR,
116     MMSYSERR_DELETEERROR,
117     MMSYSERR_VALNOTFOUND,
118     MMSYSERR_NODRIVERCB, // = MMSYSERR_BASE+20
119     MMSYSERR_LASTERROR      = MMSYSERR_NODRIVERCB
120 }
121 
122 enum {
123     DRV_LOAD = 1,
124     DRV_ENABLE,
125     DRV_OPEN,
126     DRV_CLOSE,
127     DRV_DISABLE,
128     DRV_FREE,
129     DRV_CONFIGURE,
130     DRV_QUERYCONFIGURE,
131     DRV_INSTALL,
132     DRV_REMOVE,
133     DRV_EXITSESSION,
134     DRV_POWER
135 }
136 
137 enum DRV_RESERVED = 0x800;
138 enum DRV_USER = 0x4000;
139 
140 enum DRVCNF_CANCEL = 0;
141 enum DRVCNF_OK = 1;
142 enum DRVCNF_RESTART = 2;
143 enum DRV_CANCEL = DRVCNF_CANCEL;
144 enum DRV_OK = DRVCNF_OK;
145 enum DRV_RESTART = DRVCNF_RESTART;
146 enum DRV_MCI_FIRST = DRV_RESERVED;
147 enum DRV_MCI_LAST  = DRV_RESERVED + 0xFFF;
148 
149 enum CALLBACK_TYPEMASK = 0x70000;
150 enum CALLBACK_NULL     = 0;
151 enum CALLBACK_WINDOW   = 0x10000;
152 enum CALLBACK_TASK     = 0x20000;
153 enum CALLBACK_FUNCTION = 0x30000;
154 enum CALLBACK_THREAD   = CALLBACK_TASK;
155 enum CALLBACK_EVENT    = 0x50000;
156 
157 enum SND_SYNC=0;
158 enum SND_ASYNC=1;
159 enum SND_NODEFAULT=2;
160 enum SND_MEMORY=4;
161 enum SND_LOOP=8;
162 enum SND_NOSTOP=16;
163 enum SND_NOWAIT=0x2000;
164 enum SND_ALIAS=0x10000;
165 enum SND_ALIAS_ID=0x110000;
166 enum SND_FILENAME=0x20000;
167 enum SND_RESOURCE=0x40004;
168 enum SND_PURGE=0x40;
169 enum SND_APPLICATION=0x80;
170 enum SND_ALIAS_START=0;
171 
172 template sndAlias(char c0, char c1)
173 {
174 enum DWORD sndAlias = SND_ALIAS_START + c0 | (c1<<8);
175 }
176 
177 enum SND_ALIAS_SYSTEMASTERISK    = sndAlias!('S', '*');
178 enum SND_ALIAS_SYSTEMQUESTION    = sndAlias!('S', '?');
179 enum SND_ALIAS_SYSTEMHAND        = sndAlias!('S', 'H');
180 enum SND_ALIAS_SYSTEMEXIT        = sndAlias!('S', 'E');
181 enum SND_ALIAS_SYSTEMSTART       = sndAlias!('S', 'S');
182 enum SND_ALIAS_SYSTEMWELCOME     = sndAlias!('S', 'W');
183 enum SND_ALIAS_SYSTEMEXCLAMATION = sndAlias!('S', '!');
184 enum SND_ALIAS_SYSTEMDEFAULT     = sndAlias!('S', 'D');
185 
186 enum {
187     WAVERR_BADFORMAT  = (WAVERR_BASE + 0),
188     WAVERR_STILLPLAYING,
189     WAVERR_UNPREPARED,
190     WAVERR_SYNC,  // = WAVERR_BASE + 3;
191     WAVERR_LASTERROR = WAVERR_SYNC
192 }
193 
194 enum WOM_OPEN  = MM_WOM_OPEN;
195 enum WOM_CLOSE = MM_WOM_CLOSE;
196 enum WOM_DONE  = MM_WOM_DONE;
197 enum WIM_OPEN  = MM_WIM_OPEN;
198 enum WIM_CLOSE = MM_WIM_CLOSE;
199 enum WIM_DATA  = MM_WIM_DATA;
200 
201 enum UINT WAVE_MAPPER= -1;  // FIXME: This doesn't make sense!
202 enum WAVE_FORMAT_QUERY=1;
203 enum WAVE_ALLOWSYNC=2;
204 enum WAVE_MAPPED=4;
205 enum WAVE_FORMAT_DIRECT=8;
206 enum WAVE_FORMAT_DIRECT_QUERY=(WAVE_FORMAT_QUERY|WAVE_FORMAT_DIRECT);
207 enum WHDR_DONE=1;
208 enum WHDR_PREPARED=2;
209 enum WHDR_BEGINLOOP=4;
210 enum WHDR_ENDLOOP=8;
211 enum WHDR_INQUEUE=16;
212 
213 enum WAVECAPS_PITCH=1;
214 enum WAVECAPS_PLAYBACKRATE=2;
215 enum WAVECAPS_VOLUME=4;
216 enum WAVECAPS_LRVOLUME=8;
217 enum WAVECAPS_SYNC=16;
218 enum WAVECAPS_SAMPLEACCURATE=32;
219 enum WAVECAPS_DIRECTSOUND=64;
220 
221 enum WAVE_INVALIDFORMAT=0;
222 enum WAVE_FORMAT_1M08=1;
223 enum WAVE_FORMAT_1S08=2;
224 enum WAVE_FORMAT_1M16=4;
225 enum WAVE_FORMAT_1S16=8;
226 enum WAVE_FORMAT_2M08=16;
227 enum WAVE_FORMAT_2S08=32;
228 enum WAVE_FORMAT_2M16=64;
229 enum WAVE_FORMAT_2S16=128;
230 enum WAVE_FORMAT_4M08=256;
231 enum WAVE_FORMAT_4S08=512;
232 enum WAVE_FORMAT_4M16=1024;
233 enum WAVE_FORMAT_4S16=2048;
234 enum WAVE_FORMAT_PCM=1;
235 
236 enum {
237     MIDIERR_UNPREPARED = MIDIERR_BASE,
238     MIDIERR_STILLPLAYING,
239     MIDIERR_NOMAP,
240     MIDIERR_NOTREADY,
241     MIDIERR_NODEVICE,
242     MIDIERR_INVALIDSETUP,
243     MIDIERR_BADOPENMODE,
244     MIDIERR_DONT_CONTINUE, // = MIDIERR_BASE+7
245     MIDIERR_LASTERROR = MIDIERR_DONT_CONTINUE
246 }
247 
248 enum MIDIPATCHSIZE=128;
249 
250 enum MIM_OPEN=MM_MIM_OPEN;
251 enum MIM_CLOSE=MM_MIM_CLOSE;
252 enum MIM_DATA=MM_MIM_DATA;
253 enum MIM_LONGDATA=MM_MIM_LONGDATA;
254 enum MIM_ERROR=MM_MIM_ERROR;
255 enum MIM_LONGERROR=MM_MIM_LONGERROR;
256 enum MOM_OPEN=MM_MOM_OPEN;
257 enum MOM_CLOSE=MM_MOM_CLOSE;
258 enum MOM_DONE=MM_MOM_DONE;
259 enum MIM_MOREDATA=MM_MIM_MOREDATA;
260 enum MOM_POSITIONCB=MM_MOM_POSITIONCB;
261 
262 enum UINT MIDIMAPPER= -1; // FIXME: uint is nonsense for this!
263 enum UINT MIDI_MAPPER= -1; // FIXME: uint is nonsense for this!
264 enum MIDI_IO_STATUS=32;
265 enum MIDI_CACHE_ALL=1;
266 enum MIDI_CACHE_BESTFIT=2;
267 enum MIDI_CACHE_QUERY=3;
268 enum MIDI_UNCACHE=4;
269 enum MOD_MIDIPORT=1;
270 enum MOD_SYNTH=2;
271 enum MOD_SQSYNTH=3;
272 enum MOD_FMSYNTH=4;
273 enum MOD_MAPPER=5;
274 enum MIDICAPS_VOLUME=1;
275 enum MIDICAPS_LRVOLUME=2;
276 enum MIDICAPS_CACHE=4;
277 enum MIDICAPS_STREAM=8;
278 enum MHDR_DONE=1;
279 enum MHDR_PREPARED=2;
280 enum MHDR_INQUEUE=4;
281 enum MHDR_ISSTRM=8;
282 enum MEVT_F_SHORT=0;
283 enum MEVT_F_LONG=0x80000000;
284 enum MEVT_F_CALLBACK=0x40000000;
285 
286 BYTE MEVT_EVENTTYPE(DWORD x) { return cast(BYTE)((x>>24) &0xFF); }
287 DWORD MEVT_EVENTPARM(DWORD x) { return x & 0xFFFFFF; }
288 
289 enum MEVT_SHORTMSG=0;
290 enum MEVT_TEMPO=1;
291 enum MEVT_NOP=2;
292 
293 enum BYTE MEVT_LONGMSG = 0x80;
294 enum BYTE MEVT_COMMENT = 0x82;
295 enum BYTE MEVT_VERSION = 0x84;
296 
297 enum MIDISTRM_ERROR = -2;
298 
299 enum MIDIPROP_SET = 0x80000000;
300 enum MIDIPROP_GET = 0x40000000;
301 enum MIDIPROP_TIMEDIV = 1;
302 enum MIDIPROP_TEMPO = 2;
303 
304 enum UINT AUX_MAPPER = -1;
305 
306 enum AUXCAPS_CDAUDIO=1;
307 enum AUXCAPS_AUXIN=2;
308 enum AUXCAPS_VOLUME=1;
309 enum AUXCAPS_LRVOLUME=2;
310 enum MIXER_SHORT_NAME_CHARS=16;
311 enum MIXER_LONG_NAME_CHARS=64;
312 enum MIXERR_INVALLINE=MIXERR_BASE;
313 enum MIXERR_INVALCONTROL=(MIXERR_BASE+1);
314 enum MIXERR_INVALVALUE=(MIXERR_BASE+2);
315 enum MIXERR_LASTERROR=(MIXERR_BASE+2);
316 
317 enum MIXER_OBJECTF_HANDLE=0x80000000;
318 enum MIXER_OBJECTF_MIXER=0;
319 enum MIXER_OBJECTF_HMIXER=(MIXER_OBJECTF_HANDLE|MIXER_OBJECTF_MIXER);
320 enum MIXER_OBJECTF_WAVEOUT=0x10000000;
321 enum MIXER_OBJECTF_HWAVEOUT=(MIXER_OBJECTF_HANDLE|MIXER_OBJECTF_WAVEOUT);
322 enum MIXER_OBJECTF_WAVEIN=0x20000000;
323 enum MIXER_OBJECTF_HWAVEIN=(MIXER_OBJECTF_HANDLE|MIXER_OBJECTF_WAVEIN);
324 enum MIXER_OBJECTF_MIDIOUT=0x30000000;
325 enum MIXER_OBJECTF_HMIDIOUT=(MIXER_OBJECTF_HANDLE|MIXER_OBJECTF_MIDIOUT);
326 enum MIXER_OBJECTF_MIDIIN=0x40000000;
327 enum MIXER_OBJECTF_HMIDIIN=(MIXER_OBJECTF_HANDLE|MIXER_OBJECTF_MIDIIN);
328 enum MIXER_OBJECTF_AUX=0x50000000;
329 
330 enum MIXERLINE_LINEF_ACTIVE=1;
331 enum MIXERLINE_LINEF_DISCONNECTED=0x8000;
332 enum MIXERLINE_LINEF_SOURCE=0x80000000;
333 
334 enum MIXERLINE_COMPONENTTYPE_DST_FIRST=0;
335 enum MIXERLINE_COMPONENTTYPE_DST_UNDEFINED=MIXERLINE_COMPONENTTYPE_DST_FIRST;
336 enum MIXERLINE_COMPONENTTYPE_DST_DIGITAL=(MIXERLINE_COMPONENTTYPE_DST_FIRST+1);
337 enum MIXERLINE_COMPONENTTYPE_DST_LINE=(MIXERLINE_COMPONENTTYPE_DST_FIRST+2);
338 enum MIXERLINE_COMPONENTTYPE_DST_MONITOR=(MIXERLINE_COMPONENTTYPE_DST_FIRST+3);
339 enum MIXERLINE_COMPONENTTYPE_DST_SPEAKERS=(MIXERLINE_COMPONENTTYPE_DST_FIRST+4);
340 enum MIXERLINE_COMPONENTTYPE_DST_HEADPHONES=(MIXERLINE_COMPONENTTYPE_DST_FIRST+5);
341 enum MIXERLINE_COMPONENTTYPE_DST_TELEPHONE=(MIXERLINE_COMPONENTTYPE_DST_FIRST+6);
342 enum MIXERLINE_COMPONENTTYPE_DST_WAVEIN=(MIXERLINE_COMPONENTTYPE_DST_FIRST+7);
343 enum MIXERLINE_COMPONENTTYPE_DST_VOICEIN=(MIXERLINE_COMPONENTTYPE_DST_FIRST+8);
344 enum MIXERLINE_COMPONENTTYPE_DST_LAST=(MIXERLINE_COMPONENTTYPE_DST_FIRST+8);
345 enum MIXERLINE_COMPONENTTYPE_SRC_FIRST=0x1000;
346 enum MIXERLINE_COMPONENTTYPE_SRC_UNDEFINED=MIXERLINE_COMPONENTTYPE_SRC_FIRST;
347 enum MIXERLINE_COMPONENTTYPE_SRC_DIGITAL=(MIXERLINE_COMPONENTTYPE_SRC_FIRST+1);
348 enum MIXERLINE_COMPONENTTYPE_SRC_LINE=(MIXERLINE_COMPONENTTYPE_SRC_FIRST+2);
349 enum MIXERLINE_COMPONENTTYPE_SRC_MICROPHONE=(MIXERLINE_COMPONENTTYPE_SRC_FIRST+3);
350 enum MIXERLINE_COMPONENTTYPE_SRC_SYNTHESIZER=(MIXERLINE_COMPONENTTYPE_SRC_FIRST+4);
351 enum MIXERLINE_COMPONENTTYPE_SRC_COMPACTDISC=(MIXERLINE_COMPONENTTYPE_SRC_FIRST+5);
352 enum MIXERLINE_COMPONENTTYPE_SRC_TELEPHONE=(MIXERLINE_COMPONENTTYPE_SRC_FIRST+6);
353 enum MIXERLINE_COMPONENTTYPE_SRC_PCSPEAKER=(MIXERLINE_COMPONENTTYPE_SRC_FIRST+7);
354 enum MIXERLINE_COMPONENTTYPE_SRC_WAVEOUT=(MIXERLINE_COMPONENTTYPE_SRC_FIRST+8);
355 enum MIXERLINE_COMPONENTTYPE_SRC_AUXILIARY=(MIXERLINE_COMPONENTTYPE_SRC_FIRST+9);
356 enum MIXERLINE_COMPONENTTYPE_SRC_ANALOG=(MIXERLINE_COMPONENTTYPE_SRC_FIRST+10);
357 enum MIXERLINE_COMPONENTTYPE_SRC_LAST=(MIXERLINE_COMPONENTTYPE_SRC_FIRST+10);
358 
359 enum {
360     MIXERLINE_TARGETTYPE_UNDEFINED = 0,
361     MIXERLINE_TARGETTYPE_WAVEOUT,
362     MIXERLINE_TARGETTYPE_WAVEIN,
363     MIXERLINE_TARGETTYPE_MIDIOUT,
364     MIXERLINE_TARGETTYPE_MIDIIN,
365     MIXERLINE_TARGETTYPE_AUX // =5
366 }
367 
368 enum MIXER_GETLINEINFOF_DESTINATION=0;
369 enum MIXER_GETLINEINFOF_SOURCE=1;
370 enum MIXER_GETLINEINFOF_LINEID=2;
371 enum MIXER_GETLINEINFOF_COMPONENTTYPE=3;
372 enum MIXER_GETLINEINFOF_TARGETTYPE=4;
373 enum MIXER_GETLINEINFOF_QUERYMASK=15;
374 
375 enum MIXERCONTROL_CONTROLF_UNIFORM=1;
376 enum MIXERCONTROL_CONTROLF_MULTIPLE=2;
377 enum MIXERCONTROL_CONTROLF_DISABLED=0x80000000;
378 enum MIXERCONTROL_CT_CLASS_MASK=0xF0000000;
379 enum MIXERCONTROL_CT_CLASS_CUSTOM=0;
380 enum MIXERCONTROL_CT_CLASS_METER=0x10000000;
381 enum MIXERCONTROL_CT_CLASS_SWITCH=0x20000000;
382 enum MIXERCONTROL_CT_CLASS_NUMBER=0x30000000;
383 enum MIXERCONTROL_CT_CLASS_SLIDER=0x40000000;
384 enum MIXERCONTROL_CT_CLASS_FADER=0x50000000;
385 enum MIXERCONTROL_CT_CLASS_TIME=0x60000000;
386 enum MIXERCONTROL_CT_CLASS_LIST=0x70000000;
387 enum MIXERCONTROL_CT_SUBCLASS_MASK=0xF000000;
388 enum MIXERCONTROL_CT_SC_SWITCH_BOOLEAN=0;
389 enum MIXERCONTROL_CT_SC_SWITCH_BUTTON=0x1000000;
390 enum MIXERCONTROL_CT_SC_METER_POLLED=0;
391 enum MIXERCONTROL_CT_SC_TIME_MICROSECS=0;
392 enum MIXERCONTROL_CT_SC_TIME_MILLISECS=0x1000000;
393 enum MIXERCONTROL_CT_SC_LIST_SINGLE=0;
394 enum MIXERCONTROL_CT_SC_LIST_MULTIPLE=0x1000000;
395 enum MIXERCONTROL_CT_UNITS_MASK=0xFF0000;
396 enum MIXERCONTROL_CT_UNITS_CUSTOM=0;
397 enum MIXERCONTROL_CT_UNITS_BOOLEAN=0x10000;
398 enum MIXERCONTROL_CT_UNITS_SIGNED=0x20000;
399 enum MIXERCONTROL_CT_UNITS_UNSIGNED=0x30000;
400 enum MIXERCONTROL_CT_UNITS_DECIBELS=0x40000;
401 enum MIXERCONTROL_CT_UNITS_PERCENT=0x50000;
402 
403 enum MIXERCONTROL_CONTROLTYPE_CUSTOM=(MIXERCONTROL_CT_CLASS_CUSTOM|MIXERCONTROL_CT_UNITS_CUSTOM);
404 enum MIXERCONTROL_CONTROLTYPE_BOOLEANMETER=(MIXERCONTROL_CT_CLASS_METER|MIXERCONTROL_CT_SC_METER_POLLED|MIXERCONTROL_CT_UNITS_BOOLEAN);
405 enum MIXERCONTROL_CONTROLTYPE_SIGNEDMETER=(MIXERCONTROL_CT_CLASS_METER|MIXERCONTROL_CT_SC_METER_POLLED|MIXERCONTROL_CT_UNITS_SIGNED);
406 enum MIXERCONTROL_CONTROLTYPE_PEAKMETER=(MIXERCONTROL_CONTROLTYPE_SIGNEDMETER+1);
407 enum MIXERCONTROL_CONTROLTYPE_UNSIGNEDMETER=(MIXERCONTROL_CT_CLASS_METER|MIXERCONTROL_CT_SC_METER_POLLED|MIXERCONTROL_CT_UNITS_UNSIGNED);
408 enum MIXERCONTROL_CONTROLTYPE_BOOLEAN=(MIXERCONTROL_CT_CLASS_SWITCH|MIXERCONTROL_CT_SC_SWITCH_BOOLEAN|MIXERCONTROL_CT_UNITS_BOOLEAN);
409 enum MIXERCONTROL_CONTROLTYPE_ONOFF=(MIXERCONTROL_CONTROLTYPE_BOOLEAN+1);
410 enum MIXERCONTROL_CONTROLTYPE_MUTE=(MIXERCONTROL_CONTROLTYPE_BOOLEAN+2);
411 enum MIXERCONTROL_CONTROLTYPE_MONO=(MIXERCONTROL_CONTROLTYPE_BOOLEAN+3);
412 enum MIXERCONTROL_CONTROLTYPE_LOUDNESS=(MIXERCONTROL_CONTROLTYPE_BOOLEAN+4);
413 enum MIXERCONTROL_CONTROLTYPE_STEREOENH=(MIXERCONTROL_CONTROLTYPE_BOOLEAN+5);
414 enum MIXERCONTROL_CONTROLTYPE_BUTTON=(MIXERCONTROL_CT_CLASS_SWITCH|MIXERCONTROL_CT_SC_SWITCH_BUTTON|MIXERCONTROL_CT_UNITS_BOOLEAN);
415 enum MIXERCONTROL_CONTROLTYPE_DECIBELS=(MIXERCONTROL_CT_CLASS_NUMBER|MIXERCONTROL_CT_UNITS_DECIBELS);
416 enum MIXERCONTROL_CONTROLTYPE_SIGNED=(MIXERCONTROL_CT_CLASS_NUMBER|MIXERCONTROL_CT_UNITS_SIGNED);
417 enum MIXERCONTROL_CONTROLTYPE_UNSIGNED=(MIXERCONTROL_CT_CLASS_NUMBER|MIXERCONTROL_CT_UNITS_UNSIGNED);
418 enum MIXERCONTROL_CONTROLTYPE_PERCENT=(MIXERCONTROL_CT_CLASS_NUMBER|MIXERCONTROL_CT_UNITS_PERCENT);
419 enum MIXERCONTROL_CONTROLTYPE_SLIDER=(MIXERCONTROL_CT_CLASS_SLIDER|MIXERCONTROL_CT_UNITS_SIGNED);
420 enum MIXERCONTROL_CONTROLTYPE_PAN=(MIXERCONTROL_CONTROLTYPE_SLIDER+1);
421 enum MIXERCONTROL_CONTROLTYPE_QSOUNDPAN=(MIXERCONTROL_CONTROLTYPE_SLIDER+2);
422 enum MIXERCONTROL_CONTROLTYPE_FADER=(MIXERCONTROL_CT_CLASS_FADER|MIXERCONTROL_CT_UNITS_UNSIGNED);
423 enum MIXERCONTROL_CONTROLTYPE_VOLUME=(MIXERCONTROL_CONTROLTYPE_FADER+1);
424 enum MIXERCONTROL_CONTROLTYPE_BASS=(MIXERCONTROL_CONTROLTYPE_FADER+2);
425 enum MIXERCONTROL_CONTROLTYPE_TREBLE=(MIXERCONTROL_CONTROLTYPE_FADER+3);
426 enum MIXERCONTROL_CONTROLTYPE_EQUALIZER=(MIXERCONTROL_CONTROLTYPE_FADER+4);
427 enum MIXERCONTROL_CONTROLTYPE_SINGLESELECT=(MIXERCONTROL_CT_CLASS_LIST|MIXERCONTROL_CT_SC_LIST_SINGLE|MIXERCONTROL_CT_UNITS_BOOLEAN);
428 enum MIXERCONTROL_CONTROLTYPE_MUX=(MIXERCONTROL_CONTROLTYPE_SINGLESELECT+1);
429 enum MIXERCONTROL_CONTROLTYPE_MULTIPLESELECT=(MIXERCONTROL_CT_CLASS_LIST|MIXERCONTROL_CT_SC_LIST_MULTIPLE|MIXERCONTROL_CT_UNITS_BOOLEAN);
430 enum MIXERCONTROL_CONTROLTYPE_MIXER=(MIXERCONTROL_CONTROLTYPE_MULTIPLESELECT+1);
431 enum MIXERCONTROL_CONTROLTYPE_MICROTIME=(MIXERCONTROL_CT_CLASS_TIME|MIXERCONTROL_CT_SC_TIME_MICROSECS|MIXERCONTROL_CT_UNITS_UNSIGNED);
432 enum MIXERCONTROL_CONTROLTYPE_MILLITIME=(MIXERCONTROL_CT_CLASS_TIME|MIXERCONTROL_CT_SC_TIME_MILLISECS|MIXERCONTROL_CT_UNITS_UNSIGNED);
433 
434 enum MIXER_GETLINECONTROLSF_ALL=0;
435 enum MIXER_GETLINECONTROLSF_ONEBYID=1;
436 enum MIXER_GETLINECONTROLSF_ONEBYTYPE=2;
437 enum MIXER_GETLINECONTROLSF_QUERYMASK=15;
438 enum MIXER_GETCONTROLDETAILSF_VALUE=0;
439 enum MIXER_GETCONTROLDETAILSF_LISTTEXT=1;
440 enum MIXER_GETCONTROLDETAILSF_QUERYMASK=15;
441 enum MIXER_SETCONTROLDETAILSF_VALUE=0;
442 enum MIXER_SETCONTROLDETAILSF_CUSTOM=1;
443 enum MIXER_SETCONTROLDETAILSF_QUERYMASK=15;
444 
445 enum TIMERR_NOERROR=0;
446 enum TIMERR_NOCANDO=(TIMERR_BASE+1);
447 enum TIMERR_STRUCT=(TIMERR_BASE+33);
448 enum TIME_ONESHOT=0;
449 enum TIME_PERIODIC=1;
450 enum TIME_CALLBACK_FUNCTION=0;
451 enum TIME_CALLBACK_EVENT_SET=16;
452 enum TIME_CALLBACK_EVENT_PULSE=32;
453 
454 static if (_WIN32_WINNT >= 0x501) {
455 
456 enum TIME_KILL_SYNCHRONOUS=0x0100;
457 
458 }
459 
460 enum JOYERR_NOERROR = 0;
461 enum JOYERR_PARMS=(JOYERR_BASE+5);
462 enum JOYERR_NOCANDO=(JOYERR_BASE+6);
463 enum JOYERR_UNPLUGGED=(JOYERR_BASE+7);
464 
465 enum JOY_BUTTON1=1;
466 enum JOY_BUTTON2=2;
467 enum JOY_BUTTON3=4;
468 enum JOY_BUTTON4=8;
469 enum JOY_BUTTON1CHG=256;
470 enum JOY_BUTTON2CHG=512;
471 enum JOY_BUTTON3CHG=1024;
472 enum JOY_BUTTON4CHG=2048;
473 enum JOY_BUTTON5=257;
474 enum JOY_BUTTON6=513;
475 enum JOY_BUTTON7=1025;
476 enum JOY_BUTTON8=2049;
477 enum JOY_BUTTON9=256;
478 enum JOY_BUTTON10=512;
479 enum JOY_BUTTON11=1024;
480 enum JOY_BUTTON12=2048;
481 enum JOY_BUTTON13=4096;
482 enum JOY_BUTTON14=8192;
483 enum JOY_BUTTON15=16384;
484 enum JOY_BUTTON16=32768;
485 enum JOY_BUTTON17=65536;
486 enum JOY_BUTTON18=0x20000;
487 enum JOY_BUTTON19=0x40000;
488 enum JOY_BUTTON20=0x80000;
489 enum JOY_BUTTON21=0x100000;
490 enum JOY_BUTTON22=0x200000;
491 enum JOY_BUTTON23=0x400000;
492 enum JOY_BUTTON24=0x800000;
493 enum JOY_BUTTON25=0x1000000;
494 enum JOY_BUTTON26=0x2000000;
495 enum JOY_BUTTON27=0x4000000;
496 enum JOY_BUTTON28=0x8000000;
497 enum JOY_BUTTON29=0x10000000;
498 enum JOY_BUTTON30=0x20000000;
499 enum JOY_BUTTON31=0x40000000;
500 enum JOY_BUTTON32=0x80000000;
501 
502 enum  : DWORD {
503     JOY_POVCENTERED = -1,
504     JOY_POVFORWARD  = 0,
505     JOY_POVBACKWARD = 18000,
506     JOY_POVLEFT     = 27000,
507     JOY_POVRIGHT    = 9000
508 }
509 
510 enum DWORD
511     JOY_RETURNX        = 0x00000001,
512     JOY_RETURNY        = 0x00000002,
513     JOY_RETURNZ        = 0x00000004,
514     JOY_RETURNR        = 0x00000008,
515     JOY_RETURNU        = 0x00000010,
516     JOY_RETURNV        = 0x00000020,
517     JOY_RETURNPOV      = 0x00000040,
518     JOY_RETURNBUTTONS  = 0x00000080,
519     JOY_RETURNRAWDATA  = 0x00000100,
520     JOY_RETURNPOVCTS   = 0x00000200,
521     JOY_RETURNCENTERED = 0x00000400,
522     JOY_USEDEADZONE    = 0x00000800,
523     JOY_RETURNALL      = JOY_RETURNX | JOY_RETURNY | JOY_RETURNZ | JOY_RETURNR
524                          | JOY_RETURNU | JOY_RETURNV | JOY_RETURNPOV
525                          | JOY_RETURNBUTTONS,
526     JOY_CAL_READALWAYS = 0x00010000,
527     JOY_CAL_READXYONLY = 0x00020000,
528     JOY_CAL_READ3      = 0x00040000,
529     JOY_CAL_READ4      = 0x00080000,
530     JOY_CAL_READXONLY  = 0x00100000,
531     JOY_CAL_READYONLY  = 0x00200000,
532     JOY_CAL_READ5      = 0x00400000,
533     JOY_CAL_READ6      = 0x00800000,
534     JOY_CAL_READZONLY  = 0x01000000,
535     JOY_CAL_READRONLY  = 0x02000000,
536     JOY_CAL_READUONLY  = 0x04000000,
537     JOY_CAL_READVONLY  = 0x08000000;
538 
539 enum JOYSTICKID1=0;
540 enum JOYSTICKID2=1;
541 
542 enum JOYCAPS_HASZ=1;
543 enum JOYCAPS_HASR=2;
544 enum JOYCAPS_HASU=4;
545 enum JOYCAPS_HASV=8;
546 enum JOYCAPS_HASPOV=16;
547 enum JOYCAPS_POV4DIR=32;
548 enum JOYCAPS_POVCTS=64;
549 
550 enum MMIOERR_BASE=256;
551 enum MMIOERR_FILENOTFOUND=(MMIOERR_BASE+1);
552 enum MMIOERR_OUTOFMEMORY=(MMIOERR_BASE+2);
553 enum MMIOERR_CANNOTOPEN=(MMIOERR_BASE+3);
554 enum MMIOERR_CANNOTCLOSE=(MMIOERR_BASE+4);
555 enum MMIOERR_CANNOTREAD=(MMIOERR_BASE+5);
556 enum MMIOERR_CANNOTWRITE=(MMIOERR_BASE+6);
557 enum MMIOERR_CANNOTSEEK=(MMIOERR_BASE+7);
558 enum MMIOERR_CANNOTEXPAND=(MMIOERR_BASE+8);
559 enum MMIOERR_CHUNKNOTFOUND=(MMIOERR_BASE+9);
560 enum MMIOERR_UNBUFFERED=(MMIOERR_BASE+10);
561 enum MMIOERR_PATHNOTFOUND=(MMIOERR_BASE+11);
562 enum MMIOERR_ACCESSDENIED=(MMIOERR_BASE+12);
563 enum MMIOERR_SHARINGVIOLATION=(MMIOERR_BASE+13);
564 enum MMIOERR_NETWORKERROR=(MMIOERR_BASE+14);
565 enum MMIOERR_TOOMANYOPENFILES=(MMIOERR_BASE+15);
566 enum MMIOERR_INVALIDFILE=(MMIOERR_BASE+16);
567 
568 enum CFSEPCHAR='+';
569 
570 enum MMIO_RWMODE=3;
571 enum MMIO_SHAREMODE=0x70;
572 enum MMIO_CREATE=0x1000;
573 enum MMIO_PARSE=256;
574 enum MMIO_DELETE=512;
575 enum MMIO_EXIST=0x4000;
576 enum MMIO_ALLOCBUF=0x10000;
577 enum MMIO_GETTEMP=0x20000;
578 enum MMIO_DIRTY=0x10000000;
579 enum MMIO_READ=0;
580 enum MMIO_WRITE=1;
581 enum MMIO_READWRITE=2;
582 enum MMIO_COMPAT=0;
583 enum MMIO_EXCLUSIVE=16;
584 enum MMIO_DENYWRITE=32;
585 enum MMIO_DENYREAD=0x30;
586 enum MMIO_DENYNONE=64;
587 enum MMIO_FHOPEN=16;
588 enum MMIO_EMPTYBUF=16;
589 enum MMIO_TOUPPER=16;
590 enum MMIO_INSTALLPROC=0x10000;
591 enum MMIO_GLOBALPROC=0x10000000;
592 enum MMIO_REMOVEPROC=0x20000;
593 enum MMIO_UNICODEPROC=0x1000000;
594 enum MMIO_FINDPROC=0x40000;
595 enum MMIO_FINDCHUNK=16;
596 enum MMIO_FINDRIFF=32;
597 enum MMIO_FINDLIST=64;
598 enum MMIO_CREATERIFF=32;
599 enum MMIO_CREATELIST=64;
600 enum MMIOM_READ=MMIO_READ;
601 enum MMIOM_WRITE=MMIO_WRITE;
602 enum MMIOM_SEEK=2;
603 enum MMIOM_OPEN=3;
604 enum MMIOM_CLOSE=4;
605 enum MMIOM_WRITEFLUSH=5;
606 enum MMIOM_RENAME=6;
607 enum MMIOM_USER=0x8000;
608 
609 enum FOURCC_RIFF = mmioFOURCC!('R', 'I', 'F', 'F');
610 enum FOURCC_LIST = mmioFOURCC!('L', 'I', 'S', 'T');
611 enum FOURCC_DOS  = mmioFOURCC!('D', 'O', 'S', ' ');
612 enum FOURCC_MEM  = mmioFOURCC!('M', 'E', 'M', ' ');
613 
614 enum MMIO_DEFAULTBUFFER=8192;
615 
616 enum {
617     MCIERR_INVALID_DEVICE_ID = MCIERR_BASE + 1,
618     MCIERR_UNRECOGNIZED_KEYWORD = MCIERR_BASE + 3,
619     MCIERR_UNRECOGNIZED_COMMAND = MCIERR_BASE + 5,
620     MCIERR_HARDWARE,
621     MCIERR_INVALID_DEVICE_NAME,
622     MCIERR_OUT_OF_MEMORY,
623     MCIERR_DEVICE_OPEN,
624     MCIERR_CANNOT_LOAD_DRIVER,
625     MCIERR_MISSING_COMMAND_STRING,
626     MCIERR_PARAM_OVERFLOW,
627     MCIERR_MISSING_STRING_ARGUMENT,
628     MCIERR_BAD_INTEGER,
629     MCIERR_PARSER_INTERNAL,
630     MCIERR_DRIVER_INTERNAL,
631     MCIERR_MISSING_PARAMETER,
632     MCIERR_UNSUPPORTED_FUNCTION,
633     MCIERR_FILE_NOT_FOUND,
634     MCIERR_DEVICE_NOT_READY,
635     MCIERR_INTERNAL,
636     MCIERR_DRIVER,
637     MCIERR_CANNOT_USE_ALL,
638     MCIERR_MULTIPLE,
639     MCIERR_EXTENSION_NOT_FOUND,
640     MCIERR_OUTOFRANGE, // = MCIERR_BASE+26
641     MCIERR_FLAGS_NOT_COMPATIBLE = MCIERR_BASE + 28,
642     MCIERR_FILE_NOT_SAVED = MCIERR_BASE + 30,
643     MCIERR_DEVICE_TYPE_REQUIRED,
644     MCIERR_DEVICE_LOCKED,
645     MCIERR_DUPLICATE_ALIAS,
646     MCIERR_BAD_CONSTANT,
647     MCIERR_MUST_USE_SHAREABLE,
648     MCIERR_MISSING_DEVICE_NAME,
649     MCIERR_BAD_TIME_FORMAT,
650     MCIERR_NO_CLOSING_QUOTE,
651     MCIERR_DUPLICATE_FLAGS,
652     MCIERR_INVALID_FILE,
653     MCIERR_NULL_PARAMETER_BLOCK,
654     MCIERR_UNNAMED_RESOURCE,
655     MCIERR_NEW_REQUIRES_ALIAS,
656     MCIERR_NOTIFY_ON_AUTO_OPEN,
657     MCIERR_NO_ELEMENT_ALLOWED,
658     MCIERR_NONAPPLICABLE_FUNCTION,
659     MCIERR_ILLEGAL_FOR_AUTO_OPEN,
660     MCIERR_FILENAME_REQUIRED,
661     MCIERR_EXTRA_CHARACTERS,
662     MCIERR_DEVICE_NOT_INSTALLED,
663     MCIERR_GET_CD,
664     MCIERR_SET_CD,
665     MCIERR_SET_DRIVE,
666     MCIERR_DEVICE_LENGTH,
667     MCIERR_DEVICE_ORD_LENGTH,
668     MCIERR_NO_INTEGER, // = MCIERR_BASE + 56
669     MCIERR_WAVE_OUTPUTSINUSE = MCIERR_BASE + 64,
670     MCIERR_WAVE_SETOUTPUTINUSE,
671     MCIERR_WAVE_INPUTSINUSE,
672     MCIERR_WAVE_SETINPUTINUSE,
673     MCIERR_WAVE_OUTPUTUNSPECIFIED,
674     MCIERR_WAVE_INPUTUNSPECIFIED,
675     MCIERR_WAVE_OUTPUTSUNSUITABLE,
676     MCIERR_WAVE_SETOUTPUTUNSUITABLE,
677     MCIERR_WAVE_INPUTSUNSUITABLE,
678     MCIERR_WAVE_SETINPUTUNSUITABLE, // = MCIERR_BASE + 73
679     MCIERR_SEQ_DIV_INCOMPATIBLE = MCIERR_BASE + 80,
680     MCIERR_SEQ_PORT_INUSE,
681     MCIERR_SEQ_PORT_NONEXISTENT,
682     MCIERR_SEQ_PORT_MAPNODEVICE,
683     MCIERR_SEQ_PORT_MISCERROR,
684     MCIERR_SEQ_TIMER,
685     MCIERR_SEQ_PORTUNSPECIFIED,
686     MCIERR_SEQ_NOMIDIPRESENT, // = MCIERR_BASE + 87
687     MCIERR_NO_WINDOW = MCIERR_BASE + 90,
688     MCIERR_CREATEWINDOW,
689     MCIERR_FILE_READ,
690     MCIERR_FILE_WRITE,
691     MCIERR_NO_IDENTITY // = MCIERR_BASE + 94
692 }
693 enum MCIERR_CUSTOM_DRIVER_BASE = MCIERR_BASE + 256;
694 
695 enum MCI_FIRST=DRV_MCI_FIRST;
696 enum MCI_OPEN=0x803;
697 enum MCI_CLOSE=0x804;
698 enum MCI_ESCAPE=0x805;
699 enum MCI_PLAY=0x806;
700 enum MCI_SEEK=0x807;
701 enum MCI_STOP=0x808;
702 enum MCI_PAUSE=0x809;
703 enum MCI_INFO=0x80A;
704 enum MCI_GETDEVCAPS=0x80B;
705 enum MCI_SPIN=0x80C;
706 enum MCI_SET=0x80D;
707 enum MCI_STEP=0x80E;
708 enum MCI_RECORD=0x80F;
709 enum MCI_SYSINFO=0x810;
710 enum MCI_BREAK=0x811;
711 enum MCI_SAVE=0x813;
712 enum MCI_STATUS=0x814;
713 enum MCI_CUE=0x830;
714 enum MCI_REALIZE=0x840;
715 enum MCI_WINDOW=0x841;
716 enum MCI_PUT=0x842;
717 enum MCI_WHERE=0x843;
718 enum MCI_FREEZE=0x844;
719 enum MCI_UNFREEZE=0x845;
720 enum MCI_LOAD=0x850;
721 enum MCI_CUT=0x851;
722 enum MCI_COPY=0x852;
723 enum MCI_PASTE=0x853;
724 enum MCI_UPDATE=0x854;
725 enum MCI_RESUME=0x855;
726 enum MCI_DELETE=0x856;
727 enum MCI_USER_MESSAGES=(DRV_MCI_FIRST+0x400);
728 enum MCI_LAST=0xFFF;
729 
730 enum MCIDEVICEID MCI_ALL_DEVICE_ID = -1;
731 
732 enum MCI_DEVTYPE_VCR=513;
733 enum MCI_DEVTYPE_VIDEODISC=514;
734 enum MCI_DEVTYPE_OVERLAY=515;
735 enum MCI_DEVTYPE_CD_AUDIO=516;
736 enum MCI_DEVTYPE_DAT=517;
737 enum MCI_DEVTYPE_SCANNER=518;
738 enum MCI_DEVTYPE_ANIMATION=519;
739 enum MCI_DEVTYPE_DIGITAL_VIDEO=520;
740 enum MCI_DEVTYPE_OTHER=521;
741 enum MCI_DEVTYPE_WAVEFORM_AUDIO=522;
742 enum MCI_DEVTYPE_SEQUENCER=523;
743 enum MCI_DEVTYPE_FIRST=MCI_DEVTYPE_VCR;
744 enum MCI_DEVTYPE_LAST=MCI_DEVTYPE_SEQUENCER;
745 enum MCI_DEVTYPE_FIRST_USER=0x1000;
746 enum MCI_MODE_NOT_READY=(MCI_STRING_OFFSET+12);
747 enum MCI_MODE_STOP=(MCI_STRING_OFFSET+13);
748 enum MCI_MODE_PLAY=(MCI_STRING_OFFSET+14);
749 enum MCI_MODE_RECORD=(MCI_STRING_OFFSET+15);
750 enum MCI_MODE_SEEK=(MCI_STRING_OFFSET+16);
751 enum MCI_MODE_PAUSE=(MCI_STRING_OFFSET+17);
752 enum MCI_MODE_OPEN=(MCI_STRING_OFFSET+18);
753 enum MCI_FORMAT_MILLISECONDS=0;
754 enum MCI_FORMAT_HMS=1;
755 enum MCI_FORMAT_MSF=2;
756 enum MCI_FORMAT_FRAMES=3;
757 enum MCI_FORMAT_SMPTE_24=4;
758 enum MCI_FORMAT_SMPTE_25=5;
759 enum MCI_FORMAT_SMPTE_30=6;
760 enum MCI_FORMAT_SMPTE_30DROP=7;
761 enum MCI_FORMAT_BYTES=8;
762 enum MCI_FORMAT_SAMPLES=9;
763 enum MCI_FORMAT_TMSF=10;
764 
765 
766 
767 
768 // Macros
769 BYTE MCI_HMS_HOUR(DWORD t) { return cast(BYTE)(t); }
770 BYTE MCI_HMS_MINUTE(DWORD t) { return cast(BYTE)(t>>>8); }
771 BYTE MCI_HMS_SECOND(DWORD t) { return cast(BYTE)( t>>>16); }
772 DWORD MCI_MAKE_HMS(BYTE h, BYTE m, BYTE s) { return h |(m<<8)|(cast(DWORD)(s)<<16); }
773 DWORD MCI_MAKE_MSF(BYTE m, BYTE s, BYTE f) { return m |(s<<8)|(cast(DWORD)(f)<<16); }
774 DWORD MCI_MAKE_TMSF(BYTE t, BYTE m, BYTE s, BYTE f) {
775  return t |(m<<8)|(s<<16)|(cast(DWORD)(f)<< 24); }
776 
777 BYTE MCI_MSF_MINUTE(DWORD t) { return cast(BYTE)(t); }
778 BYTE MCI_MSF_SECOND(DWORD t) { return cast(BYTE)(t >>> 8); }
779 BYTE MCI_MSF_FRAME(DWORD t)  {  return cast(BYTE)(t >>> 16); }
780 
781 BYTE MCI_TMSF_TRACK(DWORD t)  { return cast(BYTE)(t); }
782 BYTE MCI_TMSF_MINUTE(DWORD t) { return cast(BYTE)(t>>8); }
783 BYTE MCI_TMSF_SECOND(DWORD t) { return cast(BYTE)(t>>16); }
784 BYTE MCI_TMSF_FRAME(DWORD t)  { return cast(BYTE)(t>>24); }
785 
786 
787 enum MCI_NOTIFY_SUCCESSFUL=1;
788 enum MCI_NOTIFY_SUPERSEDED=2;
789 enum MCI_NOTIFY_ABORTED=4;
790 enum MCI_NOTIFY_FAILURE=8;
791 enum MCI_NOTIFY=1;
792 enum MCI_WAIT=2;
793 enum MCI_FROM=4;
794 enum MCI_TO=8;
795 enum MCI_TRACK=16;
796 enum MCI_OPEN_SHAREABLE=256;
797 enum MCI_OPEN_ELEMENT=512;
798 enum MCI_OPEN_ALIAS=1024;
799 enum MCI_OPEN_ELEMENT_ID=2048;
800 enum MCI_OPEN_TYPE_ID=0x1000;
801 enum MCI_OPEN_TYPE=0x2000;
802 enum MCI_SEEK_TO_START=256;
803 enum MCI_SEEK_TO_END=512;
804 enum MCI_STATUS_ITEM=256;
805 enum MCI_STATUS_START=512;
806 enum MCI_STATUS_LENGTH=1;
807 enum MCI_STATUS_POSITION=2;
808 enum MCI_STATUS_NUMBER_OF_TRACKS=3;
809 enum MCI_STATUS_MODE=4;
810 enum MCI_STATUS_MEDIA_PRESENT=5;
811 enum MCI_STATUS_TIME_FORMAT=6;
812 enum MCI_STATUS_READY=7;
813 enum MCI_STATUS_CURRENT_TRACK=8;
814 enum MCI_INFO_PRODUCT=256;
815 enum MCI_INFO_FILE=512;
816 enum MCI_INFO_MEDIA_UPC=1024;
817 enum MCI_INFO_MEDIA_IDENTITY=2048;
818 enum MCI_INFO_NAME=0x1000;
819 enum MCI_INFO_COPYRIGHT=0x2000;
820 
821 enum MCI_GETDEVCAPS_ITEM=256;
822 enum MCI_GETDEVCAPS_CAN_RECORD=1;
823 enum MCI_GETDEVCAPS_HAS_AUDIO=2;
824 enum MCI_GETDEVCAPS_HAS_VIDEO=3;
825 enum MCI_GETDEVCAPS_DEVICE_TYPE=4;
826 enum MCI_GETDEVCAPS_USES_FILES=5;
827 enum MCI_GETDEVCAPS_COMPOUND_DEVICE=6;
828 enum MCI_GETDEVCAPS_CAN_EJECT=7;
829 enum MCI_GETDEVCAPS_CAN_PLAY=8;
830 enum MCI_GETDEVCAPS_CAN_SAVE=9;
831 
832 enum MCI_SYSINFO_QUANTITY=256;
833 enum MCI_SYSINFO_OPEN=512;
834 enum MCI_SYSINFO_NAME=1024;
835 enum MCI_SYSINFO_INSTALLNAME=2048;
836 enum MCI_SET_DOOR_OPEN=256;
837 enum MCI_SET_DOOR_CLOSED=512;
838 enum MCI_SET_TIME_FORMAT=1024;
839 enum MCI_SET_AUDIO=2048;
840 enum MCI_SET_VIDEO=0x1000;
841 enum MCI_SET_ON=0x2000;
842 enum MCI_SET_OFF=0x4000;
843 
844 enum MCI_SET_AUDIO_ALL=0;
845 enum MCI_SET_AUDIO_LEFT=1;
846 enum MCI_SET_AUDIO_RIGHT=2;
847 
848 enum MCI_BREAK_KEY=256;
849 enum MCI_BREAK_HWND=512;
850 enum MCI_BREAK_OFF=1024;
851 
852 enum MCI_RECORD_INSERT=256;
853 enum MCI_RECORD_OVERWRITE=512;
854 enum MCI_SAVE_FILE=256;
855 enum MCI_LOAD_FILE=256;
856 
857 enum MCI_VD_MODE_PARK=(MCI_VD_OFFSET+1);
858 enum MCI_VD_MEDIA_CLV=(MCI_VD_OFFSET+2);
859 enum MCI_VD_MEDIA_CAV=(MCI_VD_OFFSET+3);
860 enum MCI_VD_MEDIA_OTHER=(MCI_VD_OFFSET+4);
861 
862 enum MCI_VD_FORMAT_TRACK=0x4001;
863 enum MCI_VD_PLAY_REVERSE=0x10000;
864 enum MCI_VD_PLAY_FAST=0x20000;
865 enum MCI_VD_PLAY_SPEED=0x40000;
866 enum MCI_VD_PLAY_SCAN=0x80000;
867 enum MCI_VD_PLAY_SLOW=0x100000;
868 enum MCI_VD_SEEK_REVERSE=0x10000;
869 enum MCI_VD_STATUS_SPEED=0x4002;
870 enum MCI_VD_STATUS_FORWARD=0x4003;
871 enum MCI_VD_STATUS_MEDIA_TYPE=0x4004;
872 enum MCI_VD_STATUS_SIDE=0x4005;
873 enum MCI_VD_STATUS_DISC_SIZE=0x4006;
874 enum MCI_VD_GETDEVCAPS_CLV=0x10000;
875 enum MCI_VD_GETDEVCAPS_CAV=0x20000;
876 enum MCI_VD_SPIN_UP=0x10000;
877 enum MCI_VD_SPIN_DOWN=0x20000;
878 enum MCI_VD_GETDEVCAPS_CAN_REVERSE=0x4002;
879 enum MCI_VD_GETDEVCAPS_FAST_RATE=0x4003;
880 enum MCI_VD_GETDEVCAPS_SLOW_RATE=0x4004;
881 enum MCI_VD_GETDEVCAPS_NORMAL_RATE=0x4005;
882 enum MCI_VD_STEP_FRAMES=0x10000;
883 enum MCI_VD_STEP_REVERSE=0x20000;
884 enum MCI_VD_ESCAPE_STRING=256;
885 
886 enum MCI_CDA_STATUS_TYPE_TRACK=0x4001;
887 enum MCI_CDA_TRACK_AUDIO=MCI_CD_OFFSET;
888 enum MCI_CDA_TRACK_OTHER=(MCI_CD_OFFSET+1);
889 
890 enum MCI_WAVE_PCM=MCI_WAVE_OFFSET;
891 enum MCI_WAVE_MAPPER=(MCI_WAVE_OFFSET+1);
892 enum MCI_WAVE_OPEN_BUFFER=0x10000;
893 enum MCI_WAVE_SET_FORMATTAG=0x10000;
894 enum MCI_WAVE_SET_CHANNELS=0x20000;
895 enum MCI_WAVE_SET_SAMPLESPERSEC=0x40000;
896 enum MCI_WAVE_SET_AVGBYTESPERSEC=0x80000;
897 enum MCI_WAVE_SET_BLOCKALIGN=0x100000;
898 enum MCI_WAVE_SET_BITSPERSAMPLE=0x200000;
899 enum MCI_WAVE_INPUT=0x400000;
900 enum MCI_WAVE_OUTPUT=0x800000;
901 enum MCI_WAVE_STATUS_FORMATTAG=0x4001;
902 enum MCI_WAVE_STATUS_CHANNELS=0x4002;
903 enum MCI_WAVE_STATUS_SAMPLESPERSEC=0x4003;
904 enum MCI_WAVE_STATUS_AVGBYTESPERSEC=0x4004;
905 enum MCI_WAVE_STATUS_BLOCKALIGN=0x4005;
906 enum MCI_WAVE_STATUS_BITSPERSAMPLE=0x4006;
907 enum MCI_WAVE_STATUS_LEVEL=0x4007;
908 enum MCI_WAVE_SET_ANYINPUT=0x4000000;
909 enum MCI_WAVE_SET_ANYOUTPUT=0x8000000;
910 enum MCI_WAVE_GETDEVCAPS_INPUTS=0x4001;
911 enum MCI_WAVE_GETDEVCAPS_OUTPUTS=0x4002;
912 
913 enum MCI_SEQ_DIV_PPQN=MCI_SEQ_OFFSET;
914 enum MCI_SEQ_DIV_SMPTE_24=(MCI_SEQ_OFFSET+1);
915 enum MCI_SEQ_DIV_SMPTE_25=(MCI_SEQ_OFFSET+2);
916 enum MCI_SEQ_DIV_SMPTE_30DROP=(MCI_SEQ_OFFSET+3);
917 enum MCI_SEQ_DIV_SMPTE_30=(MCI_SEQ_OFFSET+4);
918 enum MCI_SEQ_FORMAT_SONGPTR=0x4001;
919 enum MCI_SEQ_FILE=0x4002;
920 enum MCI_SEQ_MIDI=0x4003;
921 enum MCI_SEQ_SMPTE=0x4004;
922 enum MCI_SEQ_NONE=65533;
923 enum MCI_SEQ_MAPPER=65535;
924 
925 enum MCI_SEQ_STATUS_TEMPO=0x4002;
926 enum MCI_SEQ_STATUS_PORT=0x4003;
927 enum MCI_SEQ_STATUS_SLAVE=0x4007;
928 enum MCI_SEQ_STATUS_MASTER=0x4008;
929 enum MCI_SEQ_STATUS_OFFSET=0x4009;
930 enum MCI_SEQ_STATUS_DIVTYPE=0x400A;
931 enum MCI_SEQ_STATUS_NAME=0x400B;
932 enum MCI_SEQ_STATUS_COPYRIGHT=0x400C;
933 
934 enum MCI_SEQ_SET_TEMPO=0x10000;
935 enum MCI_SEQ_SET_PORT=0x20000;
936 enum MCI_SEQ_SET_SLAVE=0x40000;
937 enum MCI_SEQ_SET_MASTER=0x80000;
938 enum MCI_SEQ_SET_OFFSET=0x1000000;
939 
940 enum MCI_ANIM_OPEN_WS=0x10000;
941 enum MCI_ANIM_OPEN_PARENT=0x20000;
942 enum MCI_ANIM_OPEN_NOSTATIC=0x40000;
943 enum MCI_ANIM_PLAY_SPEED=0x10000;
944 enum MCI_ANIM_PLAY_REVERSE=0x20000;
945 enum MCI_ANIM_PLAY_FAST=0x40000;
946 enum MCI_ANIM_PLAY_SLOW=0x80000;
947 enum MCI_ANIM_PLAY_SCAN=0x100000;
948 enum MCI_ANIM_STEP_REVERSE=0x10000;
949 enum MCI_ANIM_STEP_FRAMES=0x20000;
950 enum MCI_ANIM_STATUS_SPEED=0x4001;
951 enum MCI_ANIM_STATUS_FORWARD=0x4002;
952 enum MCI_ANIM_STATUS_HWND=0x4003;
953 enum MCI_ANIM_STATUS_HPAL=0x4004;
954 enum MCI_ANIM_STATUS_STRETCH=0x4005;
955 enum MCI_ANIM_INFO_TEXT=0x10000;
956 
957 enum MCI_ANIM_GETDEVCAPS_CAN_REVERSE=0x4001;
958 enum MCI_ANIM_GETDEVCAPS_FAST_RATE=0x4002;
959 enum MCI_ANIM_GETDEVCAPS_SLOW_RATE=0x4003;
960 enum MCI_ANIM_GETDEVCAPS_NORMAL_RATE=0x4004;
961 enum MCI_ANIM_GETDEVCAPS_PALETTES=0x4006;
962 enum MCI_ANIM_GETDEVCAPS_CAN_STRETCH=0x4007;
963 enum MCI_ANIM_GETDEVCAPS_MAX_WINDOWS=0x4008;
964 
965 enum MCI_ANIM_REALIZE_NORM=0x10000;
966 enum MCI_ANIM_REALIZE_BKGD=0x20000;
967 
968 enum MCI_ANIM_WINDOW_HWND=0x10000;
969 enum MCI_ANIM_WINDOW_STATE=0x40000;
970 enum MCI_ANIM_WINDOW_TEXT=0x80000;
971 enum MCI_ANIM_WINDOW_ENABLE_STRETCH=0x100000;
972 enum MCI_ANIM_WINDOW_DISABLE_STRETCH=0x200000;
973 enum MCI_ANIM_WINDOW_DEFAULT=0x0;
974 
975 enum MCI_ANIM_RECT=0x10000;
976 enum MCI_ANIM_PUT_SOURCE=0x20000;
977 enum MCI_ANIM_PUT_DESTINATION=0x40000;
978 enum MCI_ANIM_WHERE_SOURCE=0x20000;
979 enum MCI_ANIM_WHERE_DESTINATION=0x40000;
980 enum MCI_ANIM_UPDATE_HDC=0x20000;
981 
982 enum MCI_OVLY_OPEN_WS=0x10000;
983 enum MCI_OVLY_OPEN_PARENT=0x20000;
984 enum MCI_OVLY_STATUS_HWND=0x4001;
985 enum MCI_OVLY_STATUS_STRETCH=0x4002;
986 enum MCI_OVLY_INFO_TEXT=0x10000;
987 enum MCI_OVLY_GETDEVCAPS_CAN_STRETCH=0x4001;
988 enum MCI_OVLY_GETDEVCAPS_CAN_FREEZE=0x4002;
989 enum MCI_OVLY_GETDEVCAPS_MAX_WINDOWS=0x4003;
990 enum MCI_OVLY_WINDOW_HWND=0x10000;
991 enum MCI_OVLY_WINDOW_STATE=0x40000;
992 enum MCI_OVLY_WINDOW_TEXT=0x80000;
993 enum MCI_OVLY_WINDOW_ENABLE_STRETCH=0x100000;
994 enum MCI_OVLY_WINDOW_DISABLE_STRETCH=0x200000;
995 enum MCI_OVLY_WINDOW_DEFAULT=0x0;
996 enum MCI_OVLY_RECT=0x10000;
997 enum MCI_OVLY_PUT_SOURCE=0x20000;
998 enum MCI_OVLY_PUT_DESTINATION=0x40000;
999 enum MCI_OVLY_PUT_FRAME=0x80000;
1000 enum MCI_OVLY_PUT_VIDEO=0x100000;
1001 enum MCI_OVLY_WHERE_SOURCE=0x20000;
1002 enum MCI_OVLY_WHERE_DESTINATION=0x40000;
1003 enum MCI_OVLY_WHERE_FRAME=0x80000;
1004 enum MCI_OVLY_WHERE_VIDEO=0x100000;
1005 
1006 enum NEWTRANSPARENT=3;
1007 enum QUERYROPSUPPORT=40;
1008 enum SELECTDIB=41;
1009 
1010 LONG DIBINDEX(WORD n) {
1011     return MAKELONG(n, 0x10FF);
1012 }
1013 enum CAPS1=94;
1014 enum C1_TRANSPARENT=1;
1015 
1016 //const SEEK_SET=0;
1017 //const SEEK_CUR=1;
1018 //const SEEK_END=2;
1019 public import core.stdc.stdio : SEEK_SET, SEEK_CUR, SEEK_END;
1020 
1021 alias DWORD MCIERROR;
1022 alias UINT MCIDEVICEID;
1023 extern(Windows) alias UINT function (MCIDEVICEID, DWORD) YIELDPROC;
1024 alias UINT MMVERSION;
1025 alias UINT MMRESULT;
1026 
1027 struct MMTIME {
1028     UINT wType;
1029     union {
1030         DWORD ms;
1031         DWORD sample;
1032         DWORD cb;
1033         DWORD ticks;
1034         struct _smpte {
1035             BYTE hour;
1036             BYTE min;
1037             BYTE sec;
1038             BYTE frame;
1039             BYTE fps;
1040             BYTE dummy;
1041             BYTE[2] pad;
1042         }
1043         _smpte smpte;
1044         struct _midi {
1045             DWORD songptrpos;
1046         }
1047         _midi midi;
1048     }
1049 }
1050 alias MMTIME* PMMTIME, LPMMTIME;
1051 
1052 alias HANDLE HDRVR;
1053 
1054 struct DRVCONFIGINFO {
1055 align(1):
1056     DWORD dwDCISize;
1057     LPCWSTR lpszDCISectionName;
1058     LPCWSTR lpszDCIAliasName;
1059 }
1060 alias DRVCONFIGINFO * PDRVCONFIGINFO, LPDRVCONFIGINFO;
1061 
1062 struct DRVCONFIGINFOEX {
1063 align(1):
1064     DWORD dwDCISize;
1065     LPCWSTR lpszDCISectionName;
1066     LPCWSTR lpszDCIAliasName;
1067     DWORD dnDevNode;
1068 }
1069 alias DRVCONFIGINFOEX* PDRVCONFIGINFOEX, LPDRVCONFIGINFOEX;
1070 
1071 extern(Windows):
1072 
1073 /+FIXME: I couldn't find these in MSDN.
1074 alias void function (HDRVR, UINT, DWORD_PTR, DWORD_PTR, DWORD_PTR) DRVCALLBACK;
1075 LRESULT DRIVERPROC (DWORD_PTR, HDRVR, UINT, LPARAM, LPARAM);
1076 alias DRVCALLBACK* LPDRVCALLBACK, PDRVCALLBACK;
1077 
1078 alias DRVCALLBACK WAVECALLBACK;
1079 alias WAVECALLBACK* LPWAVECALLBACK;
1080 
1081 alias DRVCALLBACK MIDICALLBACK;
1082 alias MIDICALLBACK* LPMIDICALLBACK;
1083 
1084 +/
1085 
1086 alias HANDLE HWAVE;
1087 alias HANDLE HWAVEIN;
1088 alias HANDLE HWAVEOUT;
1089 
1090 alias HWAVEIN* LPHWAVEIN;
1091 alias HWAVEOUT* LPHWAVEOUT;
1092 
1093 struct WAVEHDR {
1094     LPSTR lpData;
1095     DWORD dwBufferLength;
1096     DWORD dwBytesRecorded;
1097     DWORD_PTR dwUser;
1098     DWORD dwFlags;
1099     DWORD dwLoops;
1100     WAVEHDR *lpNext;
1101     DWORD_PTR reserved;
1102 }
1103 alias WAVEHDR* PWAVEHDR, LPWAVEHDR;
1104 
1105 struct WAVEOUTCAPSA {
1106     WORD wMid;
1107     WORD wPid;
1108     MMVERSION vDriverVersion;
1109     CHAR[MAXPNAMELEN] szPname = 0;
1110     DWORD dwFormats;
1111     WORD wChannels;
1112     WORD wReserved1;
1113     DWORD dwSupport;
1114 }
1115 alias WAVEOUTCAPSA* PWAVEOUTCAPSA, LPWAVEOUTCAPSA;
1116 
1117 struct WAVEOUTCAPSW {
1118     WORD wMid;
1119     WORD wPid;
1120     MMVERSION vDriverVersion;
1121     WCHAR[MAXPNAMELEN] szPname = 0;
1122     DWORD dwFormats;
1123     WORD wChannels;
1124     WORD wReserved1;
1125     DWORD dwSupport;
1126 }
1127 alias WAVEOUTCAPSW* PWAVEOUTCAPSW, LPWAVEOUTCAPSW;
1128 
1129 struct WAVEINCAPSA {
1130     WORD wMid;
1131     WORD wPid;
1132     MMVERSION vDriverVersion;
1133     CHAR[MAXPNAMELEN] szPname = 0;
1134     DWORD dwFormats;
1135     WORD wChannels;
1136     WORD wReserved1;
1137 }
1138 alias WAVEINCAPSA* PWAVEINCAPSA, LPWAVEINCAPSA;
1139 
1140 struct WAVEINCAPSW {
1141     WORD wMid;
1142     WORD wPid;
1143     MMVERSION vDriverVersion;
1144     WCHAR[MAXPNAMELEN] szPname = 0;
1145     DWORD dwFormats;
1146     WORD wChannels;
1147     WORD wReserved1;
1148 }
1149 alias WAVEINCAPSW* PWAVEINCAPSW, LPWAVEINCAPSW;
1150 
1151 struct WAVEFORMAT {
1152     WORD wFormatTag;
1153     WORD nChannels;
1154     DWORD nSamplesPerSec;
1155     DWORD nAvgBytesPerSec;
1156     WORD nBlockAlign;
1157 }
1158 alias WAVEFORMAT* PWAVEFORMAT, LPWAVEFORMAT;
1159 
1160 struct PCMWAVEFORMAT {
1161     WAVEFORMAT wf;
1162     WORD wBitsPerSample;
1163 }
1164 alias PCMWAVEFORMAT* PPCMWAVEFORMAT, LPPCMWAVEFORMAT;
1165 
1166 struct WAVEFORMATEX {
1167     WORD wFormatTag;
1168     WORD nChannels;
1169     DWORD nSamplesPerSec;
1170     DWORD nAvgBytesPerSec;
1171     WORD nBlockAlign;
1172     WORD wBitsPerSample;
1173     WORD cbSize;
1174 }
1175 alias WAVEFORMATEX* PWAVEFORMATEX, LPWAVEFORMATEX;
1176 alias const(WAVEFORMATEX)* LPCWAVEFORMATEX;
1177 
1178 alias HANDLE HMIDI;
1179 alias HANDLE HMIDIIN;
1180 alias HANDLE HMIDIOUT;
1181 alias HANDLE HMIDISTRM;
1182 
1183 alias HMIDI* LPHMIDI;
1184 alias HMIDIIN* LPHMIDIIN;
1185 alias HMIDIOUT* LPHMIDIOUT;
1186 alias HMIDISTRM* LPHMIDISTRM;
1187 
1188 alias WORD[MIDIPATCHSIZE] PATCHARRAY;
1189 alias WORD* LPPATCHARRAY;
1190 alias WORD[MIDIPATCHSIZE] KEYARRAY;
1191 alias WORD* LPKEYARRAY;
1192 
1193 struct MIDIOUTCAPSA {
1194     WORD wMid;
1195     WORD wPid;
1196     MMVERSION vDriverVersion;
1197     CHAR[MAXPNAMELEN] szPname = 0;
1198     WORD wTechnology;
1199     WORD wVoices;
1200     WORD wNotes;
1201     WORD wChannelMask;
1202     DWORD dwSupport;
1203 }
1204 alias MIDIOUTCAPSA* PMIDIOUTCAPSA, LPMIDIOUTCAPSA;
1205 
1206 struct MIDIOUTCAPSW {
1207     WORD wMid;
1208     WORD wPid;
1209     MMVERSION vDriverVersion;
1210     WCHAR[MAXPNAMELEN] szPname = 0;
1211     WORD wTechnology;
1212     WORD wVoices;
1213     WORD wNotes;
1214     WORD wChannelMask;
1215     DWORD dwSupport;
1216 }
1217 alias MIDIOUTCAPSW* PMIDIOUTCAPSW, LPMIDIOUTCAPSW;
1218 
1219 struct MIDIINCAPSA {
1220     WORD wMid;
1221     WORD wPid;
1222     MMVERSION vDriverVersion;
1223     CHAR[MAXPNAMELEN] szPname = 0;
1224     DWORD dwSupport;
1225 }
1226 alias MIDIINCAPSA* PMIDIINCAPSA, LPMIDIINCAPSA;
1227 
1228 struct MIDIINCAPSW {
1229     WORD wMid;
1230     WORD wPid;
1231     MMVERSION vDriverVersion;
1232     WCHAR[MAXPNAMELEN] szPname = 0;
1233     DWORD dwSupport;
1234 }
1235 alias MIDIINCAPSW* PMIDIINCAPSW, LPMIDIINCAPSW;
1236 
1237 struct MIDIHDR {
1238 align(1):
1239     LPSTR lpData;
1240     DWORD dwBufferLength;
1241     DWORD dwBytesRecorded;
1242     DWORD_PTR dwUser;
1243     DWORD dwFlags;
1244     MIDIHDR *lpNext;
1245     DWORD_PTR reserved;
1246     DWORD dwOffset;
1247     DWORD_PTR[8] dwReserved;
1248 }
1249 alias MIDIHDR* PMIDIHDR, LPMIDIHDR;
1250 
1251 struct MIDIEVENT {
1252     DWORD dwDeltaTime;
1253     DWORD dwStreamID;
1254     DWORD dwEvent;
1255     DWORD[1] dwParms;
1256 }
1257 
1258 struct MIDISTRMBUFFVER {
1259     DWORD dwVersion;
1260     DWORD dwMid;
1261     DWORD dwOEMVersion;
1262 }
1263 
1264 struct MIDIPROPTIMEDIV {
1265     DWORD cbStruct;
1266     DWORD dwTimeDiv;
1267 }
1268 alias MIDIPROPTIMEDIV* LPMIDIPROPTIMEDIV;
1269 
1270 struct MIDIPROPTEMPO {
1271     DWORD cbStruct;
1272     DWORD dwTempo;
1273 }
1274 alias MIDIPROPTEMPO* LPMIDIPROPTEMPO;
1275 
1276 struct AUXCAPSA {
1277     WORD wMid;
1278     WORD wPid;
1279     MMVERSION vDriverVersion;
1280     CHAR[MAXPNAMELEN] szPname = 0;
1281     WORD wTechnology;
1282     WORD wReserved1;
1283     DWORD dwSupport;
1284 }
1285 alias AUXCAPSA* PAUXCAPSA, LPAUXCAPSA;
1286 
1287 struct AUXCAPSW {
1288     WORD wMid;
1289     WORD wPid;
1290     MMVERSION vDriverVersion;
1291     WCHAR[MAXPNAMELEN] szPname = 0;
1292     WORD wTechnology;
1293     WORD wReserved1;
1294     DWORD dwSupport;
1295 }
1296 alias AUXCAPSW* PAUXCAPSW, LPAUXCAPSW;
1297 
1298 alias HANDLE HMIXEROBJ;
1299 alias HMIXEROBJ* LPHMIXEROBJ;
1300 
1301 alias HANDLE HMIXER;
1302 alias HMIXER* LPHMIXER;
1303 
1304 struct MIXERCAPSA {
1305     WORD wMid;
1306     WORD wPid;
1307     MMVERSION vDriverVersion;
1308     CHAR[MAXPNAMELEN] szPname = 0;
1309     DWORD fdwSupport;
1310     DWORD cDestinations;
1311 }
1312 alias MIXERCAPSA* PMIXERCAPSA, LPMIXERCAPSA;
1313 
1314 struct MIXERCAPSW {
1315     WORD wMid;
1316     WORD wPid;
1317     MMVERSION vDriverVersion;
1318     WCHAR[MAXPNAMELEN] szPname = 0;
1319     DWORD fdwSupport;
1320     DWORD cDestinations;
1321 }
1322 alias MIXERCAPSW* PMIXERCAPSW, LPMIXERCAPSW;
1323 
1324 struct MIXERLINEA {
1325 align(1):
1326     DWORD cbStruct;
1327     DWORD dwDestination;
1328     DWORD dwSource;
1329     DWORD dwLineID;
1330     DWORD fdwLine;
1331     DWORD_PTR dwUser;
1332     DWORD dwComponentType;
1333     DWORD cChannels;
1334     DWORD cConnections;
1335     DWORD cControls;
1336     CHAR[MIXER_SHORT_NAME_CHARS] szShortName = 0;
1337     CHAR[MIXER_LONG_NAME_CHARS] szName = 0;
1338     struct _Target {
1339         DWORD dwType;
1340         DWORD dwDeviceID;
1341         WORD wMid;
1342         WORD wPid;
1343         MMVERSION vDriverVersion;
1344         CHAR[MAXPNAMELEN] szPname = 0;
1345     }
1346     _Target Target;
1347 }
1348 alias MIXERLINEA* PMIXERLINEA, LPMIXERLINEA;
1349 
1350 struct MIXERLINEW {
1351 align(1):
1352     DWORD cbStruct;
1353     DWORD dwDestination;
1354     DWORD dwSource;
1355     DWORD dwLineID;
1356     DWORD fdwLine;
1357     DWORD_PTR dwUser;
1358     DWORD dwComponentType;
1359     DWORD cChannels;
1360     DWORD cConnections;
1361     DWORD cControls;
1362     WCHAR[MIXER_SHORT_NAME_CHARS] szShortName = 0;
1363     WCHAR[MIXER_LONG_NAME_CHARS] szName = 0;
1364     struct _Target {
1365         DWORD dwType;
1366         DWORD dwDeviceID;
1367         WORD wMid;
1368         WORD wPid;
1369         MMVERSION vDriverVersion;
1370         WCHAR[MAXPNAMELEN] szPname = 0;
1371     }
1372     _Target Target;
1373 }
1374 alias MIXERLINEW* PMIXERLINEW, LPMIXERLINEW;
1375 
1376 struct MIXERCONTROLA {
1377     DWORD cbStruct;
1378     DWORD dwControlID;
1379     DWORD dwControlType;
1380     DWORD fdwControl;
1381     DWORD cMultipleItems;
1382     CHAR[MIXER_SHORT_NAME_CHARS] szShortName = 0;
1383     CHAR[MIXER_LONG_NAME_CHARS] szName = 0;
1384     union _Bounds {
1385         struct {
1386             LONG lMinimum;
1387             LONG lMaximum;
1388         }
1389         struct {
1390             DWORD dwMinimum;
1391             DWORD dwMaximum;
1392         }
1393         DWORD[6] dwReserved;
1394     }
1395     _Bounds Bounds;
1396     union _Metrics {
1397         DWORD cSteps;
1398         DWORD cbCustomData;
1399         DWORD[6] dwReserved;
1400     }
1401     _Metrics Metrics;
1402 }
1403 alias MIXERCONTROLA* PMIXERCONTROLA, LPMIXERCONTROLA;
1404 
1405 struct MIXERCONTROLW {
1406     DWORD cbStruct;
1407     DWORD dwControlID;
1408     DWORD dwControlType;
1409     DWORD fdwControl;
1410     DWORD cMultipleItems;
1411     WCHAR[MIXER_SHORT_NAME_CHARS] szShortName = 0;
1412     WCHAR[MIXER_LONG_NAME_CHARS] szName = 0;
1413     union _Bounds {
1414         struct {
1415             LONG lMinimum;
1416             LONG lMaximum;
1417         }
1418         struct {
1419             DWORD dwMinimum;
1420             DWORD dwMaximum;
1421         }
1422         DWORD[6] dwReserved;
1423     }
1424     _Bounds Bounds;
1425     union _Metrics {
1426         DWORD cSteps;
1427         DWORD cbCustomData;
1428         DWORD[6] dwReserved;
1429     }
1430     _Metrics Metrics;
1431 }
1432 
1433 alias MIXERCONTROLW* PMIXERCONTROLW, LPMIXERCONTROLW;
1434 
1435 struct MIXERLINECONTROLSA {
1436 align(1):
1437     DWORD cbStruct;
1438     DWORD dwLineID;
1439     union {
1440         DWORD dwControlID;
1441         DWORD dwControlType;
1442     }
1443     DWORD cControls;
1444     DWORD cbmxctrl;
1445     LPMIXERCONTROLA pamxctrl;
1446 }
1447 alias MIXERLINECONTROLSA* PMIXERLINECONTROLSA, LPMIXERLINECONTROLSA;
1448 
1449 struct MIXERLINECONTROLSW {
1450 align(1):
1451     DWORD cbStruct;
1452     DWORD dwLineID;
1453     union {
1454         DWORD dwControlID;
1455         DWORD dwControlType;
1456     }
1457     DWORD cControls;
1458     DWORD cbmxctrl;
1459     LPMIXERCONTROLW pamxctrl;
1460 }
1461 alias MIXERLINECONTROLSW* PMIXERLINECONTROLSW, LPMIXERLINECONTROLSW;
1462 
1463 struct MIXERCONTROLDETAILS {
1464 align(1):
1465     DWORD cbStruct;
1466     DWORD dwControlID;
1467     DWORD cChannels;
1468     union {
1469         HWND hwndOwner;
1470         DWORD cMultipleItems;
1471     }
1472     DWORD cbDetails;
1473     PVOID paDetails;
1474 }
1475 alias MIXERCONTROLDETAILS* PMIXERCONTROLDETAILS, LPMIXERCONTROLDETAILS;
1476 
1477 struct MIXERCONTROLDETAILS_LISTTEXTA {
1478     DWORD dwParam1;
1479     DWORD dwParam2;
1480     CHAR[MIXER_LONG_NAME_CHARS] szName = 0;
1481 }
1482 alias MIXERCONTROLDETAILS_LISTTEXTA* PMIXERCONTROLDETAILS_LISTTEXTA, LPMIXERCONTROLDETAILS_LISTTEXTA;
1483 
1484 struct MIXERCONTROLDETAILS_LISTTEXTW {
1485     DWORD dwParam1;
1486     DWORD dwParam2;
1487     WCHAR[MIXER_LONG_NAME_CHARS] szName = 0;
1488 }
1489 alias MIXERCONTROLDETAILS_LISTTEXTW* PMIXERCONTROLDETAILS_LISTTEXTW, LPMIXERCONTROLDETAILS_LISTTEXTW;
1490 
1491 struct MIXERCONTROLDETAILS_BOOLEAN {
1492     LONG fValue;
1493 }
1494 alias MIXERCONTROLDETAILS_BOOLEAN* PMIXERCONTROLDETAILS_BOOLEAN, LPMIXERCONTROLDETAILS_BOOLEAN;
1495 
1496 struct MIXERCONTROLDETAILS_SIGNED {
1497     LONG lValue;
1498 }
1499 alias MIXERCONTROLDETAILS_SIGNED* PMIXERCONTROLDETAILS_SIGNED, LPMIXERCONTROLDETAILS_SIGNED;
1500 
1501 struct MIXERCONTROLDETAILS_UNSIGNED {
1502     DWORD dwValue;
1503 }
1504 alias MIXERCONTROLDETAILS_UNSIGNED* PMIXERCONTROLDETAILS_UNSIGNED, LPMIXERCONTROLDETAILS_UNSIGNED;
1505 
1506 alias void function (UINT, UINT, DWORD_PTR, DWORD_PTR, DWORD_PTR) LPTIMECALLBACK;
1507 
1508 struct TIMECAPS {
1509     UINT wPeriodMin;
1510     UINT wPeriodMax;
1511 }
1512 alias TIMECAPS* PTIMECAPS, LPTIMECAPS;
1513 
1514 struct JOYCAPSA {
1515     WORD wMid;
1516     WORD wPid;
1517     CHAR[MAXPNAMELEN] szPname = 0;
1518     UINT wXmin;
1519     UINT wXmax;
1520     UINT wYmin;
1521     UINT wYmax;
1522     UINT wZmin;
1523     UINT wZmax;
1524     UINT wNumButtons;
1525     UINT wPeriodMin;
1526     UINT wPeriodMax;
1527     UINT wRmin;
1528     UINT wRmax;
1529     UINT wUmin;
1530     UINT wUmax;
1531     UINT wVmin;
1532     UINT wVmax;
1533     UINT wCaps;
1534     UINT wMaxAxes;
1535     UINT wNumAxes;
1536     UINT wMaxButtons;
1537     CHAR[MAXPNAMELEN] szRegKey = 0;
1538     CHAR[MAX_JOYSTICKOEMVXDNAME] szOEMVxD = 0;
1539 }
1540 alias JOYCAPSA* PJOYCAPSA, LPJOYCAPSA;
1541 
1542 struct JOYCAPSW {
1543     WORD wMid;
1544     WORD wPid;
1545     WCHAR[MAXPNAMELEN] szPname = 0;
1546     UINT wXmin;
1547     UINT wXmax;
1548     UINT wYmin;
1549     UINT wYmax;
1550     UINT wZmin;
1551     UINT wZmax;
1552     UINT wNumButtons;
1553     UINT wPeriodMin;
1554     UINT wPeriodMax;
1555     UINT wRmin;
1556     UINT wRmax;
1557     UINT wUmin;
1558     UINT wUmax;
1559     UINT wVmin;
1560     UINT wVmax;
1561     UINT wCaps;
1562     UINT wMaxAxes;
1563     UINT wNumAxes;
1564     UINT wMaxButtons;
1565     WCHAR[MAXPNAMELEN] szRegKey = 0;
1566     WCHAR[MAX_JOYSTICKOEMVXDNAME] szOEMVxD = 0;
1567 }
1568 alias JOYCAPSW* PJOYCAPSW, LPJOYCAPSW;
1569 
1570 struct JOYINFO {
1571     UINT wXpos;
1572     UINT wYpos;
1573     UINT wZpos;
1574     UINT wButtons;
1575 }
1576 alias JOYINFO* PJOYINFO, LPJOYINFO;
1577 
1578 struct JOYINFOEX {
1579     DWORD dwSize;
1580     DWORD dwFlags;
1581     DWORD dwXpos;
1582     DWORD dwYpos;
1583     DWORD dwZpos;
1584     DWORD dwRpos;
1585     DWORD dwUpos;
1586     DWORD dwVpos;
1587     DWORD dwButtons;
1588     DWORD dwButtonNumber;
1589     DWORD dwPOV;
1590     DWORD dwReserved1;
1591     DWORD dwReserved2;
1592 }
1593 alias JOYINFOEX* PJOYINFOEX, LPJOYINFOEX;
1594 
1595 alias DWORD FOURCC;
1596 alias char* HPSTR;
1597 
1598 alias HANDLE HMMIO;
1599 
1600 alias LRESULT function (LPSTR, UINT, LPARAM, LPARAM) LPMMIOPROC;
1601 
1602 struct MMIOINFO {
1603 align(1):
1604     DWORD dwFlags;
1605     FOURCC fccIOProc;
1606     LPMMIOPROC pIOProc;
1607     UINT wErrorRet;
1608     HTASK htask;
1609     LONG cchBuffer;
1610     HPSTR pchBuffer;
1611     HPSTR pchNext;
1612     HPSTR pchEndRead;
1613     HPSTR pchEndWrite;
1614     LONG lBufOffset;
1615     LONG lDiskOffset;
1616     DWORD[3] adwInfo;
1617     DWORD dwReserved1;
1618     DWORD dwReserved2;
1619     HMMIO hmmio;
1620 }
1621 alias MMIOINFO* PMMIOINFO, LPMMIOINFO;
1622 alias const(MMIOINFO)* LPCMMIOINFO;
1623 
1624 struct MMCKINFO {
1625     FOURCC ckid;
1626     DWORD cksize;
1627     FOURCC fccType;
1628     DWORD dwDataOffset;
1629     DWORD dwFlags;
1630 }
1631 alias MMCKINFO* PMMCKINFO, LPMMCKINFO;
1632 alias const(MMCKINFO)* LPCMMCKINFO;
1633 
1634 struct MCI_GENERIC_PARMS {
1635     DWORD_PTR dwCallback;
1636 }
1637 alias MCI_GENERIC_PARMS* PMCI_GENERIC_PARMS, LPMCI_GENERIC_PARMS;
1638 
1639 struct MCI_OPEN_PARMSA {
1640 align(1):
1641     DWORD_PTR dwCallback;
1642     MCIDEVICEID wDeviceID;
1643     LPCSTR lpstrDeviceType;
1644     LPCSTR lpstrElementName;
1645     LPCSTR lpstrAlias;
1646 }
1647 alias MCI_OPEN_PARMSA* PMCI_OPEN_PARMSA, LPMCI_OPEN_PARMSA;
1648 
1649 struct MCI_OPEN_PARMSW {
1650 align(1):
1651     DWORD_PTR dwCallback;
1652     MCIDEVICEID wDeviceID;
1653     LPCWSTR lpstrDeviceType;
1654     LPCWSTR lpstrElementName;
1655     LPCWSTR lpstrAlias;
1656 }
1657 alias MCI_OPEN_PARMSW* PMCI_OPEN_PARMSW, LPMCI_OPEN_PARMSW;
1658 
1659 struct MCI_PLAY_PARMS {
1660     DWORD_PTR dwCallback;
1661     DWORD dwFrom;
1662     DWORD dwTo;
1663 }
1664 alias MCI_PLAY_PARMS* PMCI_PLAY_PARMS, LPMCI_PLAY_PARMS;
1665 
1666 struct MCI_SEEK_PARMS {
1667     DWORD_PTR dwCallback;
1668     DWORD dwTo;
1669 }
1670 alias MCI_SEEK_PARMS* PMCI_SEEK_PARMS, LPMCI_SEEK_PARMS;
1671 
1672 struct MCI_STATUS_PARMS {
1673     DWORD_PTR dwCallback;
1674     DWORD_PTR dwReturn;
1675     DWORD dwItem;
1676     DWORD dwTrack;
1677 }
1678 alias MCI_STATUS_PARMS* PMCI_STATUS_PARMS, LPMCI_STATUS_PARMS;
1679 
1680 struct MCI_INFO_PARMSA {
1681     DWORD_PTR dwCallback;
1682     LPSTR lpstrReturn;
1683     DWORD dwRetSize;
1684 }
1685 alias MCI_INFO_PARMSA* LPMCI_INFO_PARMSA;
1686 
1687 struct MCI_INFO_PARMSW {
1688     DWORD_PTR dwCallback;
1689     LPWSTR lpstrReturn;
1690     DWORD dwRetSize;
1691 }
1692 alias MCI_INFO_PARMSW* LPMCI_INFO_PARMSW;
1693 
1694 struct MCI_GETDEVCAPS_PARMS {
1695     DWORD_PTR dwCallback;
1696     DWORD dwReturn;
1697     DWORD dwItem;
1698 }
1699 alias MCI_GETDEVCAPS_PARMS* PMCI_GETDEVCAPS_PARMS, LPMCI_GETDEVCAPS_PARMS;
1700 
1701 struct MCI_SYSINFO_PARMSA {
1702     DWORD_PTR dwCallback;
1703     LPSTR lpstrReturn;
1704     DWORD dwRetSize;
1705     DWORD dwNumber;
1706     UINT wDeviceType;
1707 }
1708 alias MCI_SYSINFO_PARMSA* PMCI_SYSINFO_PARMSA, LPMCI_SYSINFO_PARMSA;
1709 
1710 struct MCI_SYSINFO_PARMSW {
1711     DWORD_PTR dwCallback;
1712     LPWSTR lpstrReturn;
1713     DWORD dwRetSize;
1714     DWORD dwNumber;
1715     UINT wDeviceType;
1716 }
1717 alias MCI_SYSINFO_PARMSW* PMCI_SYSINFO_PARMSW, LPMCI_SYSINFO_PARMSW;
1718 
1719 struct MCI_SET_PARMS {
1720     DWORD_PTR dwCallback;
1721     DWORD dwTimeFormat;
1722     DWORD dwAudio;
1723 }
1724 alias MCI_SET_PARMS* PMCI_SET_PARMS, LPMCI_SET_PARMS;
1725 
1726 struct MCI_BREAK_PARMS {
1727 align(1):
1728     DWORD_PTR dwCallback;
1729     int nVirtKey;
1730     HWND hwndBreak;
1731 }
1732 alias MCI_BREAK_PARMS* PMCI_BREAK_PARMS, LPMCI_BREAK_PARMS;
1733 
1734 struct MCI_SAVE_PARMSA {
1735     DWORD_PTR dwCallback;
1736     LPCSTR lpfilename;
1737 }
1738 alias MCI_SAVE_PARMSA* PMCI_SAVE_PARMSA, LPMCI_SAVE_PARMSA;
1739 
1740 struct MCI_SAVE_PARMSW {
1741     DWORD_PTR dwCallback;
1742     LPCWSTR lpfilename;
1743 }
1744 alias MCI_SAVE_PARMSW* PMCI_SAVE_PARMSW, LPMCI_SAVE_PARMSW;
1745 
1746 struct MCI_LOAD_PARMSA {
1747     DWORD_PTR dwCallback;
1748     LPCSTR lpfilename;
1749 }
1750 alias MCI_LOAD_PARMSA* PMCI_LOAD_PARMSA, LPMCI_LOAD_PARMSA;
1751 
1752 struct MCI_LOAD_PARMSW {
1753     DWORD_PTR dwCallback;
1754     LPCWSTR lpfilename;
1755 }
1756 alias MCI_LOAD_PARMSW* PMCI_LOAD_PARMSW, LPMCI_LOAD_PARMSW;
1757 
1758 struct MCI_RECORD_PARMS {
1759     DWORD_PTR dwCallback;
1760     DWORD dwFrom;
1761     DWORD dwTo;
1762 }
1763 alias MCI_RECORD_PARMS* LPMCI_RECORD_PARMS;
1764 
1765 struct MCI_VD_PLAY_PARMS {
1766     DWORD_PTR dwCallback;
1767     DWORD dwFrom;
1768     DWORD dwTo;
1769     DWORD dwSpeed;
1770 }
1771 alias MCI_VD_PLAY_PARMS* PMCI_VD_PLAY_PARMS, LPMCI_VD_PLAY_PARMS;
1772 
1773 struct MCI_VD_STEP_PARMS {
1774     DWORD_PTR dwCallback;
1775     DWORD dwFrames;
1776 }
1777 alias MCI_VD_STEP_PARMS* PMCI_VD_STEP_PARMS, LPMCI_VD_STEP_PARMS;
1778 
1779 struct MCI_VD_ESCAPE_PARMSA {
1780     DWORD_PTR dwCallback;
1781     LPCSTR lpstrCommand;
1782 }
1783 alias MCI_VD_ESCAPE_PARMSA* PMCI_VD_ESCAPE_PARMSA, LPMCI_VD_ESCAPE_PARMSA;
1784 
1785 struct MCI_VD_ESCAPE_PARMSW {
1786     DWORD_PTR dwCallback;
1787     LPCWSTR lpstrCommand;
1788 }
1789 alias MCI_VD_ESCAPE_PARMSW* PMCI_VD_ESCAPE_PARMSW, LPMCI_VD_ESCAPE_PARMSW;
1790 
1791 struct MCI_WAVE_OPEN_PARMSA {
1792 align(1):
1793     DWORD_PTR dwCallback;
1794     MCIDEVICEID wDeviceID;
1795     LPCSTR lpstrDeviceType;
1796     LPCSTR lpstrElementName;
1797     LPCSTR lpstrAlias;
1798     DWORD dwBufferSeconds;
1799 }
1800 alias MCI_WAVE_OPEN_PARMSA* PMCI_WAVE_OPEN_PARMSA, LPMCI_WAVE_OPEN_PARMSA;
1801 
1802 struct MCI_WAVE_OPEN_PARMSW {
1803 align(1):
1804     DWORD_PTR dwCallback;
1805     MCIDEVICEID wDeviceID;
1806     LPCWSTR lpstrDeviceType;
1807     LPCWSTR lpstrElementName;
1808     LPCWSTR lpstrAlias;
1809     DWORD dwBufferSeconds;
1810 }
1811 alias MCI_WAVE_OPEN_PARMSW* PMCI_WAVE_OPEN_PARMSW, LPMCI_WAVE_OPEN_PARMSW;
1812 
1813 struct MCI_WAVE_DELETE_PARMS {
1814     DWORD_PTR dwCallback;
1815     DWORD dwFrom;
1816     DWORD dwTo;
1817 }
1818 alias MCI_WAVE_DELETE_PARMS* PMCI_WAVE_DELETE_PARMS, LPMCI_WAVE_DELETE_PARMS;
1819 
1820 struct MCI_WAVE_SET_PARMS {
1821     DWORD_PTR dwCallback;
1822     DWORD dwTimeFormat;
1823     DWORD dwAudio;
1824     UINT wInput;
1825     UINT wOutput;
1826     WORD wFormatTag;
1827     WORD wReserved2;
1828     WORD nChannels;
1829     WORD wReserved3;
1830     DWORD nSamplesPerSec;
1831     DWORD nAvgBytesPerSec;
1832     WORD nBlockAlign;
1833     WORD wReserved4;
1834     WORD wBitsPerSample;
1835     WORD wReserved5;
1836 }
1837 alias MCI_WAVE_SET_PARMS* PMCI_WAVE_SET_PARMS, LPMCI_WAVE_SET_PARMS;
1838 
1839 extern (Windows) nothrow @nogc:
1840 LRESULT CloseDriver(HDRVR, LONG, LONG);
1841 HDRVR OpenDriver(LPCWSTR, LPCWSTR, LONG);
1842 LRESULT SendDriverMessage(HDRVR, UINT, LONG, LONG);
1843 HMODULE DrvGetModuleHandle(HDRVR);
1844 HMODULE GetDriverModuleHandle(HDRVR);
1845 LRESULT DefDriverProc(DWORD_PTR, HDRVR, UINT, LPARAM, LPARAM);
1846 UINT mmsystemGetVersion();
1847 // FIXME: I believe this next line is a mistake
1848 //alias OutputDebugString OutputDebugStr;
1849 BOOL sndPlaySoundA(LPCSTR, UINT);
1850 BOOL sndPlaySoundW(LPCWSTR, UINT);
1851 BOOL PlaySoundA(LPCSTR, HMODULE, DWORD);
1852 BOOL PlaySoundW(LPCWSTR, HMODULE, DWORD);
1853 UINT waveOutGetNumDevs();
1854 MMRESULT waveOutGetDevCapsA(UINT_PTR, LPWAVEOUTCAPSA, UINT);
1855 MMRESULT waveOutGetDevCapsW(UINT_PTR, LPWAVEOUTCAPSW, UINT);
1856 MMRESULT waveOutGetVolume(HWAVEOUT, PDWORD);
1857 MMRESULT waveOutSetVolume(HWAVEOUT, DWORD);
1858 MMRESULT waveOutGetErrorTextA(MMRESULT, LPSTR, UINT);
1859 MMRESULT waveOutGetErrorTextW(MMRESULT, LPWSTR, UINT);
1860 MMRESULT waveOutOpen(LPHWAVEOUT, UINT, LPCWAVEFORMATEX, DWORD_PTR, DWORD_PTR, DWORD);
1861 MMRESULT waveOutClose(HWAVEOUT);
1862 MMRESULT waveOutPrepareHeader(HWAVEOUT, LPWAVEHDR, UINT);
1863 MMRESULT waveOutUnprepareHeader(HWAVEOUT, LPWAVEHDR, UINT);
1864 MMRESULT waveOutWrite(HWAVEOUT, LPWAVEHDR, UINT);
1865 MMRESULT waveOutPause(HWAVEOUT);
1866 MMRESULT waveOutRestart(HWAVEOUT);
1867 MMRESULT waveOutReset(HWAVEOUT);
1868 MMRESULT waveOutBreakLoop(HWAVEOUT);
1869 MMRESULT waveOutGetPosition(HWAVEOUT, LPMMTIME, UINT);
1870 MMRESULT waveOutGetPitch(HWAVEOUT, PDWORD);
1871 MMRESULT waveOutSetPitch(HWAVEOUT, DWORD);
1872 MMRESULT waveOutGetPlaybackRate(HWAVEOUT, PDWORD);
1873 MMRESULT waveOutSetPlaybackRate(HWAVEOUT, DWORD);
1874 MMRESULT waveOutGetID(HWAVEOUT, LPUINT);
1875 MMRESULT waveOutMessage(HWAVEOUT, UINT, DWORD_PTR, DWORD_PTR);
1876 UINT waveInGetNumDevs();
1877 MMRESULT waveInGetDevCapsA(UINT_PTR, LPWAVEINCAPSA, UINT);
1878 MMRESULT waveInGetDevCapsW(UINT_PTR, LPWAVEINCAPSW, UINT);
1879 MMRESULT waveInGetErrorTextA(MMRESULT, LPSTR, UINT);
1880 MMRESULT waveInGetErrorTextW(MMRESULT, LPWSTR, UINT);
1881 MMRESULT waveInOpen(LPHWAVEIN, UINT, LPCWAVEFORMATEX, DWORD_PTR, DWORD_PTR, DWORD);
1882 MMRESULT waveInClose(HWAVEIN);
1883 MMRESULT waveInPrepareHeader(HWAVEIN, LPWAVEHDR, UINT);
1884 MMRESULT waveInUnprepareHeader(HWAVEIN, LPWAVEHDR, UINT);
1885 MMRESULT waveInAddBuffer(HWAVEIN, LPWAVEHDR, UINT);
1886 MMRESULT waveInStart(HWAVEIN);
1887 MMRESULT waveInStop(HWAVEIN);
1888 MMRESULT waveInReset(HWAVEIN);
1889 MMRESULT waveInGetPosition(HWAVEIN, LPMMTIME, UINT);
1890 MMRESULT waveInGetID(HWAVEIN, LPUINT);
1891 MMRESULT waveInMessage(HWAVEIN, UINT, DWORD_PTR, DWORD_PTR);
1892 UINT midiOutGetNumDevs();
1893 MMRESULT midiStreamOpen(LPHMIDISTRM, LPUINT, DWORD, DWORD_PTR, DWORD_PTR, DWORD);
1894 MMRESULT midiStreamClose(HMIDISTRM);
1895 MMRESULT midiStreamProperty(HMIDISTRM, LPBYTE, DWORD);
1896 MMRESULT midiStreamPosition(HMIDISTRM, LPMMTIME, UINT);
1897 MMRESULT midiStreamOut(HMIDISTRM, LPMIDIHDR, UINT);
1898 MMRESULT midiStreamPause(HMIDISTRM);
1899 MMRESULT midiStreamRestart(HMIDISTRM);
1900 MMRESULT midiStreamStop(HMIDISTRM);
1901 MMRESULT midiConnect(HMIDI, HMIDIOUT, PVOID);
1902 MMRESULT midiDisconnect(HMIDI, HMIDIOUT, PVOID);
1903 MMRESULT midiOutGetDevCapsA(UINT_PTR, LPMIDIOUTCAPSA, UINT);
1904 MMRESULT midiOutGetDevCapsW(UINT_PTR, LPMIDIOUTCAPSW, UINT);
1905 MMRESULT midiOutGetVolume(HMIDIOUT, PDWORD);
1906 MMRESULT midiOutSetVolume(HMIDIOUT, DWORD);
1907 MMRESULT midiOutGetErrorTextA(MMRESULT, LPSTR, UINT);
1908 MMRESULT midiOutGetErrorTextW(MMRESULT, LPWSTR, UINT);
1909 MMRESULT midiOutOpen(LPHMIDIOUT, UINT, DWORD_PTR, DWORD_PTR, DWORD);
1910 MMRESULT midiOutClose(HMIDIOUT);
1911 MMRESULT midiOutPrepareHeader(HMIDIOUT, LPMIDIHDR, UINT);
1912 MMRESULT midiOutUnprepareHeader(HMIDIOUT, LPMIDIHDR, UINT);
1913 MMRESULT midiOutShortMsg(HMIDIOUT, DWORD);
1914 MMRESULT midiOutLongMsg(HMIDIOUT, LPMIDIHDR, UINT);
1915 MMRESULT midiOutReset(HMIDIOUT);
1916 MMRESULT midiOutCachePatches(HMIDIOUT, UINT, LPWORD, UINT);
1917 MMRESULT midiOutCacheDrumPatches(HMIDIOUT, UINT, LPWORD, UINT);
1918 MMRESULT midiOutGetID(HMIDIOUT, LPUINT);
1919 MMRESULT midiOutMessage(HMIDIOUT, UINT, DWORD_PTR, DWORD_PTR);
1920 UINT midiInGetNumDevs();
1921 MMRESULT midiInGetDevCapsA(UINT_PTR, LPMIDIINCAPSA, UINT);
1922 MMRESULT midiInGetDevCapsW(UINT_PTR, LPMIDIINCAPSW, UINT);
1923 MMRESULT midiInGetErrorTextA(MMRESULT, LPSTR, UINT);
1924 MMRESULT midiInGetErrorTextW(MMRESULT, LPWSTR, UINT);
1925 MMRESULT midiInOpen(LPHMIDIIN, UINT, DWORD_PTR, DWORD_PTR, DWORD);
1926 MMRESULT midiInClose(HMIDIIN);
1927 MMRESULT midiInPrepareHeader(HMIDIIN, LPMIDIHDR, UINT);
1928 MMRESULT midiInUnprepareHeader(HMIDIIN, LPMIDIHDR, UINT);
1929 MMRESULT midiInAddBuffer(HMIDIIN, LPMIDIHDR, UINT);
1930 MMRESULT midiInStart(HMIDIIN);
1931 MMRESULT midiInStop(HMIDIIN);
1932 MMRESULT midiInReset(HMIDIIN);
1933 MMRESULT midiInGetID(HMIDIIN, LPUINT);
1934 MMRESULT midiInMessage(HMIDIIN, UINT, DWORD_PTR, DWORD_PTR);
1935 UINT auxGetNumDevs();
1936 MMRESULT auxGetDevCapsA(UINT_PTR, LPAUXCAPSA, UINT);
1937 MMRESULT auxGetDevCapsW(UINT_PTR, LPAUXCAPSW, UINT);
1938 MMRESULT auxSetVolume(UINT, DWORD);
1939 MMRESULT auxGetVolume(UINT, PDWORD);
1940 MMRESULT auxOutMessage(UINT, UINT, DWORD_PTR, DWORD_PTR);
1941 UINT mixerGetNumDevs();
1942 MMRESULT mixerGetDevCapsA(UINT_PTR, LPMIXERCAPSA, UINT);
1943 MMRESULT mixerGetDevCapsW(UINT_PTR, LPMIXERCAPSW, UINT);
1944 MMRESULT mixerOpen(LPHMIXER, UINT, DWORD_PTR, DWORD_PTR, DWORD);
1945 MMRESULT mixerClose(HMIXER);
1946 DWORD mixerMessage(HMIXER, UINT, DWORD_PTR, DWORD_PTR);
1947 MMRESULT mixerGetLineInfoA(HMIXEROBJ, LPMIXERLINEA, DWORD);
1948 MMRESULT mixerGetLineInfoW(HMIXEROBJ, LPMIXERLINEW, DWORD);
1949 MMRESULT mixerGetID(HMIXEROBJ, PUINT, DWORD);
1950 MMRESULT mixerGetLineControlsA(HMIXEROBJ, LPMIXERLINECONTROLSA, DWORD);
1951 MMRESULT mixerGetLineControlsW(HMIXEROBJ, LPMIXERLINECONTROLSW, DWORD);
1952 MMRESULT mixerGetControlDetailsA(HMIXEROBJ, LPMIXERCONTROLDETAILS, DWORD);
1953 MMRESULT mixerGetControlDetailsW(HMIXEROBJ, LPMIXERCONTROLDETAILS, DWORD);
1954 MMRESULT mixerSetControlDetails(HMIXEROBJ, LPMIXERCONTROLDETAILS, DWORD);
1955 MMRESULT timeGetSystemTime(LPMMTIME, UINT);
1956 DWORD timeGetTime();
1957 MMRESULT timeSetEvent(UINT, UINT, LPTIMECALLBACK, DWORD_PTR, UINT);
1958 MMRESULT timeKillEvent(UINT);
1959 MMRESULT timeGetDevCaps(LPTIMECAPS, UINT);
1960 MMRESULT timeBeginPeriod(UINT);
1961 MMRESULT timeEndPeriod(UINT);
1962 UINT joyGetNumDevs();
1963 MMRESULT joyGetDevCapsA(UINT_PTR, LPJOYCAPSA, UINT);
1964 MMRESULT joyGetDevCapsW(UINT_PTR, LPJOYCAPSW, UINT);
1965 MMRESULT joyGetPos(UINT, LPJOYINFO);
1966 MMRESULT joyGetPosEx(UINT, LPJOYINFOEX);
1967 MMRESULT joyGetThreshold(UINT, LPUINT);
1968 MMRESULT joyReleaseCapture(UINT);
1969 MMRESULT joySetCapture(HWND, UINT, UINT, BOOL);
1970 MMRESULT joySetThreshold(UINT, UINT);
1971 FOURCC mmioStringToFOURCCA(LPCSTR, UINT);
1972 FOURCC mmioStringToFOURCCW(LPCWSTR, UINT);
1973 LPMMIOPROC mmioInstallIOProcA(FOURCC, LPMMIOPROC, DWORD);
1974 LPMMIOPROC mmioInstallIOProcW(FOURCC, LPMMIOPROC, DWORD);
1975 HMMIO mmioOpenA(LPSTR, LPMMIOINFO, DWORD);
1976 HMMIO mmioOpenW(LPWSTR, LPMMIOINFO, DWORD);
1977 MMRESULT mmioRenameA(LPCSTR, LPCSTR, LPCMMIOINFO, DWORD);
1978 MMRESULT mmioRenameW(LPCWSTR, LPCWSTR, LPCMMIOINFO, DWORD);
1979 MMRESULT mmioClose(HMMIO, UINT);
1980 LONG mmioRead(HMMIO, HPSTR, LONG);
1981 LONG mmioWrite(HMMIO, LPCSTR, LONG);
1982 LONG mmioSeek(HMMIO, LONG, int);
1983 MMRESULT mmioGetInfo(HMMIO, LPMMIOINFO, UINT);
1984 MMRESULT mmioSetInfo(HMMIO, LPCMMIOINFO, UINT);
1985 MMRESULT mmioSetBuffer(HMMIO, LPSTR, LONG, UINT);
1986 MMRESULT mmioFlush(HMMIO, UINT);
1987 MMRESULT mmioAdvance(HMMIO, LPMMIOINFO, UINT);
1988 LRESULT mmioSendMessage(HMMIO, UINT, LPARAM, LPARAM);
1989 MMRESULT mmioDescend(HMMIO, LPMMCKINFO, const(MMCKINFO)*, UINT);
1990 MMRESULT mmioAscend(HMMIO, LPMMCKINFO, UINT);
1991 MMRESULT mmioCreateChunk(HMMIO, LPMMCKINFO, UINT);
1992 MCIERROR mciSendCommandA(MCIDEVICEID, UINT, DWORD_PTR, DWORD_PTR);
1993 MCIERROR mciSendCommandW(MCIDEVICEID, UINT, DWORD_PTR, DWORD_PTR);
1994 MCIERROR mciSendStringA(LPCSTR, LPSTR, UINT, HWND);
1995 MCIERROR mciSendStringW(LPCWSTR, LPWSTR, UINT, HWND);
1996 MCIDEVICEID mciGetDeviceIDA(LPCSTR);
1997 MCIDEVICEID mciGetDeviceIDW(LPCWSTR);
1998 MCIDEVICEID mciGetDeviceIDFromElementIDA(DWORD, LPCSTR);
1999 MCIDEVICEID mciGetDeviceIDFromElementIDW(DWORD, LPCWSTR);
2000 BOOL mciGetErrorStringA(MCIERROR, LPSTR, UINT);
2001 BOOL mciGetErrorStringW(MCIERROR, LPWSTR, UINT);
2002 BOOL mciSetYieldProc(MCIDEVICEID, YIELDPROC, DWORD);
2003 HTASK mciGetCreatorTask(MCIDEVICEID);
2004 YIELDPROC mciGetYieldProc(MCIDEVICEID, PDWORD);
2005 
2006 struct MCI_SEQ_SET_PARMS {
2007     DWORD_PTR dwCallback;
2008     DWORD dwTimeFormat;
2009     DWORD dwAudio;
2010     DWORD dwTempo;
2011     DWORD dwPort;
2012     DWORD dwSlave;
2013     DWORD dwMaster;
2014     DWORD dwOffset;
2015 }
2016 alias MCI_SEQ_SET_PARMS* PMCI_SEQ_SET_PARMS, LPMCI_SEQ_SET_PARMS;
2017 
2018 struct MCI_ANIM_OPEN_PARMSA {
2019 align(1):
2020     DWORD_PTR dwCallback;
2021     MCIDEVICEID wDeviceID;
2022     LPCSTR lpstrDeviceType;
2023     LPCSTR lpstrElementName;
2024     LPCSTR lpstrAlias;
2025     DWORD dwStyle;
2026     HWND hWndParent;
2027 }
2028 alias MCI_ANIM_OPEN_PARMSA* PMCI_ANIM_OPEN_PARMSA, LPMCI_ANIM_OPEN_PARMSA;
2029 
2030 struct MCI_ANIM_OPEN_PARMSW {
2031 align(1):
2032     DWORD_PTR dwCallback;
2033     MCIDEVICEID wDeviceID;
2034     LPCWSTR lpstrDeviceType;
2035     LPCWSTR lpstrElementName;
2036     LPCWSTR lpstrAlias;
2037     DWORD dwStyle;
2038     HWND hWndParent;
2039 }
2040 alias MCI_ANIM_OPEN_PARMSW* PMCI_ANIM_OPEN_PARMSW, LPMCI_ANIM_OPEN_PARMSW;
2041 
2042 struct MCI_ANIM_PLAY_PARMS {
2043     DWORD_PTR dwCallback;
2044     DWORD dwFrom;
2045     DWORD dwTo;
2046     DWORD dwSpeed;
2047 }
2048 alias MCI_ANIM_PLAY_PARMS* PMCI_ANIM_PLAY_PARMS, LPMCI_ANIM_PLAY_PARMS;
2049 
2050 struct MCI_ANIM_STEP_PARMS {
2051     DWORD_PTR dwCallback;
2052     DWORD dwFrames;
2053 }
2054 alias MCI_ANIM_STEP_PARMS* PMCI_ANIM_STEP_PARMS, LPMCI_ANIM_STEP_PARMS;
2055 
2056 struct MCI_ANIM_WINDOW_PARMSA {
2057 align(1):
2058     DWORD_PTR dwCallback;
2059     HWND hWnd;
2060     UINT nCmdShow;
2061     LPCSTR lpstrText;
2062 }
2063 alias MCI_ANIM_WINDOW_PARMSA* PMCI_ANIM_WINDOW_PARMSA, LPMCI_ANIM_WINDOW_PARMSA;
2064 
2065 struct MCI_ANIM_WINDOW_PARMSW {
2066 align(1):
2067     DWORD_PTR dwCallback;
2068     HWND hWnd;
2069     UINT nCmdShow;
2070     LPCWSTR lpstrText;
2071 }
2072 alias MCI_ANIM_WINDOW_PARMSW* PMCI_ANIM_WINDOW_PARMSW, LPMCI_ANIM_WINDOW_PARMSW;
2073 
2074 struct MCI_ANIM_RECT_PARMS {
2075     DWORD_PTR dwCallback;
2076     //#ifdef MCI_USE_OFFEXT
2077     //  POINT ptOffset;
2078     //  POINT ptExtent;
2079     //#else
2080     RECT rc;
2081     //#endif
2082 }
2083 alias MCI_ANIM_RECT_PARMS* PMCI_ANIM_RECT_PARMS, LPMCI_ANIM_RECT_PARMS;
2084 
2085 struct MCI_ANIM_UPDATE_PARMS {
2086     DWORD_PTR dwCallback;
2087     RECT rc;
2088     HDC hDC;
2089 }
2090 alias MCI_ANIM_UPDATE_PARMS* PMCI_ANIM_UPDATE_PARMS, LPMCI_ANIM_UPDATE_PARMS;
2091 
2092 struct MCI_OVLY_OPEN_PARMSA {
2093 align(1):
2094     DWORD_PTR dwCallback;
2095     MCIDEVICEID wDeviceID;
2096     LPCSTR lpstrDeviceType;
2097     LPCSTR lpstrElementName;
2098     LPCSTR lpstrAlias;
2099     DWORD dwStyle;
2100     HWND hWndParent;
2101 }
2102 alias MCI_OVLY_OPEN_PARMSA* PMCI_OVLY_OPEN_PARMSA, LPMCI_OVLY_OPEN_PARMSA;
2103 
2104 struct MCI_OVLY_OPEN_PARMSW {
2105 align(1):
2106     DWORD_PTR dwCallback;
2107     MCIDEVICEID wDeviceID;
2108     LPCWSTR lpstrDeviceType;
2109     LPCWSTR lpstrElementName;
2110     LPCWSTR lpstrAlias;
2111     DWORD dwStyle;
2112     HWND hWndParent;
2113 }
2114 alias MCI_OVLY_OPEN_PARMSW* PMCI_OVLY_OPEN_PARMSW, LPMCI_OVLY_OPEN_PARMSW;
2115 
2116 struct MCI_OVLY_WINDOW_PARMSA {
2117 align(1):
2118     DWORD_PTR dwCallback;
2119     HWND hWnd;
2120     UINT nCmdShow;
2121     LPCSTR lpstrText;
2122 }
2123 alias MCI_OVLY_WINDOW_PARMSA* PMCI_OVLY_WINDOW_PARMSA, LPMCI_OVLY_WINDOW_PARMSA;
2124 
2125 struct MCI_OVLY_WINDOW_PARMSW {
2126 align(1):
2127     DWORD_PTR dwCallback;
2128     HWND hWnd;
2129     UINT nCmdShow;
2130     LPCWSTR lpstrText;
2131 }
2132 alias MCI_OVLY_WINDOW_PARMSW* PMCI_OVLY_WINDOW_PARMSW, LPMCI_OVLY_WINDOW_PARMSW;
2133 
2134 struct MCI_OVLY_RECT_PARMS {
2135     DWORD_PTR dwCallback;
2136     //#ifdef MCI_USE_OFFEXT
2137     //  POINT ptOffset;
2138     //  POINT ptExtent;
2139     //#else
2140     RECT rc;
2141     //#endif
2142 }
2143 alias MCI_OVLY_RECT_PARMS* PMCI_OVLY_RECT_PARMS, LPMCI_OVLY_RECT_PARMS;
2144 
2145 struct MCI_OVLY_SAVE_PARMSA {
2146     DWORD_PTR dwCallback;
2147     LPCSTR lpfilename;
2148     RECT rc;
2149 }
2150 alias MCI_OVLY_SAVE_PARMSA* PMCI_OVLY_SAVE_PARMSA, LPMCI_OVLY_SAVE_PARMSA;
2151 
2152 struct MCI_OVLY_SAVE_PARMSW {
2153     DWORD_PTR dwCallback;
2154     LPCWSTR lpfilename;
2155     RECT rc;
2156 }
2157 alias MCI_OVLY_SAVE_PARMSW* PMCI_OVLY_SAVE_PARMSW, LPMCI_OVLY_SAVE_PARMSW;
2158 
2159 struct MCI_OVLY_LOAD_PARMSA {
2160     DWORD_PTR dwCallback;
2161     LPCSTR lpfilename;
2162     RECT rc;
2163 }
2164 alias MCI_OVLY_LOAD_PARMSA* PMCI_OVLY_LOAD_PARMSA, LPMCI_OVLY_LOAD_PARMSA;
2165 
2166 struct MCI_OVLY_LOAD_PARMSW {
2167     DWORD_PTR dwCallback;
2168     LPCWSTR lpfilename;
2169     RECT rc;
2170 }
2171 alias MCI_OVLY_LOAD_PARMSW* PMCI_OVLY_LOAD_PARMSW, LPMCI_OVLY_LOAD_PARMSW;
2172 
2173 version (Unicode) {
2174     alias WAVEOUTCAPSW WAVEOUTCAPS;
2175     alias WAVEINCAPSW WAVEINCAPS;
2176     alias MIDIOUTCAPSW MIDIOUTCAPS;
2177     alias MIDIINCAPSW MIDIINCAPS;
2178     alias AUXCAPSW AUXCAPS;
2179     alias MIXERCAPSW MIXERCAPS;
2180     alias MIXERLINEW MIXERLINE;
2181     alias MIXERCONTROLA MIXERCONTROL;
2182     alias MIXERLINECONTROLSW MIXERLINECONTROLS;
2183     alias MIXERCONTROLDETAILS_LISTTEXTW MIXERCONTROLDETAILS_LISTTEXT;
2184     alias JOYCAPSW JOYCAPS;
2185     alias MCI_OPEN_PARMSW MCI_OPEN_PARMS;
2186     alias MCI_INFO_PARMSW MCI_INFO_PARMS;
2187     alias MCI_SYSINFO_PARMSW MCI_SYSINFO_PARMS;
2188     alias MCI_SAVE_PARMSW MCI_SAVE_PARMS;
2189     alias MCI_LOAD_PARMSW MCI_LOAD_PARMS;
2190     alias MCI_VD_ESCAPE_PARMSW MCI_VD_ESCAPE_PARMS;
2191     alias MCI_WAVE_OPEN_PARMSW MCI_WAVE_OPEN_PARMS;
2192     alias MCI_ANIM_OPEN_PARMSW MCI_ANIM_OPEN_PARMS;
2193     alias MCI_ANIM_WINDOW_PARMSW MCI_ANIM_WINDOW_PARMS;
2194     alias MCI_OVLY_OPEN_PARMSW MCI_OVLY_OPEN_PARMS;
2195     alias MCI_OVLY_WINDOW_PARMSW MCI_OVLY_WINDOW_PARMS;
2196     alias MCI_OVLY_SAVE_PARMSW MCI_OVLY_SAVE_PARMS;
2197 
2198     alias sndPlaySoundW sndPlaySound;
2199     alias PlaySoundW PlaySound;
2200     alias waveOutGetDevCapsW waveOutGetDevCaps;
2201     alias waveOutGetErrorTextW waveOutGetErrorText;
2202     alias waveInGetDevCapsW waveInGetDevCaps;
2203     alias waveInGetErrorTextW waveInGetErrorText;
2204     alias midiOutGetDevCapsW midiOutGetDevCaps;
2205     alias midiOutGetErrorTextW midiOutGetErrorText;
2206     alias midiInGetDevCapsW midiInGetDevCaps;
2207     alias midiInGetErrorTextW midiInGetErrorText;
2208     alias auxGetDevCapsW auxGetDevCaps;
2209     alias mixerGetDevCapsW mixerGetDevCaps;
2210     alias mixerGetLineInfoW mixerGetLineInfo;
2211     alias mixerGetLineControlsW mixerGetLineControls;
2212     alias mixerGetControlDetailsW mixerGetControlDetails;
2213     alias joyGetDevCapsW joyGetDevCaps;
2214     alias mmioInstallIOProcW mmioInstallIOProc;
2215     alias mmioStringToFOURCCW mmioStringToFOURCC;
2216     alias mmioOpenW mmioOpen;
2217     alias mmioRenameW mmioRename;
2218     alias mciSendCommandW mciSendCommand;
2219     alias mciSendStringW mciSendString;
2220     alias mciGetDeviceIDW mciGetDeviceID;
2221     alias mciGetDeviceIDFromElementIDW mciGetDeviceIDFromElementID;
2222     alias mciGetErrorStringW mciGetErrorString;
2223 
2224 } else {
2225     alias WAVEOUTCAPSA WAVEOUTCAPS;
2226     alias WAVEINCAPSA WAVEINCAPS;
2227     alias MIDIOUTCAPSA MIDIOUTCAPS;
2228     alias MIDIINCAPSA MIDIINCAPS;
2229     alias AUXCAPSA AUXCAPS;
2230     alias MIXERCAPSA MIXERCAPS;
2231     alias MIXERLINEA MIXERLINE;
2232     alias MIXERCONTROLA MIXERCONTROL;
2233     alias MIXERLINECONTROLSA MIXERLINECONTROLS;
2234     alias MIXERCONTROLDETAILS_LISTTEXTA MIXERCONTROLDETAILS_LISTTEXT;
2235     alias JOYCAPSA JOYCAPS;
2236     alias MCI_OPEN_PARMSA MCI_OPEN_PARMS;
2237     alias MCI_INFO_PARMSA MCI_INFO_PARMS;
2238     alias MCI_SYSINFO_PARMSA MCI_SYSINFO_PARMS;
2239     alias MCI_SAVE_PARMSA MCI_SAVE_PARMS;
2240     alias MCI_LOAD_PARMSA MCI_LOAD_PARMS;
2241     alias MCI_VD_ESCAPE_PARMSA MCI_VD_ESCAPE_PARMS;
2242     alias MCI_WAVE_OPEN_PARMSA MCI_WAVE_OPEN_PARMS;
2243     alias MCI_ANIM_OPEN_PARMSA MCI_ANIM_OPEN_PARMS;
2244     alias MCI_ANIM_WINDOW_PARMSA MCI_ANIM_WINDOW_PARMS;
2245     alias MCI_OVLY_OPEN_PARMSA MCI_OVLY_OPEN_PARMS;
2246     alias MCI_OVLY_WINDOW_PARMSA MCI_OVLY_WINDOW_PARMS;
2247     alias MCI_OVLY_SAVE_PARMSA MCI_OVLY_SAVE_PARMS;
2248 
2249     alias sndPlaySoundA sndPlaySound;
2250     alias PlaySoundA PlaySound;
2251     alias waveOutGetDevCapsA waveOutGetDevCaps;
2252     alias waveOutGetErrorTextA waveOutGetErrorText;
2253     alias waveInGetDevCapsA waveInGetDevCaps;
2254     alias waveInGetErrorTextA waveInGetErrorText;
2255     alias midiOutGetDevCapsA midiOutGetDevCaps;
2256     alias midiOutGetErrorTextA midiOutGetErrorText;
2257     alias midiInGetDevCapsA midiInGetDevCaps;
2258     alias midiInGetErrorTextA midiInGetErrorText;
2259     alias auxGetDevCapsA auxGetDevCaps;
2260     alias mixerGetDevCapsA mixerGetDevCaps;
2261     alias mixerGetLineInfoA mixerGetLineInfo;
2262     alias mixerGetLineControlsA mixerGetLineControls;
2263     alias mixerGetControlDetailsA mixerGetControlDetails;
2264     alias joyGetDevCapsA joyGetDevCaps;
2265     alias mmioInstallIOProcA mmioInstallIOProc;
2266     alias mmioStringToFOURCCA mmioStringToFOURCC;
2267     alias mmioOpenA mmioOpen;
2268     alias mmioRenameA mmioRename;
2269     alias mciSendCommandA mciSendCommand;
2270     alias mciSendStringA mciSendString;
2271     alias mciGetDeviceIDA mciGetDeviceID;
2272     alias mciGetDeviceIDFromElementIDA mciGetDeviceIDFromElementID;
2273     alias mciGetErrorStringA mciGetErrorString;
2274 }
2275 
2276 alias WAVEOUTCAPS* PWAVEOUTCAPS, LPWAVEOUTCAPS;
2277 alias WAVEINCAPS* PWAVEINCAPS, LPWAVEINCAPS;
2278 alias MIDIOUTCAPS* PMIDIOUTCAPS, LPMIDIOUTCAPS;
2279 alias MIDIINCAPS* PMIDIINCAPS, LPMIDIINCAPS;
2280 alias AUXCAPS* PAUXCAPS, LPAUXCAPS;
2281 alias MIXERCAPS* PMIXERCAPS, LPMIXERCAPS;
2282 alias MIXERLINE* PMIXERLINE, LPMIXERLINE;
2283 alias MIXERCONTROL* PMIXERCONTROL, LPMIXERCONTROL;
2284 alias MIXERLINECONTROLS* PMIXERLINECONTROLS, LPMIXERLINECONTROLS;
2285 alias MIXERCONTROLDETAILS_LISTTEXT* PMIXERCONTROLDETAILS_LISTTEXT, LPMIXERCONTROLDETAILS_LISTTEXT;
2286 alias JOYCAPS* PJOYCAPS, LPJOYCAPS;
2287 alias MCI_OPEN_PARMS* PMCI_OPEN_PARMS, LPMCI_OPEN_PARMS;
2288 alias MCI_INFO_PARMS* LPMCI_INFO_PARMS;
2289 alias MCI_SYSINFO_PARMS* PMCI_SYSINFO_PARMS, LPMCI_SYSINFO_PARMS;
2290 alias MCI_SAVE_PARMS* PMCI_SAVE_PARMS, LPMCI_SAVE_PARMS;
2291 alias MCI_LOAD_PARMS* PMCI_LOAD_PARMS, LPMCI_LOAD_PARMS;
2292 alias MCI_VD_ESCAPE_PARMS* PMCI_VD_ESCAPE_PARMS, LPMCI_VD_ESCAPE_PARMS;
2293 alias MCI_WAVE_OPEN_PARMS* PMCI_WAVE_OPEN_PARMS, LPMCI_WAVE_OPEN_PARMS;
2294 alias MCI_ANIM_OPEN_PARMS* PMCI_ANIM_OPEN_PARMS, LPMCI_ANIM_OPEN_PARMS;
2295 alias MCI_ANIM_WINDOW_PARMS* PMCI_ANIM_WINDOW_PARMS, LPMCI_ANIM_WINDOW_PARMS;
2296 alias MCI_OVLY_OPEN_PARMS* PMCI_OVLY_OPEN_PARMS, LPMCI_OVLY_OPEN_PARMS;
2297 alias MCI_OVLY_WINDOW_PARMS* PMCI_OVLY_WINDOW_PARMS, LPMCI_OVLY_WINDOW_PARMS;
2298 alias MCI_OVLY_SAVE_PARMS* PMCI_OVLY_SAVE_PARMS, LPMCI_OVLY_SAVE_PARMS;