2 * MMSYSTEM - Multimedia Wine Extension ... :-)
8 typedef LPSTR HPSTR
; /* a huge version of LPSTR */
9 typedef LPCSTR HPCSTR
; /* a huge version of LPCSTR */
11 #define MAXWAVEDRIVERS 10
12 #define MAXMIDIDRIVERS 10
13 #define MAXAUXDRIVERS 10
14 #define MAXMCIDRIVERS 32
16 #define MAXPNAMELEN 32 /* max product name length (including NULL) */
17 #define MAXERRORLENGTH 128 /* max error text length (including NULL) */
19 typedef WORD VERSION
; /* major (high byte), minor (low byte) */
22 UINT wType
; /* indicates the contents of the union */
24 DWORD ms
; /* milliseconds */
25 DWORD sample
; /* samples */
26 DWORD cb
; /* byte count */
28 BYTE hour
; /* hours */
29 BYTE min
; /* minutes */
30 BYTE sec
; /* seconds */
31 BYTE frame
; /* frames */
32 BYTE fps
; /* frames per second */
36 DWORD songptrpos
; /* song pointer position */
40 typedef MMTIME FAR
*LPMMTIME
;
42 #define TIME_MS 0x0001 /* time in milliseconds */
43 #define TIME_SAMPLES 0x0002 /* number of wave samples */
44 #define TIME_BYTES 0x0004 /* current byte offset */
45 #define TIME_SMPTE 0x0008 /* SMPTE time */
46 #define TIME_MIDI 0x0010 /* MIDI time */
48 #define MM_JOY1MOVE 0x3A0 /* joystick */
49 #define MM_JOY2MOVE 0x3A1
50 #define MM_JOY1ZMOVE 0x3A2
51 #define MM_JOY2ZMOVE 0x3A3
52 #define MM_JOY1BUTTONDOWN 0x3B5
53 #define MM_JOY2BUTTONDOWN 0x3B6
54 #define MM_JOY1BUTTONUP 0x3B7
55 #define MM_JOY2BUTTONUP 0x3B8
57 #define MM_MCINOTIFY 0x3B9 /* MCI */
59 #define MM_WOM_OPEN 0x3BB /* waveform output */
60 #define MM_WOM_CLOSE 0x3BC
61 #define MM_WOM_DONE 0x3BD
63 #define MM_WIM_OPEN 0x3BE /* waveform input */
64 #define MM_WIM_CLOSE 0x3BF
65 #define MM_WIM_DATA 0x3C0
67 #define MM_MIM_OPEN 0x3C1 /* MIDI input */
68 #define MM_MIM_CLOSE 0x3C2
69 #define MM_MIM_DATA 0x3C3
70 #define MM_MIM_LONGDATA 0x3C4
71 #define MM_MIM_ERROR 0x3C5
72 #define MM_MIM_LONGERROR 0x3C6
74 #define MM_MOM_OPEN 0x3C7 /* MIDI output */
75 #define MM_MOM_CLOSE 0x3C8
76 #define MM_MOM_DONE 0x3C9
79 #define MMSYSERR_BASE 0
80 #define WAVERR_BASE 32
81 #define MIDIERR_BASE 64
82 #define TIMERR_BASE 96
83 #define JOYERR_BASE 160
84 #define MCIERR_BASE 256
86 #define MCI_STRING_OFFSET 512
87 #define MCI_VD_OFFSET 1024
88 #define MCI_CD_OFFSET 1088
89 #define MCI_WAVE_OFFSET 1152
90 #define MCI_SEQ_OFFSET 1216
92 #define MMSYSERR_NOERROR 0 /* no error */
93 #define MMSYSERR_ERROR (MMSYSERR_BASE + 1) /* unspecified error */
94 #define MMSYSERR_BADDEVICEID (MMSYSERR_BASE + 2) /* device ID out of range */
95 #define MMSYSERR_NOTENABLED (MMSYSERR_BASE + 3) /* driver failed enable */
96 #define MMSYSERR_ALLOCATED (MMSYSERR_BASE + 4) /* device already allocated */
97 #define MMSYSERR_INVALHANDLE (MMSYSERR_BASE + 5) /* device handle is invalid */
98 #define MMSYSERR_NODRIVER (MMSYSERR_BASE + 6) /* no device driver present */
99 #define MMSYSERR_NOMEM (MMSYSERR_BASE + 7) /* memory allocation error */
100 #define MMSYSERR_NOTSUPPORTED (MMSYSERR_BASE + 8) /* function isn't supported */
101 #define MMSYSERR_BADERRNUM (MMSYSERR_BASE + 9) /* error value out of range */
102 #define MMSYSERR_INVALFLAG (MMSYSERR_BASE + 10) /* invalid flag passed */
103 #define MMSYSERR_INVALPARAM (MMSYSERR_BASE + 11) /* invalid parameter passed */
104 #define MMSYSERR_LASTERROR (MMSYSERR_BASE + 11) /* last error in range */
106 #define CALLBACK_TYPEMASK 0x00070000l /* callback type mask */
107 #define CALLBACK_NULL 0x00000000l /* no callback */
108 #define CALLBACK_WINDOW 0x00010000l /* dwCallback is a HWND */
109 #define CALLBACK_TASK 0x00020000l /* dwCallback is a HTASK */
110 #define CALLBACK_FUNCTION 0x00030000l /* dwCallback is a FARPROC */
112 typedef void (CALLBACK DRVCALLBACK
) (HDRVR h
, UINT uMessage
, DWORD dwUser
, DWORD dw1
, DWORD dw2
);
114 typedef DRVCALLBACK FAR
*LPDRVCALLBACK
;
116 #define MM_MICROSOFT 1 /* Microsoft Corp. */
118 #define MM_MIDI_MAPPER 1 /* MIDI Mapper */
119 #define MM_WAVE_MAPPER 2 /* Wave Mapper */
121 #define MM_SNDBLST_MIDIOUT 3 /* Sound Blaster MIDI output port */
122 #define MM_SNDBLST_MIDIIN 4 /* Sound Blaster MIDI input port */
123 #define MM_SNDBLST_SYNTH 5 /* Sound Blaster internal synthesizer */
124 #define MM_SNDBLST_WAVEOUT 6 /* Sound Blaster waveform output */
125 #define MM_SNDBLST_WAVEIN 7 /* Sound Blaster waveform input */
127 #define MM_ADLIB 9 /* Ad Lib-compatible synthesizer */
129 #define MM_MPU401_MIDIOUT 10 /* MPU401-compatible MIDI output port */
130 #define MM_MPU401_MIDIIN 11 /* MPU401-compatible MIDI input port */
132 #define MM_PC_JOYSTICK 12 /* Joystick adapter */
135 WORD WINAPI
mmsystemGetVersion(void);
136 void WINAPI
OutputDebugStr(LPCSTR
);
138 BOOL WINAPI
sndPlaySound(LPCSTR lpszSoundName
, UINT uFlags
);
140 #define SND_SYNC 0x0000 /* play synchronously (default) */
141 #define SND_ASYNC 0x0001 /* play asynchronously */
142 #define SND_NODEFAULT 0x0002 /* don't use default sound */
143 #define SND_MEMORY 0x0004 /* lpszSoundName points to a memory file */
144 #define SND_LOOP 0x0008 /* loop the sound until next sndPlaySound */
145 #define SND_NOSTOP 0x0010 /* don't stop any currently playing sound */
147 /* waveform audio error return values */
148 #define WAVERR_BADFORMAT (WAVERR_BASE + 0) /* unsupported wave format */
149 #define WAVERR_STILLPLAYING (WAVERR_BASE + 1) /* still something playing */
150 #define WAVERR_UNPREPARED (WAVERR_BASE + 2) /* header not prepared */
151 #define WAVERR_SYNC (WAVERR_BASE + 3) /* device is synchronous */
152 #define WAVERR_LASTERROR (WAVERR_BASE + 3) /* last error in range */
154 DECLARE_HANDLE(HWAVE
);
155 DECLARE_HANDLE(HWAVEIN
);
156 DECLARE_HANDLE(HWAVEOUT
);
157 typedef HWAVEIN FAR
*LPHWAVEIN
;
158 typedef HWAVEOUT FAR
*LPHWAVEOUT
;
159 typedef DRVCALLBACK WAVECALLBACK
;
160 typedef WAVECALLBACK FAR
*LPWAVECALLBACK
;
162 #define WOM_OPEN MM_WOM_OPEN
163 #define WOM_CLOSE MM_WOM_CLOSE
164 #define WOM_DONE MM_WOM_DONE
165 #define WIM_OPEN MM_WIM_OPEN
166 #define WIM_CLOSE MM_WIM_CLOSE
167 #define WIM_DATA MM_WIM_DATA
169 #define WAVE_MAPPER (-1)
171 #define WAVE_FORMAT_QUERY 0x0001
172 #define WAVE_ALLOWSYNC 0x0002
174 typedef struct wavehdr_tag
{
175 LPSTR lpData
; /* pointer to locked data buffer */
176 DWORD dwBufferLength
; /* length of data buffer */
177 DWORD dwBytesRecorded
; /* used for input only */
178 DWORD dwUser
; /* for client's use */
179 DWORD dwFlags
; /* assorted flags (see defines) */
180 DWORD dwLoops
; /* loop control counter */
181 struct wavehdr_tag FAR
*lpNext
; /* reserved for driver */
182 DWORD reserved
; /* reserved for driver */
184 typedef WAVEHDR FAR
*LPWAVEHDR
;
186 #define WHDR_DONE 0x00000001 /* done bit */
187 #define WHDR_PREPARED 0x00000002 /* set if this header has been prepared */
188 #define WHDR_BEGINLOOP 0x00000004 /* loop start block */
189 #define WHDR_ENDLOOP 0x00000008 /* loop end block */
190 #define WHDR_INQUEUE 0x00000010 /* reserved for driver */
193 UINT wMid
; /* manufacturer ID */
194 UINT wPid
; /* product ID */
195 VERSION vDriverVersion
; /* version of the driver */
196 char szPname
[MAXPNAMELEN
]; /* product name (NULL terminated string) */
197 DWORD dwFormats
; /* formats supported */
198 UINT wChannels
; /* number of sources supported */
199 DWORD dwSupport
; /* functionality supported by driver */
201 typedef WAVEOUTCAPS FAR
*LPWAVEOUTCAPS
;
203 #define WAVECAPS_PITCH 0x0001 /* supports pitch control */
204 #define WAVECAPS_PLAYBACKRATE 0x0002 /* supports playback rate control */
205 #define WAVECAPS_VOLUME 0x0004 /* supports volume control */
206 #define WAVECAPS_LRVOLUME 0x0008 /* separate left-right volume control */
207 #define WAVECAPS_SYNC 0x0010
210 UINT wMid
; /* manufacturer ID */
211 UINT wPid
; /* product ID */
212 VERSION vDriverVersion
; /* version of the driver */
213 char szPname
[MAXPNAMELEN
]; /* product name (NULL terminated string) */
214 DWORD dwFormats
; /* formats supported */
215 UINT wChannels
; /* number of channels supported */
217 typedef WAVEINCAPS FAR
*LPWAVEINCAPS
;
219 #define WAVE_INVALIDFORMAT 0x00000000 /* invalid format */
220 #define WAVE_FORMAT_1M08 0x00000001 /* 11.025 kHz, Mono, 8-bit */
221 #define WAVE_FORMAT_1S08 0x00000002 /* 11.025 kHz, Stereo, 8-bit */
222 #define WAVE_FORMAT_1M16 0x00000004 /* 11.025 kHz, Mono, 16-bit */
223 #define WAVE_FORMAT_1S16 0x00000008 /* 11.025 kHz, Stereo, 16-bit */
224 #define WAVE_FORMAT_2M08 0x00000010 /* 22.05 kHz, Mono, 8-bit */
225 #define WAVE_FORMAT_2S08 0x00000020 /* 22.05 kHz, Stereo, 8-bit */
226 #define WAVE_FORMAT_2M16 0x00000040 /* 22.05 kHz, Mono, 16-bit */
227 #define WAVE_FORMAT_2S16 0x00000080 /* 22.05 kHz, Stereo, 16-bit */
228 #define WAVE_FORMAT_4M08 0x00000100 /* 44.1 kHz, Mono, 8-bit */
229 #define WAVE_FORMAT_4S08 0x00000200 /* 44.1 kHz, Stereo, 8-bit */
230 #define WAVE_FORMAT_4M16 0x00000400 /* 44.1 kHz, Mono, 16-bit */
231 #define WAVE_FORMAT_4S16 0x00000800 /* 44.1 kHz, Stereo, 16-bit */
233 /* general format structure common to all formats */
235 WORD wFormatTag
; /* format type */
236 WORD nChannels
; /* number of channels (i.e. mono, stereo, etc.) */
237 DWORD nSamplesPerSec
; /* sample rate */
238 DWORD nAvgBytesPerSec
; /* for buffer estimation */
239 WORD nBlockAlign
; /* block size of data */
241 typedef WAVEFORMAT FAR
*LPWAVEFORMAT
;
243 #define WAVE_FORMAT_PCM 1
249 typedef PCMWAVEFORMAT FAR
*LPPCMWAVEFORMAT
;
251 UINT WINAPI
waveOutGetNumDevs(void);
252 UINT WINAPI
waveOutGetDevCaps(UINT uDeviceID
, WAVEOUTCAPS FAR
* lpCaps
,
254 UINT WINAPI
waveOutGetVolume(UINT uDeviceID
, DWORD FAR
* lpdwVolume
);
255 UINT WINAPI
waveOutSetVolume(UINT uDeviceID
, DWORD dwVolume
);
256 UINT WINAPI
waveOutGetErrorText(UINT uError
, LPSTR lpText
, UINT uSize
);
257 UINT WINAPI
waveGetErrorText(UINT uError
, LPSTR lpText
, UINT uSize
);
258 UINT WINAPI
waveOutOpen(HWAVEOUT FAR
* lphWaveOut
, UINT uDeviceID
,
259 const LPWAVEFORMAT lpFormat
, DWORD dwCallback
, DWORD dwInstance
, DWORD dwFlags
);
260 UINT WINAPI
waveOutClose(HWAVEOUT hWaveOut
);
261 UINT WINAPI
waveOutPrepareHeader(HWAVEOUT hWaveOut
,
262 WAVEHDR FAR
* lpWaveOutHdr
, UINT uSize
);
263 UINT WINAPI
waveOutUnprepareHeader(HWAVEOUT hWaveOut
,
264 WAVEHDR FAR
* lpWaveOutHdr
, UINT uSize
);
265 UINT WINAPI
waveOutWrite(HWAVEOUT hWaveOut
, WAVEHDR FAR
* lpWaveOutHdr
,
267 UINT WINAPI
waveOutPause(HWAVEOUT hWaveOut
);
268 UINT WINAPI
waveOutRestart(HWAVEOUT hWaveOut
);
269 UINT WINAPI
waveOutReset(HWAVEOUT hWaveOut
);
270 UINT WINAPI
waveOutBreakLoop(HWAVEOUT hWaveOut
);
271 UINT WINAPI
waveOutGetPosition(HWAVEOUT hWaveOut
, MMTIME FAR
* lpInfo
,
273 UINT WINAPI
waveOutGetPitch(HWAVEOUT hWaveOut
, DWORD FAR
* lpdwPitch
);
274 UINT WINAPI
waveOutSetPitch(HWAVEOUT hWaveOut
, DWORD dwPitch
);
275 UINT WINAPI
waveOutGetPlaybackRate(HWAVEOUT hWaveOut
, DWORD FAR
* lpdwRate
);
276 UINT WINAPI
waveOutSetPlaybackRate(HWAVEOUT hWaveOut
, DWORD dwRate
);
277 UINT WINAPI
waveOutGetID(HWAVEOUT hWaveOut
, UINT FAR
* lpuDeviceID
);
279 DWORD WINAPI
waveOutMessage(HWAVEOUT hWaveOut
, UINT uMessage
, DWORD dw1
, DWORD dw2
);
281 UINT WINAPI
waveInGetNumDevs(void);
282 UINT WINAPI
waveInGetDevCaps(UINT uDeviceID
, WAVEINCAPS FAR
* lpCaps
,
284 UINT WINAPI
waveInGetErrorText(UINT uError
, LPSTR lpText
, UINT uSize
);
285 UINT WINAPI
waveInOpen(HWAVEIN FAR
* lphWaveIn
, UINT uDeviceID
,
286 const LPWAVEFORMAT lpFormat
, DWORD dwCallback
, DWORD dwInstance
, DWORD dwFlags
);
287 UINT WINAPI
waveInClose(HWAVEIN hWaveIn
);
288 UINT WINAPI
waveInPrepareHeader(HWAVEIN hWaveIn
,
289 WAVEHDR FAR
* lpWaveInHdr
, UINT uSize
);
290 UINT WINAPI
waveInUnprepareHeader(HWAVEIN hWaveIn
,
291 WAVEHDR FAR
* lpWaveInHdr
, UINT uSize
);
292 UINT WINAPI
waveInAddBuffer(HWAVEIN hWaveIn
,
293 WAVEHDR FAR
* lpWaveInHdr
, UINT uSize
);
294 UINT WINAPI
waveInStart(HWAVEIN hWaveIn
);
295 UINT WINAPI
waveInStop(HWAVEIN hWaveIn
);
296 UINT WINAPI
waveInReset(HWAVEIN hWaveIn
);
297 UINT WINAPI
waveInGetPosition(HWAVEIN hWaveIn
, MMTIME FAR
* lpInfo
,
299 UINT WINAPI
waveInGetID(HWAVEIN hWaveIn
, UINT FAR
* lpuDeviceID
);
301 DWORD WINAPI
waveInMessage(HWAVEIN hWaveIn
, UINT uMessage
, DWORD dw1
, DWORD dw2
);
303 #define MIDIERR_UNPREPARED (MIDIERR_BASE + 0) /* header not prepared */
304 #define MIDIERR_STILLPLAYING (MIDIERR_BASE + 1) /* still something playing */
305 #define MIDIERR_NOMAP (MIDIERR_BASE + 2) /* no current map */
306 #define MIDIERR_NOTREADY (MIDIERR_BASE + 3) /* hardware is still busy */
307 #define MIDIERR_NODEVICE (MIDIERR_BASE + 4) /* port no longer connected */
308 #define MIDIERR_INVALIDSETUP (MIDIERR_BASE + 5) /* invalid setup */
309 #define MIDIERR_LASTERROR (MIDIERR_BASE + 5) /* last error in range */
311 DECLARE_HANDLE(HMIDI
);
312 DECLARE_HANDLE(HMIDIIN
);
313 DECLARE_HANDLE(HMIDIOUT
);
314 typedef HMIDIIN FAR
*LPHMIDIIN
;
315 typedef HMIDIOUT FAR
*LPHMIDIOUT
;
316 typedef DRVCALLBACK MIDICALLBACK
;
317 typedef MIDICALLBACK FAR
*LPMIDICALLBACK
;
318 #define MIDIPATCHSIZE 128
319 typedef WORD PATCHARRAY
[MIDIPATCHSIZE
];
320 typedef WORD FAR
*LPPATCHARRAY
;
321 typedef WORD KEYARRAY
[MIDIPATCHSIZE
];
322 typedef WORD FAR
*LPKEYARRAY
;
324 #define MIM_OPEN MM_MIM_OPEN
325 #define MIM_CLOSE MM_MIM_CLOSE
326 #define MIM_DATA MM_MIM_DATA
327 #define MIM_LONGDATA MM_MIM_LONGDATA
328 #define MIM_ERROR MM_MIM_ERROR
329 #define MIM_LONGERROR MM_MIM_LONGERROR
330 #define MOM_OPEN MM_MOM_OPEN
331 #define MOM_CLOSE MM_MOM_CLOSE
332 #define MOM_DONE MM_MOM_DONE
334 #define MIDIMAPPER (-1)
335 #define MIDI_MAPPER (-1)
337 /* flags for wFlags parm of
338 midiOutCachePatches(),
339 midiOutCacheDrumPatches() */
340 #define MIDI_CACHE_ALL 1
341 #define MIDI_CACHE_BESTFIT 2
342 #define MIDI_CACHE_QUERY 3
343 #define MIDI_UNCACHE 4
346 UINT wMid
; /* manufacturer ID */
347 UINT wPid
; /* product ID */
348 VERSION vDriverVersion
; /* version of the driver */
349 char szPname
[MAXPNAMELEN
]; /* product name (NULL terminated string) */
350 UINT wTechnology
; /* type of device */
351 UINT wVoices
; /* # of voices (internal synth only) */
352 UINT wNotes
; /* max # of notes (internal synth only) */
353 UINT wChannelMask
; /* channels used (internal synth only) */
354 DWORD dwSupport
; /* functionality supported by driver */
356 typedef MIDIOUTCAPS FAR
*LPMIDIOUTCAPS
;
358 #define MOD_MIDIPORT 1 /* output port */
359 #define MOD_SYNTH 2 /* generic internal synth */
360 #define MOD_SQSYNTH 3 /* square wave internal synth */
361 #define MOD_FMSYNTH 4 /* FM internal synth */
362 #define MOD_MAPPER 5 /* MIDI mapper */
364 #define MIDICAPS_VOLUME 0x0001 /* supports volume control */
365 #define MIDICAPS_LRVOLUME 0x0002 /* separate left-right volume control */
366 #define MIDICAPS_CACHE 0x0004
369 UINT wMid
; /* manufacturer ID */
370 UINT wPid
; /* product ID */
371 VERSION vDriverVersion
; /* version of the driver */
372 char szPname
[MAXPNAMELEN
]; /* product name (NULL terminated string) */
374 typedef MIDIINCAPS FAR
*LPMIDIINCAPS
;
377 LPSTR lpData
; /* pointer to locked data block */
378 DWORD dwBufferLength
; /* length of data in data block */
379 DWORD dwBytesRecorded
; /* used for input only */
380 DWORD dwUser
; /* for client's use */
381 DWORD dwFlags
; /* assorted flags (see defines) */
382 struct midihdr_tag FAR
*lpNext
; /* reserved for driver */
383 DWORD reserved
; /* reserved for driver */
385 typedef MIDIHDR FAR
*LPMIDIHDR
;
387 #define MHDR_DONE 0x00000001 /* done bit */
388 #define MHDR_PREPARED 0x00000002 /* set if header prepared */
389 #define MHDR_INQUEUE 0x00000004 /* reserved for driver */
391 UINT WINAPI
midiOutGetNumDevs(void);
392 UINT WINAPI
midiOutGetDevCaps(UINT uDeviceID
,
393 MIDIOUTCAPS FAR
* lpCaps
, UINT uSize
);
394 UINT WINAPI
midiOutGetVolume(UINT uDeviceID
, DWORD FAR
* lpdwVolume
);
395 UINT WINAPI
midiOutSetVolume(UINT uDeviceID
, DWORD dwVolume
);
396 UINT WINAPI
midiOutGetErrorText(UINT uError
, LPSTR lpText
, UINT uSize
);
397 UINT WINAPI
midiGetErrorText(UINT uError
, LPSTR lpText
, UINT uSize
);
398 UINT WINAPI
midiOutOpen(HMIDIOUT FAR
* lphMidiOut
, UINT uDeviceID
,
399 DWORD dwCallback
, DWORD dwInstance
, DWORD dwFlags
);
400 UINT WINAPI
midiOutClose(HMIDIOUT hMidiOut
);
401 UINT WINAPI
midiOutPrepareHeader(HMIDIOUT hMidiOut
,
402 MIDIHDR FAR
* lpMidiOutHdr
, UINT uSize
);
403 UINT WINAPI
midiOutUnprepareHeader(HMIDIOUT hMidiOut
,
404 MIDIHDR FAR
* lpMidiOutHdr
, UINT uSize
);
405 UINT WINAPI
midiOutShortMsg(HMIDIOUT hMidiOut
, DWORD dwMsg
);
406 UINT WINAPI
midiOutLongMsg(HMIDIOUT hMidiOut
,
407 MIDIHDR FAR
* lpMidiOutHdr
, UINT uSize
);
408 UINT WINAPI
midiOutReset(HMIDIOUT hMidiOut
);
409 UINT WINAPI
midiOutCachePatches(HMIDIOUT hMidiOut
,
410 UINT uBank
, WORD FAR
* lpwPatchArray
, UINT uFlags
);
411 UINT WINAPI
midiOutCacheDrumPatches(HMIDIOUT hMidiOut
,
412 UINT uPatch
, WORD FAR
* lpwKeyArray
, UINT uFlags
);
413 UINT WINAPI
midiOutGetID(HMIDIOUT hMidiOut
, UINT FAR
* lpuDeviceID
);
415 DWORD WINAPI
midiOutMessage(HMIDIOUT hMidiOut
, UINT uMessage
, DWORD dw1
, DWORD dw2
);
417 UINT WINAPI
midiInGetNumDevs(void);
418 UINT WINAPI
midiInGetDevCaps(UINT uDeviceID
,
419 LPMIDIINCAPS lpCaps
, UINT uSize
);
420 UINT WINAPI
midiInGetErrorText(UINT uError
, LPSTR lpText
, UINT uSize
);
421 UINT WINAPI
midiInOpen(HMIDIIN FAR
* lphMidiIn
, UINT uDeviceID
,
422 DWORD dwCallback
, DWORD dwInstance
, DWORD dwFlags
);
423 UINT WINAPI
midiInClose(HMIDIIN hMidiIn
);
424 UINT WINAPI
midiInPrepareHeader(HMIDIIN hMidiIn
,
425 MIDIHDR FAR
* lpMidiInHdr
, UINT uSize
);
426 UINT WINAPI
midiInUnprepareHeader(HMIDIIN hMidiIn
,
427 MIDIHDR FAR
* lpMidiInHdr
, UINT uSize
);
428 UINT WINAPI
midiInAddBuffer(HMIDIIN hMidiIn
,
429 MIDIHDR FAR
* lpMidiInHdr
, UINT uSize
);
430 UINT WINAPI
midiInStart(HMIDIIN hMidiIn
);
431 UINT WINAPI
midiInStop(HMIDIIN hMidiIn
);
432 UINT WINAPI
midiInReset(HMIDIIN hMidiIn
);
433 UINT WINAPI
midiInGetID(HMIDIIN hMidiIn
, UINT FAR
* lpuDeviceID
);
435 DWORD WINAPI
midiInMessage(HMIDIIN hMidiIn
, UINT uMessage
, DWORD dw1
, DWORD dw2
);
437 #define AUX_MAPPER (-1)
440 UINT wMid
; /* manufacturer ID */
441 UINT wPid
; /* product ID */
442 VERSION vDriverVersion
; /* version of the driver */
443 char szPname
[MAXPNAMELEN
]; /* product name (NULL terminated string) */
444 UINT wTechnology
; /* type of device */
445 DWORD dwSupport
; /* functionality supported by driver */
447 typedef AUXCAPS FAR
*LPAUXCAPS
;
449 #define AUXCAPS_CDAUDIO 1 /* audio from internal CD-ROM drive */
450 #define AUXCAPS_AUXIN 2 /* audio from auxiliary input jacks */
452 #define AUXCAPS_VOLUME 0x0001 /* supports volume control */
453 #define AUXCAPS_LRVOLUME 0x0002 /* separate left-right volume control */
455 UINT WINAPI
auxGetNumDevs(void);
456 UINT WINAPI
auxGetDevCaps(UINT uDeviceID
, AUXCAPS FAR
* lpCaps
, UINT uSize
);
457 UINT WINAPI
auxSetVolume(UINT uDeviceID
, DWORD dwVolume
);
458 UINT WINAPI
auxGetVolume(UINT uDeviceID
, DWORD FAR
* lpdwVolume
);
460 DWORD WINAPI
auxOutMessage(UINT uDeviceID
, UINT uMessage
, DWORD dw1
, DWORD dw2
);
462 #define TIMERR_NOERROR (0) /* no error */
463 #define TIMERR_NOCANDO (TIMERR_BASE+1) /* request not completed */
464 #define TIMERR_STRUCT (TIMERR_BASE+33) /* time struct size */
466 typedef void (CALLBACK TIMECALLBACK
) (UINT uTimerID
, UINT uMessage
, DWORD dwUser
, DWORD dw1
, DWORD dw2
);
468 typedef TIMECALLBACK FAR
*LPTIMECALLBACK
;
470 #define TIME_ONESHOT 0 /* program timer for single event */
471 #define TIME_PERIODIC 1 /* program for continuous periodic event */
474 UINT wPeriodMin
; /* minimum period supported */
475 UINT wPeriodMax
; /* maximum period supported */
477 typedef TIMECAPS FAR
*LPTIMECAPS
;
479 UINT WINAPI
timeGetSystemTime(MMTIME FAR
* lpTime
, UINT uSize
);
480 DWORD WINAPI
timeGetTime(void);
481 UINT WINAPI
timeSetEvent(UINT uDelay
, UINT uResolution
,
482 LPTIMECALLBACK lpFunction
, DWORD dwUser
, UINT uFlags
);
483 UINT WINAPI
timeKillEvent(UINT uTimerID
);
484 UINT WINAPI
timeGetDevCaps(TIMECAPS FAR
* lpTimeCaps
, UINT uSize
);
485 UINT WINAPI
timeBeginPeriod(UINT uPeriod
);
486 UINT WINAPI
timeEndPeriod(UINT uPeriod
);
488 #define JOYERR_NOERROR (0) /* no error */
489 #define JOYERR_PARMS (JOYERR_BASE+5) /* bad parameters */
490 #define JOYERR_NOCANDO (JOYERR_BASE+6) /* request not completed */
491 #define JOYERR_UNPLUGGED (JOYERR_BASE+7) /* joystick is unplugged */
493 #define JOY_BUTTON1 0x0001
494 #define JOY_BUTTON2 0x0002
495 #define JOY_BUTTON3 0x0004
496 #define JOY_BUTTON4 0x0008
497 #define JOY_BUTTON1CHG 0x0100
498 #define JOY_BUTTON2CHG 0x0200
499 #define JOY_BUTTON3CHG 0x0400
500 #define JOY_BUTTON4CHG 0x0800
502 #define JOYSTICKID1 0
503 #define JOYSTICKID2 1
506 UINT wMid
; /* manufacturer ID */
507 UINT wPid
; /* product ID */
508 char szPname
[MAXPNAMELEN
]; /* product name (NULL terminated string) */
509 UINT wXmin
; /* minimum x position value */
510 UINT wXmax
; /* maximum x position value */
511 UINT wYmin
; /* minimum y position value */
512 UINT wYmax
; /* maximum y position value */
513 UINT wZmin
; /* minimum z position value */
514 UINT wZmax
; /* maximum z position value */
515 UINT wNumButtons
; /* number of buttons */
516 UINT wPeriodMin
; /* minimum message period when captured */
517 UINT wPeriodMax
; /* maximum message period when captured */
519 typedef JOYCAPS FAR
*LPJOYCAPS
;
522 UINT wXpos
; /* x position */
523 UINT wYpos
; /* y position */
524 UINT wZpos
; /* z position */
525 UINT wButtons
; /* button states */
527 typedef JOYINFO FAR
*LPJOYINFO
;
529 UINT WINAPI
joyGetDevCaps(UINT uJoyID
, JOYCAPS FAR
* lpCaps
, UINT uSize
);
530 UINT WINAPI
joyGetNumDevs(void);
531 UINT WINAPI
joyGetPos(UINT uJoyID
, JOYINFO FAR
* lpInfo
);
532 UINT WINAPI
joyGetThreshold(UINT uJoyID
, UINT FAR
* lpuThreshold
);
533 UINT WINAPI
joyReleaseCapture(UINT uJoyID
);
534 UINT WINAPI
joySetCapture(HWND hwnd
, UINT uJoyID
, UINT uPeriod
,
536 UINT WINAPI
joySetThreshold(UINT uJoyID
, UINT uThreshold
);
538 #define MMIOERR_BASE 256
539 #define MMIOERR_FILENOTFOUND (MMIOERR_BASE + 1) /* file not found */
540 #define MMIOERR_OUTOFMEMORY (MMIOERR_BASE + 2) /* out of memory */
541 #define MMIOERR_CANNOTOPEN (MMIOERR_BASE + 3) /* cannot open */
542 #define MMIOERR_CANNOTCLOSE (MMIOERR_BASE + 4) /* cannot close */
543 #define MMIOERR_CANNOTREAD (MMIOERR_BASE + 5) /* cannot read */
544 #define MMIOERR_CANNOTWRITE (MMIOERR_BASE + 6) /* cannot write */
545 #define MMIOERR_CANNOTSEEK (MMIOERR_BASE + 7) /* cannot seek */
546 #define MMIOERR_CANNOTEXPAND (MMIOERR_BASE + 8) /* cannot expand file */
547 #define MMIOERR_CHUNKNOTFOUND (MMIOERR_BASE + 9) /* chunk not found */
548 #define MMIOERR_UNBUFFERED (MMIOERR_BASE + 10) /* file is unbuffered */
550 #define CFSEPCHAR '+' /* compound file name separator char. */
552 typedef DWORD FOURCC
; /* a four character code */
553 DECLARE_HANDLE(HMMIO
); /* a handle to an open file */
554 typedef LRESULT (CALLBACK MMIOPROC
)(LPSTR lpmmioinfo
, UINT uMessage
,
555 LPARAM lParam1
, LPARAM lParam2
);
556 typedef MMIOPROC FAR
*LPMMIOPROC
;
559 DWORD dwFlags
; /* general status flags */
560 FOURCC fccIOProc
; /* pointer to I/O procedure */
561 LPMMIOPROC pIOProc
; /* pointer to I/O procedure */
562 UINT wErrorRet
; /* place for error to be returned */
563 HTASK htask
; /* alternate local task */
564 /* fields maintained by MMIO functions during buffered I/O */
565 LONG cchBuffer
; /* size of I/O buffer (or 0L) */
566 HPSTR pchBuffer
; /* start of I/O buffer (or NULL) */
567 HPSTR pchNext
; /* pointer to next byte to read/write */
568 HPSTR pchEndRead
; /* pointer to last valid byte to read */
569 HPSTR pchEndWrite
; /* pointer to last byte to write */
570 LONG lBufOffset
; /* disk offset of start of buffer */
571 /* fields maintained by I/O procedure */
572 LONG lDiskOffset
; /* disk offset of next read or write */
573 DWORD adwInfo
[3]; /* data specific to type of MMIOPROC */
574 /* other fields maintained by MMIO */
575 DWORD dwReserved1
; /* reserved for MMIO use */
576 DWORD dwReserved2
; /* reserved for MMIO use */
577 HMMIO hmmio
; /* handle to open file */
579 typedef MMIOINFO FAR
*LPMMIOINFO
;
581 typedef struct _MMCKINFO
583 FOURCC ckid
; /* chunk ID */
584 DWORD cksize
; /* chunk size */
585 FOURCC fccType
; /* form type or list type */
586 DWORD dwDataOffset
; /* offset of data portion of chunk */
587 DWORD dwFlags
; /* flags used by MMIO functions */
589 typedef MMCKINFO FAR
*LPMMCKINFO
;
591 #define MMIO_RWMODE 0x00000003 /* open file for reading/writing/both */
592 #define MMIO_SHAREMODE 0x00000070 /* file sharing mode number */
594 #define MMIO_CREATE 0x00001000 /* create new file (or truncate file) */
595 #define MMIO_PARSE 0x00000100 /* parse new file returning path */
596 #define MMIO_DELETE 0x00000200 /* create new file (or truncate file) */
597 #define MMIO_EXIST 0x00004000 /* checks for existence of file */
598 #define MMIO_ALLOCBUF 0x00010000 /* mmioOpen() should allocate a buffer */
599 #define MMIO_GETTEMP 0x00020000 /* mmioOpen() should retrieve temp name */
601 #define MMIO_DIRTY 0x10000000 /* I/O buffer is dirty */
603 #define MMIO_READ 0x00000000 /* open file for reading only */
604 #define MMIO_WRITE 0x00000001 /* open file for writing only */
605 #define MMIO_READWRITE 0x00000002 /* open file for reading and writing */
607 #define MMIO_COMPAT 0x00000000 /* compatibility mode */
608 #define MMIO_EXCLUSIVE 0x00000010 /* exclusive-access mode */
609 #define MMIO_DENYWRITE 0x00000020 /* deny writing to other processes */
610 #define MMIO_DENYREAD 0x00000030 /* deny reading to other processes */
611 #define MMIO_DENYNONE 0x00000040 /* deny nothing to other processes */
613 #define MMIO_FHOPEN 0x0010 /* mmioClose: keep file handle open */
614 #define MMIO_EMPTYBUF 0x0010 /* mmioFlush: empty the I/O buffer */
615 #define MMIO_TOUPPER 0x0010 /* mmioStringToFOURCC: to u-case */
616 #define MMIO_INSTALLPROC 0x00010000 /* mmioInstallIOProc: install MMIOProc */
617 #define MMIO_GLOBALPROC 0x10000000 /* mmioInstallIOProc: install globally */
618 #define MMIO_REMOVEPROC 0x00020000 /* mmioInstallIOProc: remove MMIOProc */
619 #define MMIO_FINDPROC 0x00040000 /* mmioInstallIOProc: find an MMIOProc */
620 #define MMIO_FINDCHUNK 0x0010 /* mmioDescend: find a chunk by ID */
621 #define MMIO_FINDRIFF 0x0020 /* mmioDescend: find a LIST chunk */
622 #define MMIO_FINDLIST 0x0040 /* mmioDescend: find a RIFF chunk */
623 #define MMIO_CREATERIFF 0x0020 /* mmioCreateChunk: make a LIST chunk */
624 #define MMIO_CREATELIST 0x0040 /* mmioCreateChunk: make a RIFF chunk */
630 #define MMIOM_READ MMIO_READ /* read */
631 #define MMIOM_WRITE MMIO_WRITE /* write */
632 #define MMIOM_SEEK 2 /* seek to a new position in file */
633 #define MMIOM_OPEN 3 /* open file */
634 #define MMIOM_CLOSE 4 /* close file */
635 #define MMIOM_WRITEFLUSH 5 /* write and flush */
637 #define MMIOM_RENAME 6 /* rename specified file */
639 #define MMIOM_USER 0x8000 /* beginning of user-defined messages */
641 #define FOURCC_RIFF mmioFOURCC('R', 'I', 'F', 'F')
642 #define FOURCC_LIST mmioFOURCC('L', 'I', 'S', 'T')
644 #define FOURCC_DOS mmioFOURCC('D', 'O', 'S', ' ')
645 #define FOURCC_MEM mmioFOURCC('M', 'E', 'M', ' ')
647 #define MMIO_DEFAULTBUFFER 8192 /* default buffer size */
649 #define mmioFOURCC( ch0, ch1, ch2, ch3 ) \
650 ( (DWORD)(BYTE)(ch0) | ( (DWORD)(BYTE)(ch1) << 8 ) | \
651 ( (DWORD)(BYTE)(ch2) << 16 ) | ( (DWORD)(BYTE)(ch3) << 24 ) )
653 FOURCC WINAPI
mmioStringToFOURCC(LPCSTR sz
, UINT uFlags
);
654 LPMMIOPROC WINAPI
mmioInstallIOProc(FOURCC fccIOProc
, LPMMIOPROC pIOProc
,
656 HMMIO WINAPI
mmioOpen(LPSTR szFileName
, MMIOINFO FAR
* lpmmioinfo
,
659 UINT WINAPI
mmioRename(LPCSTR szFileName
, LPCSTR szNewFileName
,
660 MMIOINFO FAR
* lpmmioinfo
, DWORD dwRenameFlags
);
662 UINT WINAPI
mmioClose(HMMIO hmmio
, UINT uFlags
);
663 LONG WINAPI
mmioRead(HMMIO hmmio
, HPSTR pch
, LONG cch
);
664 LONG WINAPI
mmioWrite(HMMIO hmmio
, HPCSTR pch
, LONG cch
);
665 LONG WINAPI
mmioSeek(HMMIO hmmio
, LONG lOffset
, int iOrigin
);
666 UINT WINAPI
mmioGetInfo(HMMIO hmmio
, MMIOINFO FAR
* lpmmioinfo
, UINT uFlags
);
667 UINT WINAPI
mmioSetInfo(HMMIO hmmio
, const MMIOINFO FAR
* lpmmioinfo
, UINT uFlags
);
668 UINT WINAPI
mmioSetBuffer(HMMIO hmmio
, LPSTR pchBuffer
, LONG cchBuffer
,
670 UINT WINAPI
mmioFlush(HMMIO hmmio
, UINT uFlags
);
671 UINT WINAPI
mmioAdvance(HMMIO hmmio
, MMIOINFO FAR
* lpmmioinfo
, UINT uFlags
);
672 LRESULT WINAPI
mmioSendMessage(HMMIO hmmio
, UINT uMessage
,
673 LPARAM lParam1
, LPARAM lParam2
);
674 UINT WINAPI
mmioDescend(HMMIO hmmio
, MMCKINFO FAR
* lpck
,
675 const MMCKINFO FAR
* lpckParent
, UINT uFlags
);
676 UINT WINAPI
mmioAscend(HMMIO hmmio
, MMCKINFO FAR
* lpck
, UINT uFlags
);
677 UINT WINAPI
mmioCreateChunk(HMMIO hmmio
, MMCKINFO FAR
* lpck
, UINT uFlags
);
679 typedef UINT (CALLBACK
*YIELDPROC
) (UINT uDeviceID
, DWORD dwYieldData
);
681 DWORD WINAPI
mciSendCommand (UINT uDeviceID
, UINT uMessage
,
682 DWORD dwParam1
, DWORD dwParam2
);
683 DWORD WINAPI
mciSendString (LPCSTR lpstrCommand
,
684 LPSTR lpstrReturnString
, UINT uReturnLength
, HWND hwndCallback
);
685 UINT WINAPI
mciGetDeviceID (LPCSTR lpstrName
);
686 UINT WINAPI
mciGetDeviceIDFromElementID (DWORD dwElementID
,
688 BOOL WINAPI
mciGetErrorString (DWORD wError
, LPSTR lpstrBuffer
,
690 BOOL WINAPI
mciSetYieldProc (UINT uDeviceID
, YIELDPROC fpYieldProc
,
693 HTASK WINAPI
mciGetCreatorTask(UINT uDeviceID
);
694 YIELDPROC WINAPI
mciGetYieldProc (UINT uDeviceID
, DWORD FAR
* lpdwYieldData
);
696 #define MCIERR_INVALID_DEVICE_ID (MCIERR_BASE + 1)
697 #define MCIERR_UNRECOGNIZED_KEYWORD (MCIERR_BASE + 3)
698 #define MCIERR_UNRECOGNIZED_COMMAND (MCIERR_BASE + 5)
699 #define MCIERR_HARDWARE (MCIERR_BASE + 6)
700 #define MCIERR_INVALID_DEVICE_NAME (MCIERR_BASE + 7)
701 #define MCIERR_OUT_OF_MEMORY (MCIERR_BASE + 8)
702 #define MCIERR_DEVICE_OPEN (MCIERR_BASE + 9)
703 #define MCIERR_CANNOT_LOAD_DRIVER (MCIERR_BASE + 10)
704 #define MCIERR_MISSING_COMMAND_STRING (MCIERR_BASE + 11)
705 #define MCIERR_PARAM_OVERFLOW (MCIERR_BASE + 12)
706 #define MCIERR_MISSING_STRING_ARGUMENT (MCIERR_BASE + 13)
707 #define MCIERR_BAD_INTEGER (MCIERR_BASE + 14)
708 #define MCIERR_PARSER_INTERNAL (MCIERR_BASE + 15)
709 #define MCIERR_DRIVER_INTERNAL (MCIERR_BASE + 16)
710 #define MCIERR_MISSING_PARAMETER (MCIERR_BASE + 17)
711 #define MCIERR_UNSUPPORTED_FUNCTION (MCIERR_BASE + 18)
712 #define MCIERR_FILE_NOT_FOUND (MCIERR_BASE + 19)
713 #define MCIERR_DEVICE_NOT_READY (MCIERR_BASE + 20)
714 #define MCIERR_INTERNAL (MCIERR_BASE + 21)
715 #define MCIERR_DRIVER (MCIERR_BASE + 22)
716 #define MCIERR_CANNOT_USE_ALL (MCIERR_BASE + 23)
717 #define MCIERR_MULTIPLE (MCIERR_BASE + 24)
718 #define MCIERR_EXTENSION_NOT_FOUND (MCIERR_BASE + 25)
719 #define MCIERR_OUTOFRANGE (MCIERR_BASE + 26)
720 #define MCIERR_FLAGS_NOT_COMPATIBLE (MCIERR_BASE + 28)
721 #define MCIERR_FILE_NOT_SAVED (MCIERR_BASE + 30)
722 #define MCIERR_DEVICE_TYPE_REQUIRED (MCIERR_BASE + 31)
723 #define MCIERR_DEVICE_LOCKED (MCIERR_BASE + 32)
724 #define MCIERR_DUPLICATE_ALIAS (MCIERR_BASE + 33)
725 #define MCIERR_BAD_CONSTANT (MCIERR_BASE + 34)
726 #define MCIERR_MUST_USE_SHAREABLE (MCIERR_BASE + 35)
727 #define MCIERR_MISSING_DEVICE_NAME (MCIERR_BASE + 36)
728 #define MCIERR_BAD_TIME_FORMAT (MCIERR_BASE + 37)
729 #define MCIERR_NO_CLOSING_QUOTE (MCIERR_BASE + 38)
730 #define MCIERR_DUPLICATE_FLAGS (MCIERR_BASE + 39)
731 #define MCIERR_INVALID_FILE (MCIERR_BASE + 40)
732 #define MCIERR_NULL_PARAMETER_BLOCK (MCIERR_BASE + 41)
733 #define MCIERR_UNNAMED_RESOURCE (MCIERR_BASE + 42)
734 #define MCIERR_NEW_REQUIRES_ALIAS (MCIERR_BASE + 43)
735 #define MCIERR_NOTIFY_ON_AUTO_OPEN (MCIERR_BASE + 44)
736 #define MCIERR_NO_ELEMENT_ALLOWED (MCIERR_BASE + 45)
737 #define MCIERR_NONAPPLICABLE_FUNCTION (MCIERR_BASE + 46)
738 #define MCIERR_ILLEGAL_FOR_AUTO_OPEN (MCIERR_BASE + 47)
739 #define MCIERR_FILENAME_REQUIRED (MCIERR_BASE + 48)
740 #define MCIERR_EXTRA_CHARACTERS (MCIERR_BASE + 49)
741 #define MCIERR_DEVICE_NOT_INSTALLED (MCIERR_BASE + 50)
742 #define MCIERR_GET_CD (MCIERR_BASE + 51)
743 #define MCIERR_SET_CD (MCIERR_BASE + 52)
744 #define MCIERR_SET_DRIVE (MCIERR_BASE + 53)
745 #define MCIERR_DEVICE_LENGTH (MCIERR_BASE + 54)
746 #define MCIERR_DEVICE_ORD_LENGTH (MCIERR_BASE + 55)
747 #define MCIERR_NO_INTEGER (MCIERR_BASE + 56)
749 #define MCIERR_WAVE_OUTPUTSINUSE (MCIERR_BASE + 64)
750 #define MCIERR_WAVE_SETOUTPUTINUSE (MCIERR_BASE + 65)
751 #define MCIERR_WAVE_INPUTSINUSE (MCIERR_BASE + 66)
752 #define MCIERR_WAVE_SETINPUTINUSE (MCIERR_BASE + 67)
753 #define MCIERR_WAVE_OUTPUTUNSPECIFIED (MCIERR_BASE + 68)
754 #define MCIERR_WAVE_INPUTUNSPECIFIED (MCIERR_BASE + 69)
755 #define MCIERR_WAVE_OUTPUTSUNSUITABLE (MCIERR_BASE + 70)
756 #define MCIERR_WAVE_SETOUTPUTUNSUITABLE (MCIERR_BASE + 71)
757 #define MCIERR_WAVE_INPUTSUNSUITABLE (MCIERR_BASE + 72)
758 #define MCIERR_WAVE_SETINPUTUNSUITABLE (MCIERR_BASE + 73)
760 #define MCIERR_SEQ_DIV_INCOMPATIBLE (MCIERR_BASE + 80)
761 #define MCIERR_SEQ_PORT_INUSE (MCIERR_BASE + 81)
762 #define MCIERR_SEQ_PORT_NONEXISTENT (MCIERR_BASE + 82)
763 #define MCIERR_SEQ_PORT_MAPNODEVICE (MCIERR_BASE + 83)
764 #define MCIERR_SEQ_PORT_MISCERROR (MCIERR_BASE + 84)
765 #define MCIERR_SEQ_TIMER (MCIERR_BASE + 85)
766 #define MCIERR_SEQ_PORTUNSPECIFIED (MCIERR_BASE + 86)
767 #define MCIERR_SEQ_NOMIDIPRESENT (MCIERR_BASE + 87)
769 #define MCIERR_NO_WINDOW (MCIERR_BASE + 90)
770 #define MCIERR_CREATEWINDOW (MCIERR_BASE + 91)
771 #define MCIERR_FILE_READ (MCIERR_BASE + 92)
772 #define MCIERR_FILE_WRITE (MCIERR_BASE + 93)
774 #define MCIERR_CUSTOM_DRIVER_BASE (MCIERR_BASE + 256)
776 #define MCI_OPEN_DRIVER 0x0801
777 #define MCI_CLOSE_DRIVER 0x0802
778 #define MCI_OPEN 0x0803
779 #define MCI_CLOSE 0x0804
780 #define MCI_ESCAPE 0x0805
781 #define MCI_PLAY 0x0806
782 #define MCI_SEEK 0x0807
783 #define MCI_STOP 0x0808
784 #define MCI_PAUSE 0x0809
785 #define MCI_INFO 0x080A
786 #define MCI_GETDEVCAPS 0x080B
787 #define MCI_SPIN 0x080C
788 #define MCI_SET 0x080D
789 #define MCI_STEP 0x080E
790 #define MCI_RECORD 0x080F
791 #define MCI_SYSINFO 0x0810
792 #define MCI_BREAK 0x0811
793 #define MCI_SOUND 0x0812
794 #define MCI_SAVE 0x0813
795 #define MCI_STATUS 0x0814
796 #define MCI_CUE 0x0830
797 #define MCI_REALIZE 0x0840
798 #define MCI_WINDOW 0x0841
799 #define MCI_PUT 0x0842
800 #define MCI_WHERE 0x0843
801 #define MCI_FREEZE 0x0844
802 #define MCI_UNFREEZE 0x0845
803 #define MCI_LOAD 0x0850
804 #define MCI_CUT 0x0851
805 #define MCI_COPY 0x0852
806 #define MCI_PASTE 0x0853
807 #define MCI_UPDATE 0x0854
808 #define MCI_RESUME 0x0855
809 #define MCI_DELETE 0x0856
811 #define MCI_USER_MESSAGES (0x400 + DRV_MCI_FIRST)
813 #define MCI_ALL_DEVICE_ID 0xFFFF
815 #define MCI_DEVTYPE_VCR (MCI_STRING_OFFSET + 1)
816 #define MCI_DEVTYPE_VIDEODISC (MCI_STRING_OFFSET + 2)
817 #define MCI_DEVTYPE_OVERLAY (MCI_STRING_OFFSET + 3)
818 #define MCI_DEVTYPE_CD_AUDIO (MCI_STRING_OFFSET + 4)
819 #define MCI_DEVTYPE_DAT (MCI_STRING_OFFSET + 5)
820 #define MCI_DEVTYPE_SCANNER (MCI_STRING_OFFSET + 6)
821 #define MCI_DEVTYPE_ANIMATION (MCI_STRING_OFFSET + 7)
822 #define MCI_DEVTYPE_DIGITAL_VIDEO (MCI_STRING_OFFSET + 8)
823 #define MCI_DEVTYPE_OTHER (MCI_STRING_OFFSET + 9)
824 #define MCI_DEVTYPE_WAVEFORM_AUDIO (MCI_STRING_OFFSET + 10)
825 #define MCI_DEVTYPE_SEQUENCER (MCI_STRING_OFFSET + 11)
827 #define MCI_DEVTYPE_FIRST MCI_DEVTYPE_VCR
828 #define MCI_DEVTYPE_LAST MCI_DEVTYPE_SEQUENCER
830 #define MCI_MODE_NOT_READY (MCI_STRING_OFFSET + 12)
831 #define MCI_MODE_STOP (MCI_STRING_OFFSET + 13)
832 #define MCI_MODE_PLAY (MCI_STRING_OFFSET + 14)
833 #define MCI_MODE_RECORD (MCI_STRING_OFFSET + 15)
834 #define MCI_MODE_SEEK (MCI_STRING_OFFSET + 16)
835 #define MCI_MODE_PAUSE (MCI_STRING_OFFSET + 17)
836 #define MCI_MODE_OPEN (MCI_STRING_OFFSET + 18)
838 #define MCI_FORMAT_MILLISECONDS 0
839 #define MCI_FORMAT_HMS 1
840 #define MCI_FORMAT_MSF 2
841 #define MCI_FORMAT_FRAMES 3
842 #define MCI_FORMAT_SMPTE_24 4
843 #define MCI_FORMAT_SMPTE_25 5
844 #define MCI_FORMAT_SMPTE_30 6
845 #define MCI_FORMAT_SMPTE_30DROP 7
846 #define MCI_FORMAT_BYTES 8
847 #define MCI_FORMAT_SAMPLES 9
848 #define MCI_FORMAT_TMSF 10
850 #define MCI_MSF_MINUTE(msf) ((BYTE)(msf))
851 #define MCI_MSF_SECOND(msf) ((BYTE)(((WORD)(msf)) >> 8))
852 #define MCI_MSF_FRAME(msf) ((BYTE)((msf)>>16))
854 #define MCI_MAKE_MSF(m, s, f) ((DWORD)(((BYTE)(m) | \
856 (((DWORD)(BYTE)(f))<<16)))
858 #define MCI_TMSF_TRACK(tmsf) ((BYTE)(tmsf))
859 #define MCI_TMSF_MINUTE(tmsf) ((BYTE)(((WORD)(tmsf)) >> 8))
860 #define MCI_TMSF_SECOND(tmsf) ((BYTE)((tmsf)>>16))
861 #define MCI_TMSF_FRAME(tmsf) ((BYTE)((tmsf)>>24))
863 #define MCI_MAKE_TMSF(t, m, s, f) ((DWORD)(((BYTE)(t) | \
865 (((DWORD)(BYTE)(s) | \
866 ((WORD)(f)<<8))<<16)))
868 #define MCI_HMS_HOUR(hms) ((BYTE)(hms))
869 #define MCI_HMS_MINUTE(hms) ((BYTE)(((WORD)(hms)) >> 8))
870 #define MCI_HMS_SECOND(hms) ((BYTE)((hms)>>16))
872 #define MCI_MAKE_HMS(h, m, s) ((DWORD)(((BYTE)(h) | \
874 (((DWORD)(BYTE)(s))<<16)))
876 #define MCI_NOTIFY_SUCCESSFUL 0x0001
877 #define MCI_NOTIFY_SUPERSEDED 0x0002
878 #define MCI_NOTIFY_ABORTED 0x0004
879 #define MCI_NOTIFY_FAILURE 0x0008
881 #define MCI_NOTIFY 0x00000001L
882 #define MCI_WAIT 0x00000002L
883 #define MCI_FROM 0x00000004L
884 #define MCI_TO 0x00000008L
885 #define MCI_TRACK 0x00000010L
887 #define MCI_OPEN_SHAREABLE 0x00000100L
888 #define MCI_OPEN_ELEMENT 0x00000200L
889 #define MCI_OPEN_ALIAS 0x00000400L
890 #define MCI_OPEN_ELEMENT_ID 0x00000800L
891 #define MCI_OPEN_TYPE_ID 0x00001000L
892 #define MCI_OPEN_TYPE 0x00002000L
894 #define MCI_SEEK_TO_START 0x00000100L
895 #define MCI_SEEK_TO_END 0x00000200L
897 #define MCI_STATUS_ITEM 0x00000100L
898 #define MCI_STATUS_START 0x00000200L
900 #define MCI_STATUS_LENGTH 0x00000001L
901 #define MCI_STATUS_POSITION 0x00000002L
902 #define MCI_STATUS_NUMBER_OF_TRACKS 0x00000003L
903 #define MCI_STATUS_MODE 0x00000004L
904 #define MCI_STATUS_MEDIA_PRESENT 0x00000005L
905 #define MCI_STATUS_TIME_FORMAT 0x00000006L
906 #define MCI_STATUS_READY 0x00000007L
907 #define MCI_STATUS_CURRENT_TRACK 0x00000008L
909 #define MCI_INFO_PRODUCT 0x00000100L
910 #define MCI_INFO_FILE 0x00000200L
912 #define MCI_GETDEVCAPS_ITEM 0x00000100L
914 #define MCI_GETDEVCAPS_CAN_RECORD 0x00000001L
915 #define MCI_GETDEVCAPS_HAS_AUDIO 0x00000002L
916 #define MCI_GETDEVCAPS_HAS_VIDEO 0x00000003L
917 #define MCI_GETDEVCAPS_DEVICE_TYPE 0x00000004L
918 #define MCI_GETDEVCAPS_USES_FILES 0x00000005L
919 #define MCI_GETDEVCAPS_COMPOUND_DEVICE 0x00000006L
920 #define MCI_GETDEVCAPS_CAN_EJECT 0x00000007L
921 #define MCI_GETDEVCAPS_CAN_PLAY 0x00000008L
922 #define MCI_GETDEVCAPS_CAN_SAVE 0x00000009L
924 #define MCI_SYSINFO_QUANTITY 0x00000100L
925 #define MCI_SYSINFO_OPEN 0x00000200L
926 #define MCI_SYSINFO_NAME 0x00000400L
927 #define MCI_SYSINFO_INSTALLNAME 0x00000800L
929 #define MCI_SET_DOOR_OPEN 0x00000100L
930 #define MCI_SET_DOOR_CLOSED 0x00000200L
931 #define MCI_SET_TIME_FORMAT 0x00000400L
932 #define MCI_SET_AUDIO 0x00000800L
933 #define MCI_SET_VIDEO 0x00001000L
934 #define MCI_SET_ON 0x00002000L
935 #define MCI_SET_OFF 0x00004000L
937 #define MCI_SET_AUDIO_ALL 0x00000000L
938 #define MCI_SET_AUDIO_LEFT 0x00000001L
939 #define MCI_SET_AUDIO_RIGHT 0x00000002L
941 #define MCI_BREAK_KEY 0x00000100L
942 #define MCI_BREAK_HWND 0x00000200L
943 #define MCI_BREAK_OFF 0x00000400L
945 #define MCI_RECORD_INSERT 0x00000100L
946 #define MCI_RECORD_OVERWRITE 0x00000200L
948 #define MCI_SOUND_NAME 0x00000100L
950 #define MCI_SAVE_FILE 0x00000100L
952 #define MCI_LOAD_FILE 0x00000100L
957 typedef MCI_GENERIC_PARMS FAR
*LPMCI_GENERIC_PARMS
;
963 LPCSTR lpstrDeviceType
;
964 LPCSTR lpstrElementName
;
967 typedef MCI_OPEN_PARMS FAR
*LPMCI_OPEN_PARMS
;
974 typedef MCI_PLAY_PARMS FAR
*LPMCI_PLAY_PARMS
;
980 typedef MCI_SEEK_PARMS FAR
*LPMCI_SEEK_PARMS
;
988 typedef MCI_STATUS_PARMS FAR
* LPMCI_STATUS_PARMS
;
995 typedef MCI_INFO_PARMS FAR
* LPMCI_INFO_PARMS
;
1001 } MCI_GETDEVCAPS_PARMS
;
1002 typedef MCI_GETDEVCAPS_PARMS FAR
* LPMCI_GETDEVCAPS_PARMS
;
1011 } MCI_SYSINFO_PARMS
;
1012 typedef MCI_SYSINFO_PARMS FAR
* LPMCI_SYSINFO_PARMS
;
1019 typedef MCI_SET_PARMS FAR
*LPMCI_SET_PARMS
;
1028 typedef MCI_BREAK_PARMS FAR
* LPMCI_BREAK_PARMS
;
1032 LPCSTR lpstrSoundName
;
1034 typedef MCI_SOUND_PARMS FAR
* LPMCI_SOUND_PARMS
;
1040 typedef MCI_SAVE_PARMS FAR
* LPMCI_SAVE_PARMS
;
1046 typedef MCI_LOAD_PARMS FAR
* LPMCI_LOAD_PARMS
;
1053 typedef MCI_RECORD_PARMS FAR
*LPMCI_RECORD_PARMS
;
1055 #define MCI_VD_MODE_PARK (MCI_VD_OFFSET + 1)
1057 #define MCI_VD_MEDIA_CLV (MCI_VD_OFFSET + 2)
1058 #define MCI_VD_MEDIA_CAV (MCI_VD_OFFSET + 3)
1059 #define MCI_VD_MEDIA_OTHER (MCI_VD_OFFSET + 4)
1061 #define MCI_VD_FORMAT_TRACK 0x4001
1063 #define MCI_VD_PLAY_REVERSE 0x00010000L
1064 #define MCI_VD_PLAY_FAST 0x00020000L
1065 #define MCI_VD_PLAY_SPEED 0x00040000L
1066 #define MCI_VD_PLAY_SCAN 0x00080000L
1067 #define MCI_VD_PLAY_SLOW 0x00100000L
1069 #define MCI_VD_SEEK_REVERSE 0x00010000L
1071 #define MCI_VD_STATUS_SPEED 0x00004002L
1072 #define MCI_VD_STATUS_FORWARD 0x00004003L
1073 #define MCI_VD_STATUS_MEDIA_TYPE 0x00004004L
1074 #define MCI_VD_STATUS_SIDE 0x00004005L
1075 #define MCI_VD_STATUS_DISC_SIZE 0x00004006L
1077 #define MCI_VD_GETDEVCAPS_CLV 0x00010000L
1078 #define MCI_VD_GETDEVCAPS_CAV 0x00020000L
1080 #define MCI_VD_SPIN_UP 0x00010000L
1081 #define MCI_VD_SPIN_DOWN 0x00020000L
1083 #define MCI_VD_GETDEVCAPS_CAN_REVERSE 0x00004002L
1084 #define MCI_VD_GETDEVCAPS_FAST_RATE 0x00004003L
1085 #define MCI_VD_GETDEVCAPS_SLOW_RATE 0x00004004L
1086 #define MCI_VD_GETDEVCAPS_NORMAL_RATE 0x00004005L
1088 #define MCI_VD_STEP_FRAMES 0x00010000L
1089 #define MCI_VD_STEP_REVERSE 0x00020000L
1091 #define MCI_VD_ESCAPE_STRING 0x00000100L
1098 } MCI_VD_PLAY_PARMS
;
1099 typedef MCI_VD_PLAY_PARMS FAR
*LPMCI_VD_PLAY_PARMS
;
1104 } MCI_VD_STEP_PARMS
;
1105 typedef MCI_VD_STEP_PARMS FAR
*LPMCI_VD_STEP_PARMS
;
1109 LPCSTR lpstrCommand
;
1110 } MCI_VD_ESCAPE_PARMS
;
1111 typedef MCI_VD_ESCAPE_PARMS FAR
*LPMCI_VD_ESCAPE_PARMS
;
1113 #define MCI_WAVE_OPEN_BUFFER 0x00010000L
1115 #define MCI_WAVE_SET_FORMATTAG 0x00010000L
1116 #define MCI_WAVE_SET_CHANNELS 0x00020000L
1117 #define MCI_WAVE_SET_SAMPLESPERSEC 0x00040000L
1118 #define MCI_WAVE_SET_AVGBYTESPERSEC 0x00080000L
1119 #define MCI_WAVE_SET_BLOCKALIGN 0x00100000L
1120 #define MCI_WAVE_SET_BITSPERSAMPLE 0x00200000L
1122 #define MCI_WAVE_INPUT 0x00400000L
1123 #define MCI_WAVE_OUTPUT 0x00800000L
1125 #define MCI_WAVE_STATUS_FORMATTAG 0x00004001L
1126 #define MCI_WAVE_STATUS_CHANNELS 0x00004002L
1127 #define MCI_WAVE_STATUS_SAMPLESPERSEC 0x00004003L
1128 #define MCI_WAVE_STATUS_AVGBYTESPERSEC 0x00004004L
1129 #define MCI_WAVE_STATUS_BLOCKALIGN 0x00004005L
1130 #define MCI_WAVE_STATUS_BITSPERSAMPLE 0x00004006L
1131 #define MCI_WAVE_STATUS_LEVEL 0x00004007L
1133 #define MCI_WAVE_SET_ANYINPUT 0x04000000L
1134 #define MCI_WAVE_SET_ANYOUTPUT 0x08000000L
1136 #define MCI_WAVE_GETDEVCAPS_INPUTS 0x00004001L
1137 #define MCI_WAVE_GETDEVCAPS_OUTPUTS 0x00004002L
1143 LPCSTR lpstrDeviceType
;
1144 LPCSTR lpstrElementName
;
1146 DWORD dwBufferSeconds
;
1147 } MCI_WAVE_OPEN_PARMS
;
1148 typedef MCI_WAVE_OPEN_PARMS FAR
*LPMCI_WAVE_OPEN_PARMS
;
1154 } MCI_WAVE_DELETE_PARMS
;
1155 typedef MCI_WAVE_DELETE_PARMS FAR
*LPMCI_WAVE_DELETE_PARMS
;
1169 DWORD nSamplesPerSec
;
1170 DWORD nAvgBytesPerSec
;
1173 UINT wBitsPerSample
;
1175 } MCI_WAVE_SET_PARMS
;
1176 typedef MCI_WAVE_SET_PARMS FAR
* LPMCI_WAVE_SET_PARMS
;
1178 #define MCI_SEQ_DIV_PPQN (0 + MCI_SEQ_OFFSET)
1179 #define MCI_SEQ_DIV_SMPTE_24 (1 + MCI_SEQ_OFFSET)
1180 #define MCI_SEQ_DIV_SMPTE_25 (2 + MCI_SEQ_OFFSET)
1181 #define MCI_SEQ_DIV_SMPTE_30DROP (3 + MCI_SEQ_OFFSET)
1182 #define MCI_SEQ_DIV_SMPTE_30 (4 + MCI_SEQ_OFFSET)
1184 #define MCI_SEQ_FORMAT_SONGPTR 0x4001
1185 #define MCI_SEQ_FILE 0x4002
1186 #define MCI_SEQ_MIDI 0x4003
1187 #define MCI_SEQ_SMPTE 0x4004
1188 #define MCI_SEQ_NONE 65533
1190 #define MCI_SEQ_STATUS_TEMPO 0x00004002L
1191 #define MCI_SEQ_STATUS_PORT 0x00004003L
1192 #define MCI_SEQ_STATUS_SLAVE 0x00004007L
1193 #define MCI_SEQ_STATUS_MASTER 0x00004008L
1194 #define MCI_SEQ_STATUS_OFFSET 0x00004009L
1195 #define MCI_SEQ_STATUS_DIVTYPE 0x0000400AL
1197 #define MCI_SEQ_SET_TEMPO 0x00010000L
1198 #define MCI_SEQ_SET_PORT 0x00020000L
1199 #define MCI_SEQ_SET_SLAVE 0x00040000L
1200 #define MCI_SEQ_SET_MASTER 0x00080000L
1201 #define MCI_SEQ_SET_OFFSET 0x01000000L
1212 } MCI_SEQ_SET_PARMS
;
1213 typedef MCI_SEQ_SET_PARMS FAR
* LPMCI_SEQ_SET_PARMS
;
1215 #define MCI_ANIM_OPEN_WS 0x00010000L
1216 #define MCI_ANIM_OPEN_PARENT 0x00020000L
1217 #define MCI_ANIM_OPEN_NOSTATIC 0x00040000L
1219 #define MCI_ANIM_PLAY_SPEED 0x00010000L
1220 #define MCI_ANIM_PLAY_REVERSE 0x00020000L
1221 #define MCI_ANIM_PLAY_FAST 0x00040000L
1222 #define MCI_ANIM_PLAY_SLOW 0x00080000L
1223 #define MCI_ANIM_PLAY_SCAN 0x00100000L
1225 #define MCI_ANIM_STEP_REVERSE 0x00010000L
1226 #define MCI_ANIM_STEP_FRAMES 0x00020000L
1228 #define MCI_ANIM_STATUS_SPEED 0x00004001L
1229 #define MCI_ANIM_STATUS_FORWARD 0x00004002L
1230 #define MCI_ANIM_STATUS_HWND 0x00004003L
1231 #define MCI_ANIM_STATUS_HPAL 0x00004004L
1232 #define MCI_ANIM_STATUS_STRETCH 0x00004005L
1234 #define MCI_ANIM_INFO_TEXT 0x00010000L
1236 #define MCI_ANIM_GETDEVCAPS_CAN_REVERSE 0x00004001L
1237 #define MCI_ANIM_GETDEVCAPS_FAST_RATE 0x00004002L
1238 #define MCI_ANIM_GETDEVCAPS_SLOW_RATE 0x00004003L
1239 #define MCI_ANIM_GETDEVCAPS_NORMAL_RATE 0x00004004L
1240 #define MCI_ANIM_GETDEVCAPS_PALETTES 0x00004006L
1241 #define MCI_ANIM_GETDEVCAPS_CAN_STRETCH 0x00004007L
1242 #define MCI_ANIM_GETDEVCAPS_MAX_WINDOWS 0x00004008L
1244 #define MCI_ANIM_REALIZE_NORM 0x00010000L
1245 #define MCI_ANIM_REALIZE_BKGD 0x00020000L
1247 #define MCI_ANIM_WINDOW_HWND 0x00010000L
1248 #define MCI_ANIM_WINDOW_STATE 0x00040000L
1249 #define MCI_ANIM_WINDOW_TEXT 0x00080000L
1250 #define MCI_ANIM_WINDOW_ENABLE_STRETCH 0x00100000L
1251 #define MCI_ANIM_WINDOW_DISABLE_STRETCH 0x00200000L
1253 #define MCI_ANIM_WINDOW_DEFAULT 0x00000000L
1255 #define MCI_ANIM_RECT 0x00010000L
1256 #define MCI_ANIM_PUT_SOURCE 0x00020000L
1257 #define MCI_ANIM_PUT_DESTINATION 0x00040000L
1259 #define MCI_ANIM_WHERE_SOURCE 0x00020000L
1260 #define MCI_ANIM_WHERE_DESTINATION 0x00040000L
1262 #define MCI_ANIM_UPDATE_HDC 0x00020000L
1268 LPCSTR lpstrDeviceType
;
1269 LPCSTR lpstrElementName
;
1274 } MCI_ANIM_OPEN_PARMS
;
1275 typedef MCI_ANIM_OPEN_PARMS FAR
*LPMCI_ANIM_OPEN_PARMS
;
1282 } MCI_ANIM_PLAY_PARMS
;
1283 typedef MCI_ANIM_PLAY_PARMS FAR
*LPMCI_ANIM_PLAY_PARMS
;
1288 } MCI_ANIM_STEP_PARMS
;
1289 typedef MCI_ANIM_STEP_PARMS FAR
*LPMCI_ANIM_STEP_PARMS
;
1298 } MCI_ANIM_WINDOW_PARMS
;
1299 typedef MCI_ANIM_WINDOW_PARMS FAR
* LPMCI_ANIM_WINDOW_PARMS
;
1303 #ifdef MCI_USE_OFFEXT
1306 #else /* ifdef MCI_USE_OFFEXT */
1308 #endif /* ifdef MCI_USE_OFFEXT */
1309 } MCI_ANIM_RECT_PARMS
;
1310 typedef MCI_ANIM_RECT_PARMS FAR
* LPMCI_ANIM_RECT_PARMS
;
1316 } MCI_ANIM_UPDATE_PARMS
;
1317 typedef MCI_ANIM_UPDATE_PARMS FAR
* LPMCI_ANIM_UPDATE_PARMS
;
1319 #define MCI_OVLY_OPEN_WS 0x00010000L
1320 #define MCI_OVLY_OPEN_PARENT 0x00020000L
1322 #define MCI_OVLY_STATUS_HWND 0x00004001L
1323 #define MCI_OVLY_STATUS_STRETCH 0x00004002L
1325 #define MCI_OVLY_INFO_TEXT 0x00010000L
1327 #define MCI_OVLY_GETDEVCAPS_CAN_STRETCH 0x00004001L
1328 #define MCI_OVLY_GETDEVCAPS_CAN_FREEZE 0x00004002L
1329 #define MCI_OVLY_GETDEVCAPS_MAX_WINDOWS 0x00004003L
1331 #define MCI_OVLY_WINDOW_HWND 0x00010000L
1332 #define MCI_OVLY_WINDOW_STATE 0x00040000L
1333 #define MCI_OVLY_WINDOW_TEXT 0x00080000L
1334 #define MCI_OVLY_WINDOW_ENABLE_STRETCH 0x00100000L
1335 #define MCI_OVLY_WINDOW_DISABLE_STRETCH 0x00200000L
1337 #define MCI_OVLY_WINDOW_DEFAULT 0x00000000L
1339 #define MCI_OVLY_RECT 0x00010000L
1340 #define MCI_OVLY_PUT_SOURCE 0x00020000L
1341 #define MCI_OVLY_PUT_DESTINATION 0x00040000L
1342 #define MCI_OVLY_PUT_FRAME 0x00080000L
1343 #define MCI_OVLY_PUT_VIDEO 0x00100000L
1345 #define MCI_OVLY_WHERE_SOURCE 0x00020000L
1346 #define MCI_OVLY_WHERE_DESTINATION 0x00040000L
1347 #define MCI_OVLY_WHERE_FRAME 0x00080000L
1348 #define MCI_OVLY_WHERE_VIDEO 0x00100000L
1354 LPCSTR lpstrDeviceType
;
1355 LPCSTR lpstrElementName
;
1360 } MCI_OVLY_OPEN_PARMS
;
1361 typedef MCI_OVLY_OPEN_PARMS FAR
*LPMCI_OVLY_OPEN_PARMS
;
1370 } MCI_OVLY_WINDOW_PARMS
;
1371 typedef MCI_OVLY_WINDOW_PARMS FAR
* LPMCI_OVLY_WINDOW_PARMS
;
1375 #ifdef MCI_USE_OFFEXT
1378 #else /* ifdef MCI_USE_OFFEXT */
1380 #endif /* ifdef MCI_USE_OFFEXT */
1381 } MCI_OVLY_RECT_PARMS
;
1382 typedef MCI_OVLY_RECT_PARMS FAR
* LPMCI_OVLY_RECT_PARMS
;
1388 } MCI_OVLY_SAVE_PARMS
;
1389 typedef MCI_OVLY_SAVE_PARMS FAR
* LPMCI_OVLY_SAVE_PARMS
;
1395 } MCI_OVLY_LOAD_PARMS
;
1396 typedef MCI_OVLY_LOAD_PARMS FAR
* LPMCI_OVLY_LOAD_PARMS
;
1399 /**************************************************************
1400 * Linux MMSYSTEM Internals & Sample Audio Drivers
1403 #define DRVM_INIT 100
1404 #define WODM_INIT DRVM_INIT
1405 #define WIDM_INIT DRVM_INIT
1406 #define MODM_INIT DRVM_INIT
1407 #define MIDM_INIT DRVM_INIT
1408 #define AUXM_INIT DRVM_INIT
1410 #define WODM_GETNUMDEVS 3
1411 #define WODM_GETDEVCAPS 4
1413 #define WODM_CLOSE 6
1414 #define WODM_PREPARE 7
1415 #define WODM_UNPREPARE 8
1416 #define WODM_WRITE 9
1417 #define WODM_PAUSE 10
1418 #define WODM_RESTART 11
1419 #define WODM_RESET 12
1420 #define WODM_GETPOS 13
1421 #define WODM_GETPITCH 14
1422 #define WODM_SETPITCH 15
1423 #define WODM_GETVOLUME 16
1424 #define WODM_SETVOLUME 17
1425 #define WODM_GETPLAYBACKRATE 18
1426 #define WODM_SETPLAYBACKRATE 19
1427 #define WODM_BREAKLOOP 20
1429 #define WIDM_GETNUMDEVS 50
1430 #define WIDM_GETDEVCAPS 51
1431 #define WIDM_OPEN 52
1432 #define WIDM_CLOSE 53
1433 #define WIDM_PREPARE 54
1434 #define WIDM_UNPREPARE 55
1435 #define WIDM_ADDBUFFER 56
1436 #define WIDM_START 57
1437 #define WIDM_STOP 58
1438 #define WIDM_RESET 59
1439 #define WIDM_GETPOS 60
1441 #define MODM_GETNUMDEVS 1
1442 #define MODM_GETDEVCAPS 2
1444 #define MODM_CLOSE 4
1445 #define MODM_PREPARE 5
1446 #define MODM_UNPREPARE 6
1448 #define MODM_LONGDATA 8
1449 #define MODM_RESET 9
1450 #define MODM_GETVOLUME 10
1451 #define MODM_SETVOLUME 11
1452 #define MODM_CACHEPATCHES 12
1453 #define MODM_CACHEDRUMPATCHES 13
1455 #define MIDM_GETNUMDEVS 53
1456 #define MIDM_GETDEVCAPS 54
1457 #define MIDM_OPEN 55
1458 #define MIDM_CLOSE 56
1459 #define MIDM_PREPARE 57
1460 #define MIDM_UNPREPARE 58
1461 #define MIDM_ADDBUFFER 59
1462 #define MIDM_START 60
1463 #define MIDM_STOP 61
1464 #define MIDM_RESET 62
1466 #define AUXDM_GETNUMDEVS 3
1467 #define AUXDM_GETDEVCAPS 4
1468 #define AUXDM_GETVOLUME 5
1469 #define AUXDM_SETVOLUME 6
1471 #define MCI_MAX_DEVICE_TYPE_LENGTH 80
1473 #define MCI_FALSE (MCI_STRING_OFFSET + 19)
1474 #define MCI_TRUE (MCI_STRING_OFFSET + 20)
1476 #define MCI_FORMAT_RETURN_BASE MCI_FORMAT_MILLISECONDS_S
1477 #define MCI_FORMAT_MILLISECONDS_S (MCI_STRING_OFFSET + 21)
1478 #define MCI_FORMAT_HMS_S (MCI_STRING_OFFSET + 22)
1479 #define MCI_FORMAT_MSF_S (MCI_STRING_OFFSET + 23)
1480 #define MCI_FORMAT_FRAMES_S (MCI_STRING_OFFSET + 24)
1481 #define MCI_FORMAT_SMPTE_24_S (MCI_STRING_OFFSET + 25)
1482 #define MCI_FORMAT_SMPTE_25_S (MCI_STRING_OFFSET + 26)
1483 #define MCI_FORMAT_SMPTE_30_S (MCI_STRING_OFFSET + 27)
1484 #define MCI_FORMAT_SMPTE_30DROP_S (MCI_STRING_OFFSET + 28)
1485 #define MCI_FORMAT_BYTES_S (MCI_STRING_OFFSET + 29)
1486 #define MCI_FORMAT_SAMPLES_S (MCI_STRING_OFFSET + 30)
1487 #define MCI_FORMAT_TMSF_S (MCI_STRING_OFFSET + 31)
1489 #define MCI_VD_FORMAT_TRACK_S (MCI_VD_OFFSET + 5)
1491 #define WAVE_FORMAT_PCM_S (MCI_WAVE_OFFSET + 0)
1492 #define WAVE_MAPPER_S (MCI_WAVE_OFFSET + 1)
1494 #define MCI_SEQ_MAPPER_S (MCI_SEQ_OFFSET + 5)
1495 #define MCI_SEQ_FILE_S (MCI_SEQ_OFFSET + 6)
1496 #define MCI_SEQ_MIDI_S (MCI_SEQ_OFFSET + 7)
1497 #define MCI_SEQ_SMPTE_S (MCI_SEQ_OFFSET + 8)
1498 #define MCI_SEQ_FORMAT_SONGPTR_S (MCI_SEQ_OFFSET + 9)
1499 #define MCI_SEQ_NONE_S (MCI_SEQ_OFFSET + 10)
1500 #define MIDIMAPPER_S (MCI_SEQ_OFFSET + 11)
1502 #define MCI_RESOURCE_RETURNED 0x00010000 /* resource ID */
1503 #define MCI_COLONIZED3_RETURN 0x00020000 /* colonized ID, 3 bytes data */
1504 #define MCI_COLONIZED4_RETURN 0x00040000 /* colonized ID, 4 bytes data */
1505 #define MCI_INTEGER_RETURNED 0x00080000 /* integer conversion needed */
1506 #define MCI_RESOURCE_DRIVER 0x00100000 /* driver owns returned resource */
1508 #define MCI_NO_COMMAND_TABLE 0xFFFF
1510 #define MCI_COMMAND_HEAD 0
1511 #define MCI_STRING 1
1512 #define MCI_INTEGER 2
1513 #define MCI_END_COMMAND 3
1514 #define MCI_RETURN 4
1516 #define MCI_END_COMMAND_LIST 6
1518 #define MCI_CONSTANT 8
1519 #define MCI_END_CONSTANT 9
1521 #define MAKEMCIRESOURCE(wRet, wRes) MAKELRESULT((wRet), (wRes))
1529 typedef PORTALLOC FAR
*LPPORTALLOC
;
1533 LPWAVEFORMAT lpFormat
;
1537 typedef WAVEOPENDESC FAR
*LPWAVEOPENDESC
;
1544 typedef MIDIOPENDESC FAR
*LPMIDIOPENDESC
;
1549 LPTIMECALLBACK lpFunction
;
1553 typedef TIMEREVENT FAR
*LPTIMEREVENT
;
1556 UINT wDeviceID
; /* device ID */
1557 LPSTR lpstrParams
; /* parameter string for entry in SYSTEM.INI */
1558 UINT wCustomCommandTable
; /* custom command table (0xFFFF if none) */
1559 /* filled in by the driver */
1560 UINT wType
; /* driver type */
1561 /* filled in by the driver */
1562 } MCI_OPEN_DRIVER_PARMS
;
1563 typedef MCI_OPEN_DRIVER_PARMS FAR
* LPMCI_OPEN_DRIVER_PARMS
;
1565 DWORD WINAPI
mciGetDriverData(UINT uDeviceID
);
1566 BOOL WINAPI
mciSetDriverData(UINT uDeviceID
, DWORD dwData
);
1567 UINT WINAPI
mciDriverYield(UINT uDeviceID
);
1568 BOOL WINAPI
mciDriverNotify(HWND hwndCallback
, UINT uDeviceID
,
1570 UINT WINAPI
mciLoadCommandResource(HINSTANCE hInstance
,
1571 LPCSTR lpResName
, UINT uType
);
1572 BOOL WINAPI
mciFreeCommandResource(UINT uTable
);
1574 #define DCB_NULL 0x0000
1575 #define DCB_WINDOW 0x0001 /* dwCallback is a HWND */
1576 #define DCB_TASK 0x0002 /* dwCallback is a HTASK */
1577 #define DCB_FUNCTION 0x0003 /* dwCallback is a FARPROC */
1578 #define DCB_TYPEMASK 0x0007
1579 #define DCB_NOSWITCH 0x0008 /* don't switch stacks for callback */
1581 BOOL
DriverCallback(DWORD dwCallBack
, UINT uFlags
, HANDLE hDev
,
1582 WORD wMsg
, DWORD dwUser
, DWORD dwParam1
, DWORD dwParam2
);
1583 DWORD
auxMessage(WORD wDevID
, WORD wMsg
, DWORD dwUser
,
1584 DWORD dwParam1
, DWORD dwParam2
);
1585 DWORD
midMessage(WORD wDevID
, WORD wMsg
, DWORD dwUser
,
1586 DWORD dwParam1
, DWORD dwParam2
);
1587 DWORD
modMessage(WORD wDevID
, WORD wMsg
, DWORD dwUser
,
1588 DWORD dwParam1
, DWORD dwParam2
);
1589 DWORD
widMessage(WORD wDevID
, WORD wMsg
, DWORD dwUser
,
1590 DWORD dwParam1
, DWORD dwParam2
);
1591 DWORD
wodMessage(WORD wDevID
, WORD wMsg
, DWORD dwUser
,
1592 DWORD dwParam1
, DWORD dwParam2
);
1594 #endif /* MMSYSTEM_H */