source: Include/api_mmsys.sbp@ 116

Last change on this file since 116 was 95, checked in by NoWest, 18 years ago

mmsystem.hの完全移植完了。

File size: 82.3 KB
RevLine 
[1]1' api_mmsys.sbp
2' Include file for Multimedia API's
3
4
5#ifndef _INC_MMSYS
6#define _INC_MMSYS
7
8
9' general constants
10Const MAXPNAMELEN = 32
11Const MAXERRORLENGTH = 256
12Const MAX_JOYSTICKOEMVXDNAME = 260
13
14Const MM_MIDI_MAPPER = 1
15Const MM_WAVE_MAPPER = 2
16Const MM_SNDBLST_MIDIOUT = 3
17Const MM_SNDBLST_MIDIIN = 4
18Const MM_SNDBLST_SYNTH = 5
19Const MM_SNDBLST_WAVEOUT = 6
20Const MM_SNDBLST_WAVEIN = 7
21Const MM_ADLIB = 9
22Const MM_MPU401_MIDIOUT = 10
23Const MM_MPU401_MIDIIN = 11
24Const MM_PC_JOYSTICK = 12
25
26' general data types
27TypeDef MMVERSION = DWord
28TypeDef VERSION = DWord
29TypeDef MMRESULT = DWord
30
31' MMTIME data structure
32
33Type Smpte
34 hour As Byte
35 min As Byte
36 sec As Byte
37 frame As Byte
38 fps As Byte
39 dummy As Byte
40 pad[ELM(2)] As Byte
41End Type
42
43Type Midi
44 songptrpos As DWord
45End Type
46
47Type MMTIME
48Public
49 wType As DWord
50 u As DWord
51/* union
52 ms As DWord
53 sample As DWord
54 cb As DWord
55 ticks As DWord
56 smpte As Smpte
57 midi As Midi
58*/
59End Type
60TypeDef PMMTIME = *MMTIME
61TypeDef LPMMTIME = *MMTIME
62
63Const MAKEFOURCC(ch0, ch1, ch2, ch3) = (((ch0 As Byte) or ((ch1 As Byte)<<8) or ((ch2 As Byte)<<16) or ((ch3 As Byte)<<24)) As DWord)
64
65' types for wType field in MMTIME struct
66Const TIME_MS = &H0001
67Const TIME_SAMPLES = &H0002
68Const TIME_BYTES = &H0004
69Const TIME_SMPTE = &H0008
70Const TIME_MIDI = &H0010
71Const TIME_TICKS = &H0020
72
73'----------------------------------------
74' Multimedia Extensions Window Messages
75
76Const MM_JOY1MOVE = &H3A0 'joystick
77Const MM_JOY2MOVE = &H3A1
78Const MM_JOY1ZMOVE = &H3A2
79Const MM_JOY2ZMOVE = &H3A3
80Const MM_JOY1BUTTONDOWN = &H3B5
81Const MM_JOY2BUTTONDOWN = &H3B6
82Const MM_JOY1BUTTONUP = &H3B7
83Const MM_JOY2BUTTONUP = &H3B8
84
85Const MM_MCINOTIFY = &H3B9 'MCI
86
87Const MM_WOM_OPEN = &H3BB 'waveform output
88Const MM_WOM_CLOSE = &H3BC
89Const MM_WOM_DONE = &H3BD
90
91Const MM_WIM_OPEN = &H3BE 'waveform input
92Const MM_WIM_CLOSE = &H3BF
93Const MM_WIM_DATA = &H3C0
94
95Const MM_MIM_OPEN = &H3C1 'MIDI input
96Const MM_MIM_CLOSE = &H3C2
97Const MM_MIM_DATA = &H3C3
98Const MM_MIM_LONGDATA = &H3C4
99Const MM_MIM_ERROR = &H3C5
100Const MM_MIM_LONGERROR = &H3C6
101
102Const MM_MOM_OPEN = &H3C7 'MIDI output
103Const MM_MOM_CLOSE = &H3C8
104Const MM_MOM_DONE = &H3C9
105
106Const MM_DRVM_OPEN = &H3D0 'installable drivers
107Const MM_DRVM_CLOSE = &H3D1
108Const MM_DRVM_DATA = &H3D2
109Const MM_DRVM_ERROR = &H3D3
110
111Const MM_STREAM_OPEN = &H3D4
112Const MM_STREAM_CLOSE = &H3D5
113Const MM_STREAM_DONE = &H3D6
114Const MM_STREAM_ERROR = &H3D7
115
116Const MM_MOM_POSITIONCB = &H3CA
117
118Const MM_MCISIGNAL = &H3CB
119
120Const MM_MIM_MOREDATA = &H3CC 'MIM_DONE w/ pending events
121
122Const MM_MIXM_LINE_CHANGE = &H3D0 'mixer line change notify
123Const MM_MIXM_CONTROL_CHANGE =&H3D1 'mixer control change notify
124
125
126'----------------------------------------------
127' String resource number bases (internal use)
128
129Const MMSYSERR_BASE = 0
130Const WAVERR_BASE = 32
131Const MIDIERR_BASE = 64
132Const TIMERR_BASE = 96
133Const JOYERR_BASE = 160
134Const MCIERR_BASE = 256
135Const MIXERR_BASE = 1024
136
137Const MCI_STRING_OFFSET = 512
138Const MCI_VD_OFFSET = 1024
139Const MCI_CD_OFFSET = 1088
140Const MCI_WAVE_OFFSET = 1152
141Const MCI_SEQ_OFFSET = 1216
142
143
144'----------------------------------------------
145' General error return values
146
147Const MMSYSERR_NOERROR = 0 'no error
148Const MMSYSERR_ERROR = (MMSYSERR_BASE + 1) 'unspecified error
149Const MMSYSERR_BADDEVICEID = (MMSYSERR_BASE + 2) 'device ID out of range
150Const MMSYSERR_NOTENABLED = (MMSYSERR_BASE + 3) 'driver failed enable
151Const MMSYSERR_ALLOCATED = (MMSYSERR_BASE + 4) 'device already allocated
152Const MMSYSERR_INVALHANDLE = (MMSYSERR_BASE + 5) 'device handle is invalid
153Const MMSYSERR_NODRIVER = (MMSYSERR_BASE + 6) 'no device driver present
154Const MMSYSERR_NOMEM = (MMSYSERR_BASE + 7) 'memory allocation error
155Const MMSYSERR_NOTSUPPORTED= (MMSYSERR_BASE + 8) 'function isn't supported
156Const MMSYSERR_BADERRNUM = (MMSYSERR_BASE + 9) 'error value out of range
157Const MMSYSERR_INVALFLAG = (MMSYSERR_BASE + 10) 'invalid flag passed
158Const MMSYSERR_INVALPARAM = (MMSYSERR_BASE + 11) 'invalid parameter passed
159Const MMSYSERR_HANDLEBUSY = (MMSYSERR_BASE + 12) 'handle being used
160Const MMSYSERR_INVALIDALIAS= (MMSYSERR_BASE + 13) 'specified alias not found
161Const MMSYSERR_BADDB = (MMSYSERR_BASE + 14) 'bad registry database
162Const MMSYSERR_KEYNOTFOUND = (MMSYSERR_BASE + 15) 'registry key not found
163Const MMSYSERR_READERROR = (MMSYSERR_BASE + 16) 'registry read error
164Const MMSYSERR_WRITEERROR = (MMSYSERR_BASE + 17) 'registry write error
165Const MMSYSERR_DELETEERROR = (MMSYSERR_BASE + 18) 'registry delete error
166Const MMSYSERR_VALNOTFOUND = (MMSYSERR_BASE + 19) 'registry value not found
167Const MMSYSERR_NODRIVERCB = (MMSYSERR_BASE + 20) 'driver does not call DriverCallback
168Const MMSYSERR_LASTERROR = (MMSYSERR_BASE + 20) 'last error in range
169
170
171'--------------------------------------------------------
172' Installable driver support
173
174Type _System_DeclareHandle_HDRVR:unused As DWord:End Type
175TypeDef HDRVR = *_System_DeclareHandle_HDRVR
176
177Type DRVCONFIGINFOEX
178 dwDCISize As DWord
179 lpszDCISectionName As LPCWSTR
180 lpszDCIAliasName As LPCWSTR
181 dnDevNode As DWORD
182End Type
183TypeDef PDRVCONFIGINFOEX = *DRVCONFIGINFOEX
184TypeDef LPDRVCONFIGINFOEX = *DRVCONFIGINFOEX
185
186' Driver messages
187Const DRV_LOAD = &H0001
188Const DRV_ENABLE = &H0002
189Const DRV_OPEN = &H0003
190Const DRV_CLOSE = &H0004
191Const DRV_DISABLE = &H0005
192Const DRV_FREE = &H0006
193Const DRV_CONFIGURE = &H0007
194Const DRV_QUERYCONFIGURE = &H0008
195Const DRV_INSTALL = &H0009
196Const DRV_REMOVE = &H000A
197Const DRV_EXITSESSION = &H000B
198Const DRV_POWER = &H000F
199Const DRV_RESERVED = &H0800
200Const DRV_USER = &H4000
201
202Type DRVCONFIGINFO
203 dwDCISize As DWord
204 lpszDCISectionName As LPCWSTR
205 lpszDCIAliasName As LPCWSTR
206End Type
207TypeDef PDRVCONFIGINFO = *DRVCONFIGINFO
208TypeDef LPDRVCONFIGINFO = *DRVCONFIGINFO
209
210' Supported return values for DRV_CONFIGURE message
211Const DRVCNF_CANCEL = &H0000
212Const DRVCNF_OK = &H0001
213Const DRVCNF_RESTART = &H0002
214
215TypeDef DRIVERPROC = *Function(dwDriverId As DWord, hdrvr As HDRVR, msg As DWord, lParam1 As LPARAM, lParam2 As LPARAM) As LRESULT
216
217Declare Function CloseDriver Lib "winmm" (hDriver As HDRVR, lParam1 As Long, lParam2 As Long) As LRESULT
218Declare Function OpenDriver Lib "winmm" (szDriverName As LPCWSTR, szSectionName As LPCWSTR, lParam2 As Long) As HDRVR
219Declare Function SendDriverMessage Lib "winmm" (hDriver As HDRVR, message As DWord, lParam1 As Long, lParam2 As Long) As LRESULT
220Declare Function GetDriverModuleHandle Lib "winmm" (hDriver As HDRVR) As HMODULE
221Declare Function DefDriverProc Lib "winmm" (dwDriverIdentifier As DWord, hdrvr As HDRVR, uMsg As DWord, lParam1 As LPARAM, lParam2 As LPARAM) As LRESULT
222
223Declare Function DrvClose Lib "winmm" Alias "CloseDriver" (hDriver As HDRVR, lParam1 As Long, lParam2 As Long) As LRESULT
224Declare Function DrvOpen Lib "winmm" Alias "OpenDriver" (szDriverName As LPCWSTR, szSectionName As LPCWSTR, lParam2 As Long) As HDRVR
225Declare Function DrvSendMessage Lib "winmm" Alias "SendDriverMessage" (hDriver As HDRVR, message As DWord, lParam1 As Long, lParam2 As Long) As LRESULT
226Declare Function DrvGetModuleHandle Lib "winmm" Alias "GetDriverModuleHandle" (hDriver As HDRVR) As HMODULE
227Declare Function DrvDefDriverProc Lib "winmm" Alias "DefDriverProc" (dwDriverIdentifier As DWord, hdrvr As HDRVR, uMsg As DWord, lParam1 As LPARAM, lParam2 As LPARAM) As LRESULT
228
229' return values from DriverProc() function
230Const DRV_CANCEL = DRVCNF_CANCEL
231Const DRV_OK = DRVCNF_OK
232Const DRV_RESTART = DRVCNF_RESTART
233
234Const DRV_MCI_FIRST = DRV_RESERVED
235Const DRV_MCI_LAST = (DRV_RESERVED + &HFFF)
236
237
238'--------------------------------------------------------
239' Driver callback support
240Const CALLBACK_TYPEMASK = &H00070000 'callback type mask
241Const CALLBACK_NULL = &H00000000 'no callback
242Const CALLBACK_WINDOW = &H00010000 'dwCallback is a HWND
243Const CALLBACK_TASK = &H00020000 'dwCallback is a HTASK
244Const CALLBACK_FUNCTION = &H00030000 'dwCallback is a FARPROC
245Const CALLBACK_THREAD = (CALLBACK_TASK)'thread ID replaces 16 bit task
246Const CALLBACK_EVENT = &H00050000 'dwCallback is an EVENT Handle
247
248TypeDef DRVCALLBACK = *Sub(hdrvr As HDRVR, uMsg As DWord, dwUser As DWord, dw1 As DWord, dw2 As DWord)
249TypeDef PDRVCALLBACK = *DRVCALLBACK
250TypeDef LPDRVCALLBACK = *DRVCALLBACK
251
252
253'--------------------------------------------------------
254' General MMSYSTEM support
255
256Declare Function mmsystemGetVersion Lib "winmm" () As DWord
257
258
259
260'--------------------------------------------------------
261' Sound support
262
263Declare Function sndPlaySound Lib "winmm" Alias "sndPlaySoundA" (pszSound As PCSTR, fuSound As DWord) As BOOL
264
265Const SND_SYNC = &H0000
266Const SND_ASYNC = &H0001
267Const SND_NODEFAULT = &H0002
268Const SND_MEMORY = &H0004
269Const SND_LOOP = &H0008
270Const SND_NOSTOP = &H0010
271Const SND_NOWAIT = &H00002000
272Const SND_ALIAS = &H00010000
273Const SND_ALIAS_ID = &H00110000
274Const SND_FILENAME = &H00020000
275Const SND_RESOURCE = &H00040004
276Const SND_PURGE = &H0040
277Const SND_APPLICATION = &H0080
278Const SND_ALIAS_START = 0
279
280Const sndAlias(ch0, ch1) = (SND_ALIAS_START + ((&HFF AND ch0) OR (&HFF AND ch1)<<8))
281
282Const SND_ALIAS_SYSTEMASTERISK = sndAlias(&H53, &H2A)
283Const SND_ALIAS_SYSTEMQUESTION = sndAlias(&H53, &H3F)
284Const SND_ALIAS_SYSTEMHAND = sndAlias(&H53, &H48)
285Const SND_ALIAS_SYSTEMEXIT = sndAlias(&H53, &H45)
286Const SND_ALIAS_SYSTEMSTART = sndAlias(&H53, &H53)
287Const SND_ALIAS_SYSTEMWELCOME = sndAlias(&H53, &H57)
288Const SND_ALIAS_SYSTEMEXCLAMATION = sndAlias(&H53, &H21)
289Const SND_ALIAS_SYSTEMDEFAULT = sndAlias(&H53, &H44)
290
291Declare Function PlaySound Lib "winmm" Alias "PlaySoundA" (pszSound As PCSTR, hmod As HMODULE, fdwSound As DWord) As BOOL
292
293
294'--------------------------------------------------------
295' Waveform audio support
296
297' waveform audio error return values
298Const WAVERR_BADFORMAT = (WAVERR_BASE + 0)
299Const WAVERR_STILLPLAYING = (WAVERR_BASE + 1)
300Const WAVERR_UNPREPARED = (WAVERR_BASE + 2)
301Const WAVERR_SYNC = (WAVERR_BASE + 3)
302Const WAVERR_LASTERROR = (WAVERR_BASE + 3)
303
304' waveform audio data types
305Type _System_DeclareHandle_HWAVE:unused As DWord:End Type
306TypeDef HWAVE = *_System_DeclareHandle_HWAVE
307Type _System_DeclareHandle_HWAVEIN:unused As DWord:End Type
308TypeDef HWAVEIN = *_System_DeclareHandle_HWAVEIN
309Type _System_DeclareHandle_HWAVEOUT:unused As DWord:End Type
310TypeDef HWAVEOUT = *_System_DeclareHandle_HWAVEOUT
311
312TypeDef WAVECALLBACK = DRVCALLBACK
313TypeDef LPWAVECALLBACK = *WAVECALLBACK
314
315' wave callback messages
316Const WOM_OPEN = MM_WOM_OPEN
317Const WOM_CLOSE = MM_WOM_CLOSE
318Const WOM_DONE = MM_WOM_DONE
319Const WIM_OPEN = MM_WIM_OPEN
320Const WIM_CLOSE = MM_WIM_CLOSE
321Const WIM_DATA = MM_WIM_DATA
322
323' device ID for wave device mapper
324Const WAVE_MAPPER = (-1)
325
326' flags for dwFlags parameter in waveOutOpen() and waveInOpen()
327Const WAVE_FORMAT_QUERY = &H0001
328Const WAVE_ALLOWSYNC = &H0002
329Const WAVE_MAPPED = &H0004
330Const WAVE_FORMAT_DIRECT = &H0008
331Const WAVE_FORMAT_DIRECT_QUERY = (WAVE_FORMAT_QUERY OR WAVE_FORMAT_DIRECT)
332
333' wave data block header
334Type WAVEHDR
335 lpData As LPSTR
336 dwBufferLength As DWord
337 dwBytesRecorded As DWord
338 dwUser As DWord
339 dwFlags As DWord
340 dwLoops As DWord
341 lpNext As *WAVEHDR
342 reserved As DWord
343End Type
344TypeDef PWAVEHDR = *WAVEHDR
345TypeDef LPWAVEHDR = *WAVEHDR
346
347' flags for dwFlags field of WAVEHDR
348Const WHDR_DONE = &H00000001
349Const WHDR_PREPARED = &H00000002
350Const WHDR_BEGINLOOP = &H00000004
351Const WHDR_ENDLOOP = &H00000008
352Const WHDR_INQUEUE = &H00000010
353
354' waveform output device capabilities structure
355Type WAVEOUTCAPSA
356 wMid As Word
357 wPid As Word
358 vDriverVersion As MMVERSION
359 szPname[ELM(MAXPNAMELEN)] As Char
360 dwFormats As DWord
361 wChannels As Word
362 wReserved1 As Word
363 dwSupport As DWord
364End Type
365TypeDef PWAVEOUTCAPSA = *WAVEOUTCAPSA
366TypeDef LPWAVEOUTCAPSA = *WAVEOUTCAPSA
367
368TypeDef WAVEOUTCAPS = WAVEOUTCAPSA
369TypeDef PWAVEOUTCAPS = PWAVEOUTCAPSA
370TypeDef LPWAVEOUTCAPS = LPWAVEOUTCAPSA
371
372' flags for dwSupport field of WAVEOUTCAPS
373Const WAVECAPS_PITCH = &H0001
374Const WAVECAPS_PLAYBACKRATE = &H0002
375Const WAVECAPS_VOLUME = &H0004
376Const WAVECAPS_LRVOLUME = &H0008
377Const WAVECAPS_SYNC = &H0010
378Const WAVECAPS_SAMPLEACCURATE = &H0020
379Const WAVECAPS_DIRECTSOUND = &H0040
380
381' waveform input device capabilities structure
382Type WAVEINCAPSA
383 wMid As Word
384 wPid As Word
385 vDriverVersion As MMVERSION
386 szPname[ELM(MAXPNAMELEN)] As Char
387 dwFormats As DWord
388 wChannels As Word
389 wReserved1 As Word
390End Type
391TypeDef PWAVEINCAPSA = *WAVEINCAPSA
392TypeDef LPWAVEINCAPSA = *WAVEINCAPSA
393
394TypeDef WAVEINCAPS = WAVEINCAPSA
395TypeDef PWAVEINCAPS = PWAVEINCAPSA
396TypeDef LPWAVEINCAPS = LPWAVEINCAPSA
397
398' defines for dwFormat field of WAVEINCAPS and WAVEOUTCAPS
399Const WAVE_INVALIDFORMAT = &H00000000 ' invalid format
400Const WAVE_FORMAT_1M08 = &H00000001 ' 11.025 kHz, Mono, 8-bit
401Const WAVE_FORMAT_1S08 = &H00000002 ' 11.025 kHz, Stereo, 8-bit
402Const WAVE_FORMAT_1M16 = &H00000004 ' 11.025 kHz, Mono, 16-bit
403Const WAVE_FORMAT_1S16 = &H00000008 ' 11.025 kHz, Stereo, 16-bit
404Const WAVE_FORMAT_2M08 = &H00000010 ' 22.05 kHz, Mono, 8-bit
405Const WAVE_FORMAT_2S08 = &H00000020 ' 22.05 kHz, Stereo, 8-bit
406Const WAVE_FORMAT_2M16 = &H00000040 ' 22.05 kHz, Mono, 16-bit
407Const WAVE_FORMAT_2S16 = &H00000080 ' 22.05 kHz, Stereo, 16-bit
408Const WAVE_FORMAT_4M08 = &H00000100 ' 44.1 kHz, Mono, 8-bit
409Const WAVE_FORMAT_4S08 = &H00000200 ' 44.1 kHz, Stereo, 8-bit
410Const WAVE_FORMAT_4M16 = &H00000400 ' 44.1 kHz, Mono, 16-bit
411Const WAVE_FORMAT_4S16 = &H00000800 ' 44.1 kHz, Stereo, 16-bit
412
413' OLD general waveform format structure (information common to all formats)
414Type WAVEFORMAT
415 wFormatTag As Word
416 nChannels As Word
417 nSamplesPerSec As DWord
418 nAvgBytesPerSec As DWord
419 nBlockAlign As Word
420End Type
421TypeDef PWAVEFORMAT = *WAVEFORMAT
422TypeDef LPWAVEFORMAT = *WAVEFORMAT
423
424' flags for wFormatTag field of WAVEFORMAT
425Const WAVE_FORMAT_PCM = 1
426
427' specific waveform format structure for PCM data
428Type PCMWAVEFORMAT
429 wf As WAVEFORMAT
430 wBitsPerSample As Word
431End Type
432TypeDef PPCMWAVEFORMAT = *PCMWAVEFORMAT
433TypeDef LPPCMWAVEFORMAT = *PCMWAVEFORMAT
434
435Type WAVEFORMATEX
436 wFormatTag As Word
437 nChannels As Word
438 nSamplesPerSec As DWord
439 nAvgBytesPerSec As DWord
440 nBlockAlign As Word
441 wBitsPerSample As Word
442 cbSize As Word
443End Type
444TypeDef PWAVEFORMATEX = *WAVEFORMATEX
445TypeDef LPWAVEFORMATEX = *WAVEFORMATEX
446TypeDef LPCWAVEFORMATEX = *WAVEFORMATEX
447
448' waveform audio function prototypes
449Declare Function waveOutGetNumDevs Lib "winmm" () As DWord
450Declare Function waveOutGetDevCaps Lib "winmm" Alias "waveOutGetDevCapsA" (uDeviceID As DWord, ByRef pwoc As WAVEOUTCAPS, cbwoc As DWord) As MMRESULT
451Declare Function waveOutGetVolume Lib "winmm" (hwo As HWAVEOUT, ByRef pdwVolume As DWord) As MMRESULT
452Declare Function waveOutSetVolume Lib "winmm" (hwo As HWAVEOUT, dwVolume As DWord) As MMRESULT
453Declare Function waveOutGetErrorText Lib "winmm" Alias "waveOutGetErrorTextA" (mmrError As MMRESULT, pszText As LPSTR, cchText As DWord) As MMRESULT
454Declare Function waveOutOpen Lib "winmm" (ByRef phwo As HWAVEOUT, uDeviceID As DWord, ByRef pwfx As WAVEFORMATEX, dwCallback As DWord, dwInstance As DWord, fdwOpen As DWord) As MMRESULT
455Declare Function waveOutClose Lib "winmm" (hwo As HWAVEOUT) As MMRESULT
456Declare Function waveOutPrepareHeader Lib "winmm" (hwo As HWAVEOUT, ByRef pwh As WAVEHDR, cbwh As DWord) As MMRESULT
457Declare Function waveOutUnprepareHeader Lib "winmm" (hwo As HWAVEOUT, ByRef pwh As WAVEHDR, cbwh As DWord) As MMRESULT
458Declare Function waveOutWrite Lib "winmm" (hwo As HWAVEOUT, ByRef pwh As WAVEHDR, cbwh As DWord) As MMRESULT
459Declare Function waveOutPause Lib "winmm" (hwo As HWAVEOUT) As MMRESULT
460Declare Function waveOutRestart Lib "winmm" (hwo As HWAVEOUT) As MMRESULT
461Declare Function waveOutReset Lib "winmm" (hwo As HWAVEOUT) As MMRESULT
462Declare Function waveOutBreakLoop Lib "winmm" (hwo As HWAVEOUT) As MMRESULT
463Declare Function waveOutGetPosition Lib "winmm" (hwo As HWAVEOUT, ByRef pmmt As MMTIME, cbmmt As DWord) As MMRESULT
464Declare Function waveOutGetPitch Lib "winmm" (hwo As HWAVEOUT, ByRef pdwPitch As DWord) As MMRESULT
465Declare Function waveOutSetPitch Lib "winmm" (hwo As HWAVEOUT, dwPitch As DWord) As MMRESULT
466Declare Function waveOutGetPlaybackRate Lib "winmm" (hwo As HWAVEOUT, ByRef pdwRate As DWord) As MMRESULT
467Declare Function waveOutSetPlaybackRate Lib "winmm" (hwo As HWAVEOUT, dwRate As DWord) As MMRESULT
468Declare Function waveOutGetID Lib "winmm" (hwo As HWAVEOUT, ByRef puDeviceID As DWord) As MMRESULT
469Declare Function waveOutMessage Lib "winmm" (hwo As HWAVEOUT, uMsg As DWord, dw1 As DWord, dw2 As DWord) As MMRESULT
470
471Declare Function waveInGetNumDevs Lib "winmm" () As DWord
472Declare Function waveInGetDevCaps Lib "winmm" Alias "waveInGetDevCapsA" (uDeviceID As DWord, ByRef pwic As WAVEINCAPS, cbwic As DWord) As MMRESULT
473Declare Function waveInGetErrorText Lib "winmm" Alias "waveInGetErrorTextA" (mmrError As MMRESULT, pszText As LPSTR, cchText As DWord) As MMRESULT
474Declare Function waveInOpen Lib "winmm" (ByRef phwi As HWAVEIN, uDeviceID As DWord, ByRef pwfx As WAVEFORMATEX, dwCallback As DWord, dwInstance As DWord, fdwOpen As DWord) As MMRESULT
475Declare Function waveInClose Lib "winmm" (hwi As HWAVEIN) As MMRESULT
476Declare Function waveInPrepareHeader Lib "winmm" (hwi As HWAVEIN, ByRef pwh As WAVEHDR, cbwh As DWord) As MMRESULT
477Declare Function waveInUnprepareHeader Lib "winmm" (hwi As HWAVEIN, ByRef pwh As WAVEHDR, cbwh As DWord) As MMRESULT
478Declare Function waveInAddBuffer Lib "winmm" (hwi As HWAVEIN, ByRef pwh As WAVEHDR, cbwh As DWord) As MMRESULT
479Declare Function waveInStart Lib "winmm" (hwi As HWAVEIN) As MMRESULT
480Declare Function waveInStop Lib "winmm" (hwi As HWAVEIN) As MMRESULT
481Declare Function waveInReset Lib "winmm" (hwi As HWAVEIN) As MMRESULT
482Declare Function waveInGetPosition Lib "winmm" (hwi As HWAVEIN, ByRef pmmt As MMTIME, cbmmt As DWord) As MMRESULT
483Declare Function waveInGetID Lib "winmm" (hwi As HWAVEIN, ByRef puDeviceID As DWord) As MMRESULT
484Declare Function waveInMessage Lib "winmm" (hwi As HWAVEIN, uMsg As DWord, dw1 As DWord, dw2 As DWord) As MMRESULT
485
486
487
488'--------------------------------------------------------
489' MIDI audio support
490
491' MIDI error return values
492Const MIDIERR_UNPREPARED = (MIDIERR_BASE + 0)
493Const MIDIERR_STILLPLAYING = (MIDIERR_BASE + 1)
494Const MIDIERR_NOMAP = (MIDIERR_BASE + 2)
495Const MIDIERR_NOTREADY = (MIDIERR_BASE + 3)
496Const MIDIERR_NODEVICE = (MIDIERR_BASE + 4)
497Const MIDIERR_INVALIDSETUP = (MIDIERR_BASE + 5)
498Const MIDIERR_BADOPENMODE = (MIDIERR_BASE + 6)
499Const MIDIERR_DONT_CONTINUE = (MIDIERR_BASE + 7)
500Const MIDIERR_LASTERROR = (MIDIERR_BASE + 7)
501
502' MIDI audio data types
503Type _System_DeclareHandle_HMIDI:unused As DWord:End Type
504TypeDef HMIDI = *_System_DeclareHandle_HMIDI
505Type _System_DeclareHandle_HMIDIIN:unused As DWord:End Type
506TypeDef HMIDIIN = *_System_DeclareHandle_HMIDIIN
507Type _System_DeclareHandle_HMIDIOUT:unused As DWord:End Type
508TypeDef HMIDIOUT = *_System_DeclareHandle_HMIDIOUT
509Type _System_DeclareHandle_HMIDISTRM:unused As DWord:End Type
510TypeDef HMIDISTRM = *_System_DeclareHandle_HMIDISTRM
511
512TypeDef MIDICALLBACK = DRVCALLBACK
513TypeDef LPMIDICALLBACK = *MIDICALLBACK
514
515Const MIDIPATCHSIZE = 128
516
517TypeDef LPPATCHARRAY = *Word
518TypeDef LPKEYARRAY = *Word
519
520' MIDI callback messages
521Const MIM_OPEN = MM_MIM_OPEN
522Const MIM_CLOSE = MM_MIM_CLOSE
523Const MIM_DATA = MM_MIM_DATA
524Const MIM_LONGDATA = MM_MIM_LONGDATA
525Const MIM_ERROR = MM_MIM_ERROR
526Const MIM_LONGERROR = MM_MIM_LONGERROR
527Const MOM_OPEN = MM_MOM_OPEN
528Const MOM_CLOSE = MM_MOM_CLOSE
529Const MOM_DONE = MM_MOM_DONE
530Const MIM_MOREDATA = MM_MIM_MOREDATA
531Const MOM_POSITIONCB = MM_MOM_POSITIONCB
532
533' device ID for MIDI mapper
534Const MIDIMAPPER = (-1)
535Const MIDI_MAPPER = (-1)
536
537Const MIDI_IO_STATUS = &H00000020
538
539' flags for wFlags parm of midiOutCachePatches(), midiOutCacheDrumPatches()
540Const MIDI_CACHE_ALL = 1
541Const MIDI_CACHE_BESTFIT = 2
542Const MIDI_CACHE_QUERY = 3
543Const MIDI_UNCACHE = 4
544
545' MIDI output device capabilities structure
546Type MIDIOUTCAPSA
547 wMid As Word
548 wPid As Word
549 vDriverVersion As MMVERSION
550 szPname[ELM(MAXPNAMELEN)] As Char
551 wTechnology As Word
552 wVoices As Word
553 wNotes As Word
554 wChannelMask As Word
555 dwSupport As DWord
556End Type
557TypeDef PMIDIOUTCAPSA = *MIDIOUTCAPSA
558TypeDef LPMIDIOUTCAPSA = *MIDIOUTCAPSA
559
560TypeDef MIDIOUTCAPS = MIDIOUTCAPSA
561TypeDef PMIDIOUTCAPS = PMIDIOUTCAPSA
562TypeDef LPMIDIOUTCAPS = LPMIDIOUTCAPSA
563
564' flags for wTechnology field of MIDIOUTCAPS structure
565Const MOD_MIDIPORT = 1
566Const MOD_SYNTH = 2
567Const MOD_SQSYNTH = 3
568Const MOD_FMSYNTH = 4
569Const MOD_MAPPER = 5
570
571' flags for dwSupport field of MIDIOUTCAPS structure
572Const MIDICAPS_VOLUME = &H0001
573Const MIDICAPS_LRVOLUME = &H0002
574Const MIDICAPS_CACHE = &H0004
575Const MIDICAPS_STREAM = &H0008
576
577' MIDI input device capabilities structure
578Type MIDIINCAPSA
579 wMid As Word
580 wPid As Word
581 vDriverVersion As MMVERSION
582 szPname[ELM(MAXPNAMELEN)] As Char
583 dwSupport As DWord
584End Type
585TypeDef PMIDIINCAPSA = *MIDIINCAPSA
586TypeDef LPMIDIINCAPSA = *MIDIINCAPSA
587
588TypeDef MIDIINCAPS = MIDIINCAPSA
589TypeDef PMIDIINCAPS = PMIDIINCAPSA
590TypeDef LPMIDIINCAPS = LPMIDIINCAPSA
591
592' MIDI data block header
593Type MIDIHDR
594 lpData As LPSTR
595 dwBufferLength As DWord
596 dwBytesRecorded As DWord
597 dwUser As DWord
598 dwFlags As DWord
599 lpNext As *MIDIHDR
600 reserved As DWord
601 dwOffset As DWord
602 dwReserved[ELM(8)] As DWord
603End Type
604TypeDef PMIDIHDR = *MIDIHDR
605TypeDef LPMIDIHDR = *MIDIHDR
606
607Type MIDIEVENT
608 dwDeltaTime As DWord
609 dwStreamID As DWord
610 dwEvent As DWord
611 dwParms[ELM(1)] As DWord
612End Type
613
614Type MIDISTRMBUFFVER
615 dwVersion As DWord
616 dwMid As DWord
617 dwOEMVersion As DWord
618End Type
619
620' flags for dwFlags field of MIDIHDR structure
621Const MHDR_DONE = &H00000001
622Const MHDR_PREPARED = &H00000002
623Const MHDR_INQUEUE = &H00000004
624Const MHDR_ISSTRM = &H00000008
625
626Const MEVT_F_SHORT = &H00000000
627Const MEVT_F_LONG = &H80000000
628Const MEVT_F_CALLBACK = &H40000000
629Const MEVT_EVENTTYPE(x) = ((x>>24) AND &HFF)
630Const MEVT_EVENTPARM(x) = (x AND &H00FFFFFF)
631Const MEVT_SHORTMSG = (&H00)
632Const MEVT_TEMPO = (&H01)
633Const MEVT_NOP = (&H02)
634Const MEVT_LONGMSG = (&H80)
635Const MEVT_COMMENT = (&H82)
636Const MEVT_VERSION = (&H84)
637
638Const MIDISTRM_ERROR = (-2)
639
640' Structures and defines for midiStreamProperty
641Const MIDIPROP_SET = &H80000000
642Const MIDIPROP_GET = &H40000000
643Const MIDIPROP_TIMEDIV = &H00000001
644Const MIDIPROP_TEMPO = &H00000002
645
646Type MIDIPROPTIMEDIV
647 cbStruct As DWord
648 dwTimeDiv As DWord
649End Type
650TypeDef LPMIDIPROPTIMEDIV = *MIDIPROPTIMEDIV
651
652Type MIDIPROPTEMPO
653 cbStruct As DWord
654 dwTempo As DWord
655End Type
656TypeDef LPMIDIPROPTEMPO = *MIDIPROPTEMPO
657
658
659' MIDI function prototypes
660Declare Function midiOutGetNumDevs Lib "winmm" () As DWord
661Declare Function midiStreamOpen Lib "winmm" (ByRef phms As HMIDISTRM, ByRef puDeviceID As DWord, cMidi As DWord, dwCallback As DWord, dwInstance As DWord, fdwOpen As DWord) As MMRESULT
662Declare Function midiStreamClose Lib "winmm" (hms As HMIDISTRM) As MMRESULT
663Declare Function midiStreamProperty Lib "winmm" (hms As HMIDISTRM, lppropdata As *Byte, dwProperty As DWord) As MMRESULT
664Declare Function midiStreamPosition Lib "winmm" (hms As HMIDISTRM, ByRef lpmmt As MMTIME, cbmmt As DWord) As MMRESULT
665Declare Function midiStreamOut Lib "winmm" (hms As HMIDISTRM, ByRef pmh As MIDIHDR, cbmh As DWord) As MMRESULT
666Declare Function midiStreamPause Lib "winmm" (hms As HMIDISTRM) As MMRESULT
667Declare Function midiStreamRestart Lib "winmm" (hms As HMIDISTRM) As MMRESULT
668Declare Function midiStreamStop Lib "winmm" (hms As HMIDISTRM) As MMRESULT
669
670Declare Function midiConnect Lib "winmm" (hmi As HMIDI, hmo As HMIDIOUT, pReserved As VoidPtr) As MMRESULT
671Declare Function midiDisconnect Lib "winmm" (hmi As HMIDI, hmo As HMIDIOUT, pReserved As VoidPtr) As MMRESULT
672Declare Function midiOutGetDevCaps Lib "winmm" Alias "midiOutGetDevCapsA" (uDeviceID As DWord, ByRef pmoc As MIDIOUTCAPS, cbmoc As DWord) As MMRESULT
673Declare Function midiOutGetVolume Lib "winmm" (hmo As HMIDIOUT, ByRef pdwVolume As DWord) As MMRESULT
674Declare Function midiOutSetVolume Lib "winmm" (hmo As HMIDIOUT, dwVolume As DWord) As MMRESULT
675Declare Function midiOutGetErrorText Lib "winmm" Alias "midiOutGetErrorTextA" (mmrError As MMRESULT, pszText As LPSTR, cchText As DWord) As MMRESULT
676Declare Function midiOutOpen Lib "winmm" (ByRef phmo As HMIDIOUT, uDeviceID As DWord, dwCallback As DWord, dwInstance As DWord, fdwOpen As DWord) As MMRESULT
677Declare Function midiOutClose Lib "winmm" (hmo As HMIDIOUT) As MMRESULT
678Declare Function midiOutPrepareHeader Lib "winmm" (hmo As HMIDIOUT, ByRef pmh As MIDIHDR, cbmh As DWord) As MMRESULT
679Declare Function midiOutUnprepareHeader Lib "winmm" (hmo As HMIDIOUT, ByRef pmh As MIDIHDR, cbmh As DWord) As MMRESULT
680Declare Function midiOutShortMsg Lib "winmm" (hmo As HMIDIOUT, dwMsg As DWord) As MMRESULT
681Declare Function midiOutLongMsg Lib "winmm" (hmo As HMIDIOUT, ByRef pmh As MIDIHDR, cbmh As DWord) As MMRESULT
682Declare Function midiOutReset Lib "winmm" (hmo As HMIDIOUT) As MMRESULT
683Declare Function midiOutCachePatches Lib "winmm" (hmo As HMIDIOUT, uBank As DWord, ByRef pwpa As Word, fuCache As DWord) As MMRESULT
684Declare Function midiOutCacheDrumPatches Lib "winmm" (hmo As HMIDIOUT, uPatch As DWord, ByRef pwkya As Word, fuCache As DWord) As MMRESULT
685Declare Function midiOutGetID Lib "winmm" (hmo As HMIDIOUT, ByRef puDeviceID As DWord) As MMRESULT
686Declare Function midiOutMessage Lib "winmm" (hmo As HMIDIOUT, uMsg As DWord, dw1 As DWord, dw2 As DWord) As MMRESULT
687
688Declare Function midiInGetNumDevs Lib "winmm" () As DWord
689Declare Function midiInGetDevCaps Lib "winmm" Alias "midiInGetDevCapsA" (uDeviceID As DWord, ByRef pmic As MIDIINCAPS, cbmic As DWord) As MMRESULT
690Declare Function midiInGetErrorText Lib "winmm" Alias "midiInGetErrorTextA" (mmrError As MMRESULT, pszText As LPSTR, cchText As DWord) As MMRESULT
691Declare Function midiInOpen Lib "winmm" (ByRef phmi As HMIDIIN, uDeviceID As DWord, dwCallback As DWord, dwInstance As DWord, fdwOpen As DWord) As MMRESULT
692Declare Function midiInClose Lib "winmm" (hmi As HMIDIIN) As MMRESULT
693Declare Function midiInPrepareHeader Lib "winmm" (hmi As HMIDIIN, ByRef pmh As MIDIHDR, cbmh As DWord) As MMRESULT
694Declare Function midiInUnprepareHeader Lib "winmm" (hmi As HMIDIIN, ByRef pmh As MIDIHDR, cbmh As DWord) As MMRESULT
695Declare Function midiInAddBuffer Lib "winmm" (hmi As HMIDIIN, ByRef pmh As MIDIHDR, cbmh As DWord) As MMRESULT
696Declare Function midiInStart Lib "winmm" (hmi As HMIDIIN) As MMRESULT
697Declare Function midiInStop Lib "winmm" (hmi As HMIDIIN) As MMRESULT
698Declare Function midiInReset Lib "winmm" (hmi As HMIDIIN) As MMRESULT
699Declare Function midiInGetID Lib "winmm" (hmi As HMIDIIN, ByRef puDeviceID As DWord) As MMRESULT
700Declare Function midiInMessage Lib "winmm" (hmi As HMIDIIN, uMsg As DWord, dw1 As DWord, dw2 As DWord) As MMRESULT
701
702
[75]703'--------------------------------------------------------
704' Auxiliary audio support
[1]705
[75]706' device ID for aux device mapper
707Const AUX_MAPPER = (-1)
708
709' Auxiliary audio device capabilities structure
710Type AUXCAPSA
711 wMid As Word
712 wPid As Word
713 vDriverVersion As MMVERSION
714 szPname[ELM(MAXPNAMELEN)] As Char
715 wTechnology As Word
716 wReserved1 As Word
717 dwSupport As DWord
718End Type
719TypeDef PAUXCAPSA = *AUXCAPSA
720TypeDef NPAUXCAPSA = *AUXCAPSA
721TypeDef LPAUXCAPSA = *AUXCAPSA
722
723TypeDef AUXCAPS = AUXCAPSA
724TypeDef PAUXCAPS = PAUXCAPSA
725TypeDef NPAUXCAPS = NPAUXCAPSA
726TypeDef LPAUXCAPS = LPAUXCAPSA
727
728Const AUXCAPS_CDAUDIO = 1
729Const AUXCAPS_AUXIN = 2
730
731Const AUXCAPS_VOLUME = &H0001
732Const AUXCAPS_LRVOLUME = &H0002
733
734' auxiliary audio function prototypes
735Declare Function auxGetNumDevs Lib "winmm" () As DWord
736Declare Function auxGetDevCaps Lib "winmm" Alias "auxGetDevCapsA" (uDeviceID As DWord, pac As *AUXCAPS, cbac As DWord) As MMRESULT
737Declare Function auxSetVolume Lib "winmm" (uDeviceID As DWord, dwVolume As DWord) As MMRESULT
738Declare Function auxGetVolume Lib "winmm" (uDeviceID As DWord, pdwVolume As *DWord) As MMRESULT
739Declare Function auxOutMessage Lib "winmm" (uDeviceID As DWord, uMsg As DWord, dw1 As DWord, dw2 As DWord) As MMRESULT
740
741
[1]742'--------------------------------------------------------
[75]743' Mixer Support
744
745TypeDef HMIXEROBJ = VoidPtr
746TypeDef LPHMIXEROBJ = HMIXEROBJ
747TypeDef HMIXER = VoidPtr
748TypeDef LPHMIXER = *HMIXER
749
750Const MIXER_SHORT_NAME_CHARS = 16
751Const MIXER_LONG_NAME_CHARS = 64
752
753Const MIXERR_INVALLINE = (MIXERR_BASE + 0)
754Const MIXERR_INVALCONTROL = (MIXERR_BASE + 1)
755Const MIXERR_INVALVALUE = (MIXERR_BASE + 2)
756Const MIXERR_LASTERROR = (MIXERR_BASE + 2)
757
758Const MIXER_OBJECTF_HANDLE = &H80000000
759Const MIXER_OBJECTF_MIXER = &H00000000
760Const MIXER_OBJECTF_HMIXER = (MIXER_OBJECTF_HANDLE OR MIXER_OBJECTF_MIXER)
761Const MIXER_OBJECTF_WAVEOUT = &H10000000
762Const MIXER_OBJECTF_HWAVEOUT = (MIXER_OBJECTF_HANDLE OR MIXER_OBJECTF_WAVEOUT)
763Const MIXER_OBJECTF_WAVEIN = &H20000000
764Const MIXER_OBJECTF_HWAVEIN = (MIXER_OBJECTF_HANDLE OR MIXER_OBJECTF_WAVEIN)
765Const MIXER_OBJECTF_MIDIOUT = &H30000000
766Const MIXER_OBJECTF_HMIDIOUT = (MIXER_OBJECTF_HANDLE OR MIXER_OBJECTF_MIDIOUT)
767Const MIXER_OBJECTF_MIDIIN = &H40000000
768Const MIXER_OBJECTF_HMIDIIN = (MIXER_OBJECTF_HANDLE OR MIXER_OBJECTF_MIDIIN)
769Const MIXER_OBJECTF_AUX = &H50000000
770
771Declare Function mixerGetNumDevs Lib "winmm" () As DWord
772
773Type MIXERCAPSA
774 wMid As Word
775 wPid As Word
776 vDriverVersion As MMVERSION
777 szPname[ELM(MAXPNAMELEN)] As Char
778 fdwSupport As DWord
779 cDestinations As DWord
780End Type
781TypeDef PMIXERCAPSA = *MIXERCAPSA
782TypeDef LPMIXERCAPSA = *MIXERCAPSA
783
784TypeDef MIXERCAPS = MIXERCAPSA
785TypeDef PMIXERCAPS = PMIXERCAPSA
786TypeDef LPMIXERCAPS = LPMIXERCAPSA
787
788Declare Function mixerGetDevCaps Lib "winmm" Alias "mixerGetDevCapsA" (uMxId As DWord, pmxcaps As *MIXERCAPS, cbmxcaps As DWord) As MMRESULT
789Declare Function mixerOpen Lib "winmm" (phmx As *HMIXER, uMxId As DWord, dwCallback As DWord, dwInstance As DWord, fdwOpen As DWord) As MMRESULT
790Declare Function mixerClose Lib "winmm" (hmx As HMIXER) As MMRESULT
791Declare Function mixerMessage Lib "winmm" (hmx As HMIXER, uMsg As DWord, dwParam1 As DWord, dwParam2 As DWord) As DWord
792
793Type TARGET
794 dwType As DWord
795 dwDeviceID As DWord
796 wMid As Word
797 wPid As Word
798 vDriverVersion As MMVERSION
799 szPname[ELM(MAXPNAMELEN)] As Char
800End Type
801
802Type MIXERLINEA
803 cbStruct As DWord
804 dwDestination As DWord
805 dwSource As DWord
806 dwLineID As DWord
807 fdwLine As DWord
808 dwUser As DWord
809 dwComponentType As DWord
810 cChannels As DWord
811 cConnections As DWord
812 cControls As DWord
813 szShortName[ELM(MIXER_SHORT_NAME_CHARS)] As Char
814 szName[ELM(MIXER_LONG_NAME_CHARS)] As Char
815 Target As TARGET
816End Type
817TypeDef PMIXERLINEA = *MIXERLINEA
818TypeDef LPMIXERLINEA = *MIXERLINEA
819
820TypeDef MIXERLINE = MIXERLINEA
821TypeDef PMIXERLINE = PMIXERLINEA
822TypeDef LPMIXERLINE = LPMIXERLINEA
823
824' MIXERLINE.fdwLine
825Const MIXERLINE_LINEF_ACTIVE = &H00000001
826Const MIXERLINE_LINEF_DISCONNECTED = &H00008000
827Const MIXERLINE_LINEF_SOURCE = &H80000000
828
829' MIXERLINE.dwComponentType
830Const MIXERLINE_COMPONENTTYPE_DST_FIRST = &H00000000
831Const MIXERLINE_COMPONENTTYPE_DST_UNDEFINED = (MIXERLINE_COMPONENTTYPE_DST_FIRST + 0)
832Const MIXERLINE_COMPONENTTYPE_DST_DIGITAL = (MIXERLINE_COMPONENTTYPE_DST_FIRST + 1)
833Const MIXERLINE_COMPONENTTYPE_DST_LINE = (MIXERLINE_COMPONENTTYPE_DST_FIRST + 2)
834Const MIXERLINE_COMPONENTTYPE_DST_MONITOR = (MIXERLINE_COMPONENTTYPE_DST_FIRST + 3)
835Const MIXERLINE_COMPONENTTYPE_DST_SPEAKERS = (MIXERLINE_COMPONENTTYPE_DST_FIRST + 4)
836Const MIXERLINE_COMPONENTTYPE_DST_HEADPHONES = (MIXERLINE_COMPONENTTYPE_DST_FIRST + 5)
837Const MIXERLINE_COMPONENTTYPE_DST_TELEPHONE = (MIXERLINE_COMPONENTTYPE_DST_FIRST + 6)
838Const MIXERLINE_COMPONENTTYPE_DST_WAVEIN = (MIXERLINE_COMPONENTTYPE_DST_FIRST + 7)
839Const MIXERLINE_COMPONENTTYPE_DST_VOICEIN = (MIXERLINE_COMPONENTTYPE_DST_FIRST + 8)
840Const MIXERLINE_COMPONENTTYPE_DST_LAST = (MIXERLINE_COMPONENTTYPE_DST_FIRST + 8)
841
842Const MIXERLINE_COMPONENTTYPE_SRC_FIRST = &H00001000
843Const MIXERLINE_COMPONENTTYPE_SRC_UNDEFINED = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 0)
844Const MIXERLINE_COMPONENTTYPE_SRC_DIGITAL = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 1)
845Const MIXERLINE_COMPONENTTYPE_SRC_LINE = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 2)
846Const MIXERLINE_COMPONENTTYPE_SRC_MICROPHONE = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 3)
847Const MIXERLINE_COMPONENTTYPE_SRC_SYNTHESIZER = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 4)
848Const MIXERLINE_COMPONENTTYPE_SRC_COMPACTDISC = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 5)
849Const MIXERLINE_COMPONENTTYPE_SRC_TELEPHONE = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 6)
850Const MIXERLINE_COMPONENTTYPE_SRC_PCSPEAKER = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 7)
851Const MIXERLINE_COMPONENTTYPE_SRC_WAVEOUT = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 8)
852Const MIXERLINE_COMPONENTTYPE_SRC_AUXILIARY = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 9)
853Const MIXERLINE_COMPONENTTYPE_SRC_ANALOG = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 10)
854Const MIXERLINE_COMPONENTTYPE_SRC_LAST = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 10)
855
856' MIXERLINE.Target.dwType
857Const MIXERLINE_TARGETTYPE_UNDEFINED = 0
858Const MIXERLINE_TARGETTYPE_WAVEOUT = 1
859Const MIXERLINE_TARGETTYPE_WAVEIN = 2
860Const MIXERLINE_TARGETTYPE_MIDIOUT = 3
861Const MIXERLINE_TARGETTYPE_MIDIIN = 4
862Const MIXERLINE_TARGETTYPE_AUX = 5
863
864Declare Function mixerGetLineInfo Lib "winmm" Alias "mixerGetLineInfoA" (hmxobj As HMIXEROBJ, pmxl As *MIXERLINE, fdwInfo As DWord) As MMRESULT
865
866Const MIXER_GETLINEINFOF_DESTINATION = &H00000000
867Const MIXER_GETLINEINFOF_SOURCE = &H00000001
868Const MIXER_GETLINEINFOF_LINEID = &H00000002
869Const MIXER_GETLINEINFOF_COMPONENTTYPE = &H00000003
870Const MIXER_GETLINEINFOF_TARGETTYPE = &H00000004
871Const MIXER_GETLINEINFOF_QUERYMASK = &H0000000F
872
873Declare Function mixerGetID Lib "winmm" (hmxobj As HMIXEROBJ, puMxId As *DWord, fdwId As DWord) As MMRESULT
874
875Type MIXERCONTROLA
876 cbStruct As DWord
877 dwControlID As DWord
878 dwControlType As DWord
879 fdwControl As DWord
880 cMultipleItems As DWord
881 szShortName[ELM(MIXER_SHORT_NAME_CHARS)] As Char
882 szName[ELM(MIXER_LONG_NAME_CHARS)] As Char
883 Bounds[ELM(6)] As DWord
884 Metrics[ELM(6)] As DWord
885End Type
886TypeDef PMIXERCONTROLA = *MIXERCONTROLA
887TypeDef LPMIXERCONTROLA = *MIXERCONTROLA
888
889TypeDef MIXERCONTROL = MIXERCONTROLA
890TypeDef PMIXERCONTROL = PMIXERCONTROLA
891TypeDef LPMIXERCONTROL = LPMIXERCONTROLA
892
893' MIXERCONTROL.fdwControl
894Const MIXERCONTROL_CONTROLF_UNIFORM = &H00000001
895Const MIXERCONTROL_CONTROLF_MULTIPLE = &H00000002
896Const MIXERCONTROL_CONTROLF_DISABLED = &H80000000
897
898' MIXERCONTROL_CONTROLTYPE_xxx
899Const MIXERCONTROL_CT_CLASS_MASK = &HF0000000
900Const MIXERCONTROL_CT_CLASS_CUSTOM = &H00000000
901Const MIXERCONTROL_CT_CLASS_METER = &H10000000
902Const MIXERCONTROL_CT_CLASS_SWITCH = &H20000000
903Const MIXERCONTROL_CT_CLASS_NUMBER = &H30000000
904Const MIXERCONTROL_CT_CLASS_SLIDER = &H40000000
905Const MIXERCONTROL_CT_CLASS_FADER = &H50000000
906Const MIXERCONTROL_CT_CLASS_TIME = &H60000000
907Const MIXERCONTROL_CT_CLASS_LIST = &H70000000
908Const MIXERCONTROL_CT_SUBCLASS_MASK = &H0F000000
909Const MIXERCONTROL_CT_SC_SWITCH_BOOLEAN = &H00000000
910Const MIXERCONTROL_CT_SC_SWITCH_BUTTON = &H01000000
911Const MIXERCONTROL_CT_SC_METER_POLLED = &H00000000
912Const MIXERCONTROL_CT_SC_TIME_MICROSECS = &H00000000
913Const MIXERCONTROL_CT_SC_TIME_MILLISECS = &H01000000
914Const MIXERCONTROL_CT_SC_LIST_SINGLE = &H00000000
915Const MIXERCONTROL_CT_SC_LIST_MULTIPLE = &H01000000
916Const MIXERCONTROL_CT_UNITS_MASK = &H00FF0000
917Const MIXERCONTROL_CT_UNITS_CUSTOM = &H00000000
918Const MIXERCONTROL_CT_UNITS_BOOLEAN = &H00010000
919Const MIXERCONTROL_CT_UNITS_SIGNED = &H00020000
920Const MIXERCONTROL_CT_UNITS_UNSIGNED = &H00030000
921Const MIXERCONTROL_CT_UNITS_DECIBELS = &H00040000
922Const MIXERCONTROL_CT_UNITS_PERCENT = &H00050000
923
924' MIXERCONTROL.dwControlType
925Const MIXERCONTROL_CONTROLTYPE_CUSTOM = (MIXERCONTROL_CT_CLASS_CUSTOM OR MIXERCONTROL_CT_UNITS_CUSTOM)
926Const MIXERCONTROL_CONTROLTYPE_BOOLEANMETER = (MIXERCONTROL_CT_CLASS_METER OR MIXERCONTROL_CT_SC_METER_POLLED OR MIXERCONTROL_CT_UNITS_BOOLEAN)
927Const MIXERCONTROL_CONTROLTYPE_SIGNEDMETER = (MIXERCONTROL_CT_CLASS_METER OR MIXERCONTROL_CT_SC_METER_POLLED OR MIXERCONTROL_CT_UNITS_SIGNED)
928Const MIXERCONTROL_CONTROLTYPE_PEAKMETER = (MIXERCONTROL_CONTROLTYPE_SIGNEDMETER + 1)
929Const MIXERCONTROL_CONTROLTYPE_UNSIGNEDMETER = (MIXERCONTROL_CT_CLASS_METER OR MIXERCONTROL_CT_SC_METER_POLLED OR MIXERCONTROL_CT_UNITS_UNSIGNED)
930Const MIXERCONTROL_CONTROLTYPE_BOOLEAN = (MIXERCONTROL_CT_CLASS_SWITCH OR MIXERCONTROL_CT_SC_SWITCH_BOOLEAN OR MIXERCONTROL_CT_UNITS_BOOLEAN)
931Const MIXERCONTROL_CONTROLTYPE_ONOFF = (MIXERCONTROL_CONTROLTYPE_BOOLEAN + 1)
932Const MIXERCONTROL_CONTROLTYPE_MUTE = (MIXERCONTROL_CONTROLTYPE_BOOLEAN + 2)
933Const MIXERCONTROL_CONTROLTYPE_MONO = (MIXERCONTROL_CONTROLTYPE_BOOLEAN + 3)
934Const MIXERCONTROL_CONTROLTYPE_LOUDNESS = (MIXERCONTROL_CONTROLTYPE_BOOLEAN + 4)
935Const MIXERCONTROL_CONTROLTYPE_STEREOENH = (MIXERCONTROL_CONTROLTYPE_BOOLEAN + 5)
936Const MIXERCONTROL_CONTROLTYPE_BUTTON = (MIXERCONTROL_CT_CLASS_SWITCH OR MIXERCONTROL_CT_SC_SWITCH_BUTTON OR MIXERCONTROL_CT_UNITS_BOOLEAN)
937Const MIXERCONTROL_CONTROLTYPE_DECIBELS = (MIXERCONTROL_CT_CLASS_NUMBER OR MIXERCONTROL_CT_UNITS_DECIBELS)
938Const MIXERCONTROL_CONTROLTYPE_SIGNED = (MIXERCONTROL_CT_CLASS_NUMBER OR MIXERCONTROL_CT_UNITS_SIGNED)
939Const MIXERCONTROL_CONTROLTYPE_UNSIGNED = (MIXERCONTROL_CT_CLASS_NUMBER OR MIXERCONTROL_CT_UNITS_UNSIGNED)
940Const MIXERCONTROL_CONTROLTYPE_PERCENT = (MIXERCONTROL_CT_CLASS_NUMBER OR MIXERCONTROL_CT_UNITS_PERCENT)
941Const MIXERCONTROL_CONTROLTYPE_SLIDER = (MIXERCONTROL_CT_CLASS_SLIDER OR MIXERCONTROL_CT_UNITS_SIGNED)
942Const MIXERCONTROL_CONTROLTYPE_PAN = (MIXERCONTROL_CONTROLTYPE_SLIDER + 1)
943Const MIXERCONTROL_CONTROLTYPE_QSOUNDPAN = (MIXERCONTROL_CONTROLTYPE_SLIDER + 2)
944Const MIXERCONTROL_CONTROLTYPE_FADER = (MIXERCONTROL_CT_CLASS_FADER OR MIXERCONTROL_CT_UNITS_UNSIGNED)
945Const MIXERCONTROL_CONTROLTYPE_VOLUME = (MIXERCONTROL_CONTROLTYPE_FADER + 1)
946Const MIXERCONTROL_CONTROLTYPE_BASS = (MIXERCONTROL_CONTROLTYPE_FADER + 2)
947Const MIXERCONTROL_CONTROLTYPE_TREBLE = (MIXERCONTROL_CONTROLTYPE_FADER + 3)
948Const MIXERCONTROL_CONTROLTYPE_EQUALIZER = (MIXERCONTROL_CONTROLTYPE_FADER + 4)
949Const MIXERCONTROL_CONTROLTYPE_SINGLESELECT = (MIXERCONTROL_CT_CLASS_LIST OR MIXERCONTROL_CT_SC_LIST_SINGLE OR MIXERCONTROL_CT_UNITS_BOOLEAN)
950Const MIXERCONTROL_CONTROLTYPE_MUX = (MIXERCONTROL_CONTROLTYPE_SINGLESELECT + 1)
951Const MIXERCONTROL_CONTROLTYPE_MULTIPLESELECT = (MIXERCONTROL_CT_CLASS_LIST OR MIXERCONTROL_CT_SC_LIST_MULTIPLE OR MIXERCONTROL_CT_UNITS_BOOLEAN)
952Const MIXERCONTROL_CONTROLTYPE_MIXER = (MIXERCONTROL_CONTROLTYPE_MULTIPLESELECT + 1)
953Const MIXERCONTROL_CONTROLTYPE_MICROTIME = (MIXERCONTROL_CT_CLASS_TIME OR MIXERCONTROL_CT_SC_TIME_MICROSECS OR MIXERCONTROL_CT_UNITS_UNSIGNED)
954Const MIXERCONTROL_CONTROLTYPE_MILLITIME = (MIXERCONTROL_CT_CLASS_TIME OR MIXERCONTROL_CT_SC_TIME_MILLISECS OR MIXERCONTROL_CT_UNITS_UNSIGNED)
955
956Type MIXERLINECONTROLSA
957 cbStruct As DWord
958 dwLineID As DWord
959 dwControl_ID_Type As DWord
960 cControls As DWord
961 cbmxctrl As DWord
962 pamxctrl As *MIXERCONTROL
963End Type
[76]964TypeDef PMIXERLINECONTROLSA = *MIXERLINECONTROLSA
[75]965TypeDef LPMIXERLINECONTROLSA = *MIXERLINECONTROLSA
966
967TypeDef MIXERLINECONTROLS = MIXERLINECONTROLSA
968TypeDef PMIXERLINECONTROLS = PMIXERLINECONTROLSA
969TypeDef LPMIXERLINECONTROLS = LPMIXERLINECONTROLSA
970
971Declare Function mixerGetLineControls Lib "winmm" Alias "mixerGetLineControlsA" (hmxobj As HMIXEROBJ, pmxlc As *MIXERLINECONTROLS, fdwControls As DWord) As MMRESULT
972
973Const MIXER_GETLINECONTROLSF_ALL = &H00000000
974Const MIXER_GETLINECONTROLSF_ONEBYID = &H00000001
975Const MIXER_GETLINECONTROLSF_ONEBYTYPE = &H00000002
976Const MIXER_GETLINECONTROLSF_QUERYMASK = &H0000000F
977
978Type MIXERCONTROLDETAILS
979 cbStruct As DWord
980 dwControlID As DWord
981 cChannels As DWord
982 cMultipleItems As DWord
983 cbDetails As DWord
984 paDetails As VoidPtr
985End Type
986TypeDef PMIXERCONTROLDETAILS = *MIXERCONTROLDETAILS
987TypeDef LPMIXERCONTROLDETAILS = *MIXERCONTROLDETAILS
988
989Type MIXERCONTROLDETAILS_LISTTEXTA
990 dwParam1 As DWord
991 dwParam2 As DWord
992 szName[ELM(MIXER_LONG_NAME_CHARS)] As Char
993End Type
994TypeDef PMIXERCONTROLDETAILS_LISTTEXTA = *MIXERCONTROLDETAILS_LISTTEXTA
995TypeDef LPMIXERCONTROLDETAILS_LISTTEXTA = *MIXERCONTROLDETAILS_LISTTEXTA
996
997TypeDef MIXERCONTROLDETAILS_LISTTEXT = MIXERCONTROLDETAILS_LISTTEXTA
998TypeDef PMIXERCONTROLDETAILS_LISTTEXT = PMIXERCONTROLDETAILS_LISTTEXTA
999TypeDef LPMIXERCONTROLDETAILS_LISTTEXT = LPMIXERCONTROLDETAILS_LISTTEXTA
1000
1001Type MIXERCONTROLDETAILS_BOOLEAN
1002 fValue As Long
1003End Type
1004TypeDef PMIXERCONTROLDETAILS_BOOLEAN = *MIXERCONTROLDETAILS_BOOLEAN
1005TypeDef LPMIXERCONTROLDETAILS_BOOLEAN = *MIXERCONTROLDETAILS_BOOLEAN
1006
1007Type MIXERCONTROLDETAILS_SIGNED
1008 lValue As Long
1009End Type
1010TypeDef PMIXERCONTROLDETAILS_SIGNED = *MIXERCONTROLDETAILS_SIGNED
1011TypeDef LPMIXERCONTROLDETAILS_SIGNED = *MIXERCONTROLDETAILS_SIGNED
1012
1013Type MIXERCONTROLDETAILS_UNSIGNED
1014 dwValue As DWord
1015End Type
1016TypeDef PMIXERCONTROLDETAILS_UNSIGNED = *MIXERCONTROLDETAILS_UNSIGNED
1017TypeDef LPMIXERCONTROLDETAILS_UNSIGNED = *MIXERCONTROLDETAILS_UNSIGNED
1018
1019Declare Function mixerGetControlDetailsA Lib "winmm" (hmxobj As HMIXEROBJ, pmxcd As *MIXERCONTROLDETAILS, fdwDetails As DWord) As MMRESULT
1020Declare Function mixerGetControlDetailsW Lib "winmm" (hmxobj As HMIXEROBJ, pmxcd As *MIXERCONTROLDETAILS, fdwDetails As DWord) As MMRESULT
1021Declare Function mixerGetControlDetails Lib "winmm" Alias "mixerGetControlDetailsA" (hmxobj As HMIXEROBJ, pmxcd As *MIXERCONTROLDETAILS, fdwDetails As DWord) As MMRESULT
1022
1023Const MIXER_GETCONTROLDETAILSF_VALUE = &H00000000
1024Const MIXER_GETCONTROLDETAILSF_LISTTEXT = &H00000001
1025Const MIXER_GETCONTROLDETAILSF_QUERYMASK = &H0000000F
1026
1027Declare Function mixerSetControlDetails Lib "winmm" (hmxobj As HMIXEROBJ, pmxcd As *MIXERCONTROLDETAILS, fdwDetails As DWord) As MMRESULT
1028
1029Const MIXER_SETCONTROLDETAILSF_VALUE = &H00000000
1030Const MIXER_SETCONTROLDETAILSF_CUSTOM = &H00000001
1031Const MIXER_SETCONTROLDETAILSF_QUERYMASK = &H0000000F
1032
1033
1034'--------------------------------------------------------
1035' Timer support
1036
1037' timer error
1038Const TIMERR_NOERROR = (0)
1039Const TIMERR_NOCANDO = (TIMERR_BASE+1)
1040Const TIMERR_STRUCT = (TIMERR_BASE+33)
1041
1042TypeDef LPTIMECALLBACK = *Sub(uTimerID As DWord, uMsg As DWord, dwUser As DWord, dw1 As DWord, dw2 As DWord)
1043
1044Const TIME_ONESHOT = &H0000
1045Const TIME_PERIODIC = &H0001
1046
1047Const TIME_CALLBACK_FUNCTION = &H0000
1048Const TIME_CALLBACK_EVENT_SET = &H0010
1049Const TIME_CALLBACK_EVENT_PULSE = &H0020
1050
1051' timer device capabilities data structure
1052Type TIMECAPS
1053 wPeriodMin As DWord
1054 wPeriodMax As DWord
1055End Type
1056TypeDef PTIMECAPS = *TIMECAPS
1057TypeDef NPTIMECAPS = *TIMECAPS
1058TypeDef LPTIMECAPS = *TIMECAPS
1059
1060' timer function prototypes
1061Declare Function timeGetSystemTime Lib "winmm" (pmmt As *MMTIME, cbmmt As DWord) As MMRESULT
1062Declare Function timeGetTime Lib "winmm" () As DWord
1063Declare Function timeSetEvent Lib "winmm" (uDelay As DWord, uResolution As DWord, fptc As LPTIMECALLBACK, dwUser As DWord, fuEvent As DWord) As MMRESULT
1064Declare Function timeKillEvent Lib "winmm" (uTimerID As DWord) As MMRESULT
1065Declare Function timeGetDevCaps Lib "winmm" (ptc As *TIMECAPS, cbtc As DWord) As MMRESULT
1066Declare Function timeBeginPeriod Lib "winmm" (uPeriod As DWord) As MMRESULT
1067Declare Function timeEndPeriod Lib "winmm" (uPeriod As DWord) As MMRESULT
1068
1069
1070'--------------------------------------------------------
1071' Joystick support
1072
1073' joystick error
1074Const JOYERR_NOERROR = (0)
1075Const JOYERR_PARMS = (JOYERR_BASE+5)
1076Const JOYERR_NOCANDO = (JOYERR_BASE+6)
1077Const JOYERR_UNPLUGGED = (JOYERR_BASE+7)
1078
1079' constants used with JOYINFO and JOYINFOEX structures and MM_JOY* messages
1080Const JOY_BUTTON1 = &H0001
1081Const JOY_BUTTON2 = &H0002
1082Const JOY_BUTTON3 = &H0004
1083Const JOY_BUTTON4 = &H0008
1084Const JOY_BUTTON1CHG = &H0100
1085Const JOY_BUTTON2CHG = &H0200
1086Const JOY_BUTTON3CHG = &H0400
1087Const JOY_BUTTON4CHG = &H0800
1088
1089' constants used with JOYINFOEX
1090Const JOY_BUTTON5 = &H00000010
1091Const JOY_BUTTON6 = &H00000020
1092Const JOY_BUTTON7 = &H00000040
1093Const JOY_BUTTON8 = &H00000080
1094Const JOY_BUTTON9 = &H00000100
1095Const JOY_BUTTON10 = &H00000200
1096Const JOY_BUTTON11 = &H00000400
1097Const JOY_BUTTON12 = &H00000800
1098Const JOY_BUTTON13 = &H00001000
1099Const JOY_BUTTON14 = &H00002000
1100Const JOY_BUTTON15 = &H00004000
1101Const JOY_BUTTON16 = &H00008000
1102Const JOY_BUTTON17 = &H00010000
1103Const JOY_BUTTON18 = &H00020000
1104Const JOY_BUTTON19 = &H00040000
1105Const JOY_BUTTON20 = &H00080000
1106Const JOY_BUTTON21 = &H00100000
1107Const JOY_BUTTON22 = &H00200000
1108Const JOY_BUTTON23 = &H00400000
1109Const JOY_BUTTON24 = &H00800000
1110Const JOY_BUTTON25 = &H01000000
1111Const JOY_BUTTON26 = &H02000000
1112Const JOY_BUTTON27 = &H04000000
1113Const JOY_BUTTON28 = &H08000000
1114Const JOY_BUTTON29 = &H10000000
1115Const JOY_BUTTON30 = &H20000000
1116Const JOY_BUTTON31 = &H40000000
1117Const JOY_BUTTON32 = &H80000000
1118
1119' constants used with JOYINFOEX structure
1120Const JOY_POVCENTERED = (-1)
1121Const JOY_POVFORWARD = 0
1122Const JOY_POVRIGHT = 9000
1123Const JOY_POVBACKWARD = 18000
1124Const JOY_POVLEFT = 27000
1125
1126Const JOY_RETURNX = &H00000001
1127Const JOY_RETURNY = &H00000002
1128Const JOY_RETURNZ = &H00000004
1129Const JOY_RETURNR = &H00000008
1130Const JOY_RETURNU = &H00000010
1131Const JOY_RETURNV = &H00000020
1132Const JOY_RETURNPOV = &H00000040
1133Const JOY_RETURNBUTTONS = &H00000080
1134Const JOY_RETURNRAWDATA = &H00000100
1135Const JOY_RETURNPOVCTS = &H00000200
1136Const JOY_RETURNCENTERED = &H00000400
1137Const JOY_USEDEADZONE = &H00000800
1138Const JOY_RETURNALL = (JOY_RETURNX OR JOY_RETURNY OR JOY_RETURNZ OR JOY_RETURNR OR JOY_RETURNU OR JOY_RETURNV OR JOY_RETURNPOV OR JOY_RETURNBUTTONS)
1139Const JOY_CAL_READALWAYS = &H00010000
1140Const JOY_CAL_READXYONLY = &H00020000
1141Const JOY_CAL_READ3 = &H00040000
1142Const JOY_CAL_READ4 = &H00080000
1143Const JOY_CAL_READXONLY = &H00100000
1144Const JOY_CAL_READYONLY = &H00200000
1145Const JOY_CAL_READ5 = &H00400000
1146Const JOY_CAL_READ6 = &H00800000
1147Const JOY_CAL_READZONLY = &H01000000
1148Const JOY_CAL_READRONLY = &H02000000
1149Const JOY_CAL_READUONLY = &H04000000
1150Const JOY_CAL_READVONLY = &H08000000
1151
1152' joystick ID constants
1153Const JOYSTICKID1 = 0
1154Const JOYSTICKID2 = 1
1155
1156' joystick driver capabilites
1157Const JOYCAPS_HASZ = &H0001
1158Const JOYCAPS_HASR = &H0002
1159Const JOYCAPS_HASU = &H0004
1160Const JOYCAPS_HASV = &H0008
1161Const JOYCAPS_HASPOV = &H0010
1162Const JOYCAPS_POV4DIR = &H0020
1163Const JOYCAPS_POVCTS = &H0040
1164
1165Type JOYCAPSA
1166 wMid As Word
1167 wPid As Word
1168 szPname[ELM(MAXPNAMELEN)] As Char
1169 wXmin As DWord
1170 wXmax As DWord
1171 wYmin As DWord
1172 wYmax As DWord
1173 wZmin As DWord
1174 wZmax As DWord
1175 wNumButtons As DWord
1176 wPeriodMin As DWord
1177 wPeriodMax As DWord
1178 wRmin As DWord
1179 wRmax As DWord
1180 wUmin As DWord
1181 wUmax As DWord
1182 wVmin As DWord
1183 wVmax As DWord
1184 wCaps As DWord
1185 wMaxAxes As DWord
1186 wNumAxes As DWord
1187 wMaxButtons As DWord
1188 szRegKey[ELM(MAXPNAMELEN)] As Char
1189 szOEMVxD[ELM(MAX_JOYSTICKOEMVXDNAME)] As Char
1190End Type
1191TypeDef PJOYCAPSA = *JOYCAPSA
1192TypeDef NPJOYCAPSA = *JOYCAPSA
1193TypeDef LPJOYCAPSA = *JOYCAPSA
1194
1195TypeDef JOYCAPS = JOYCAPSA
1196TypeDef PJOYCAPS = PJOYCAPSA
1197TypeDef NPJOYCAPS = NPJOYCAPSA
1198TypeDef LPJOYCAPS = LPJOYCAPSA
1199
1200Type JOYINFO
1201 wXpos As DWord
1202 wYpos As DWord
1203 wZpos As DWord
1204 wButtons As DWord
1205End Type
[76]1206TypeDef PJOYINFO = *JOYINFO
[75]1207TypeDef NPJOYINFO = *JOYINFO
1208TypeDef LPJOYINFO = *JOYINFO
1209
1210Type JOYINFOEX
1211 dwSize As DWord
1212 dwFlags As DWord
1213 dwXpos As DWord
1214 dwYpos As DWord
1215 dwZpos As DWord
1216 dwRpos As DWord
1217 dwUpos As DWord
1218 dwVpos As DWord
1219 dwButtons As DWord
1220 dwButtonNumber As DWord
1221 dwPOV As DWord
1222 dwReserved1 As DWord
1223 dwReserved2 As DWord
1224End Type
1225TypeDef PJOYINFOEX = *JOYINFOEX
1226TypeDef NPJOYINFOEX = *JOYINFOEX
1227TypeDef LPJOYINFOEX = *JOYINFOEX
1228
1229' joystick function prototypes
1230Declare Function joyGetNumDevs Lib "winmm" () As DWord
1231Declare Function joyGetDevCaps Lib "winmm" Alias "joyGetDevCapsA" (uJoyID As DWord, pjc As *JOYCAPS, cbjc As DWord) As MMRESULT
1232Declare Function joyGetPos Lib "winmm" (uJoyID As DWord, pji As *JOYINFO) As MMRESULT
1233Declare Function joyGetPosEx Lib "winmm" (uJoyID As DWord, pji As *JOYINFOEX) As MMRESULT
1234Declare Function joyGetThreshold Lib "winmm" (uJoyID As DWord, puThreshold As *DWord) As MMRESULT
1235Declare Function joyReleaseCapture Lib "winmm" (uJoyID As DWord) As MMRESULT
1236Declare Function joySetCapture Lib "winmm" (hwnd As HWND, uJoyID As DWord, uPeriod As DWord, fChanged As BOOL) As MMRESULT
1237Declare Function joySetThreshold Lib "winmm" (uJoyID As DWord, uThreshold As DWord) As MMRESULT
1238
1239
1240'--------------------------------------------------------
1241' Multimedia File I/O support
1242
1243' MMIO error return values
1244Const MMIOERR_BASE = 256
1245Const MMIOERR_FILENOTFOUND = (MMIOERR_BASE + 1)
1246Const MMIOERR_OUTOFMEMORY = (MMIOERR_BASE + 2)
1247Const MMIOERR_CANNOTOPEN = (MMIOERR_BASE + 3)
1248Const MMIOERR_CANNOTCLOSE = (MMIOERR_BASE + 4)
1249Const MMIOERR_CANNOTREAD = (MMIOERR_BASE + 5)
1250Const MMIOERR_CANNOTWRITE = (MMIOERR_BASE + 6)
1251Const MMIOERR_CANNOTSEEK = (MMIOERR_BASE + 7)
1252Const MMIOERR_CANNOTEXPAND = (MMIOERR_BASE + 8)
1253Const MMIOERR_CHUNKNOTFOUND = (MMIOERR_BASE + 9)
1254Const MMIOERR_UNBUFFERED = (MMIOERR_BASE + 10)
1255Const MMIOERR_PATHNOTFOUND = (MMIOERR_BASE + 11)
1256Const MMIOERR_ACCESSDENIED = (MMIOERR_BASE + 12)
1257Const MMIOERR_SHARINGVIOLATION = (MMIOERR_BASE + 13)
1258Const MMIOERR_NETWORKERROR = (MMIOERR_BASE + 14)
1259Const MMIOERR_TOOMANYOPENFILES = (MMIOERR_BASE + 15)
1260Const MMIOERR_INVALIDFILE = (MMIOERR_BASE + 16)
1261
1262' MMIO constants
1263Const CFSEPCHAR = "+"
1264
1265' MMIO data types
1266TypeDef FOURCC = DWord
1267TypeDef HPSTR = *Char
1268TypeDef HMMIO = VoidPtr
1269
1270TypeDef LPMMIOPROC = *Function(lpmmioinfo As LPSTR, uMsg As DWord, lParam1 As LPARAM, lParam2 As LPARAM) As LRESULT
1271
1272Type MMIOINFO
1273 dwFlags As DWord
1274 fccIOProc As FOURCC
1275 pIOProc As LPMMIOPROC
1276 wErrorRet As DWord
1277 htask As HTASK
1278 cchBuffer As Long
1279 pchBuffer As HPSTR
1280 pchNext As HPSTR
1281 pchEndRead As HPSTR
1282 pchEndWrite As HPSTR
1283 lBufOffset As Long
1284 lDiskOffset As Long
1285 adwInfo[ELM(3)] As DWord
1286 dwReserved1 As DWord
1287 dwReserved2 As DWord
1288 hmmio As HMMIO
1289End Type
1290TypeDef PMMIOINFO = *MMIOINFO
1291TypeDef NPMMIOINFO = *MMIOINFO
1292TypeDef LPMMIOINFO = *MMIOINFO
1293
1294Type MMCKINFO
1295 ckid As FOURCC
1296 cksize As DWord
1297 fccType As FOURCC
1298 dwDataOffset As DWord
1299 dwFlags As DWord
1300End Type
1301TypeDef PMMCKINFO = *MMCKINFO
1302TypeDef NPMMCKINFO = *MMCKINFO
1303TypeDef LPMMCKINFO = *MMCKINFO
1304
1305Const MMIO_RWMODE = &H00000003
1306Const MMIO_SHAREMODE = &H00000070
1307Const MMIO_CREATE = &H00001000
1308Const MMIO_PARSE = &H00000100
1309Const MMIO_DELETE = &H00000200
1310Const MMIO_EXIST = &H00004000
1311Const MMIO_ALLOCBUF = &H00010000
1312Const MMIO_GETTEMP = &H00020000
1313Const MMIO_DIRTY = &H10000000
1314Const MMIO_READ = &H00000000
1315Const MMIO_WRITE = &H00000001
1316Const MMIO_READWRITE = &H00000002
1317Const MMIO_COMPAT = &H00000000
1318Const MMIO_EXCLUSIVE = &H00000010
1319Const MMIO_DENYWRITE = &H00000020
1320Const MMIO_DENYREAD = &H00000030
1321Const MMIO_DENYNONE = &H00000040
1322Const MMIO_FHOPEN = &H0010
1323Const MMIO_EMPTYBUF = &H0010
1324Const MMIO_TOUPPER = &H0010
1325Const MMIO_INSTALLPROC = &H00010000
1326Const MMIO_GLOBALPROC = &H10000000
1327Const MMIO_REMOVEPROC = &H00020000
1328Const MMIO_UNICODEPROC = &H01000000
1329Const MMIO_FINDPROC = &H00040000
1330Const MMIO_FINDCHUNK = &H0010
1331Const MMIO_FINDRIFF = &H0020
1332Const MMIO_FINDLIST = &H0040
1333Const MMIO_CREATERIFF = &H0020
1334Const MMIO_CREATELIST = &H0040
1335
1336Const MMIOM_READ = MMIO_READ
1337Const MMIOM_WRITE = MMIO_WRITE
1338Const MMIOM_SEEK = 2
1339Const MMIOM_OPEN = 3
1340Const MMIOM_CLOSE = 4
1341Const MMIOM_WRITEFLUSH = 5
1342Const MMIOM_RENAME = 6
1343Const MMIOM_USER = &H8000
1344
1345Const FOURCC_RIFF = MAKEFOURCC(&H52, &H49, &H46, &H46)
1346Const FOURCC_LIST = MAKEFOURCC(&H4C, &H49, &H53, &H54)
1347Const FOURCC_DOS = MAKEFOURCC(&H44, &H4F, &H53, &H20)
1348Const FOURCC_MEM = MAKEFOURCC(&H4D, &H45, &H4D, &H20)
1349
1350Const SEEK_SET = 0
1351Const SEEK_CUR = 1
1352Const SEEK_END = 2
1353
1354Const MMIO_DEFAULTBUFFER = 8192
1355
1356Function mmioFOURCC(ch0 As String, ch1 As String, ch2 As String, ch3 As String) As FOURCC
1357 mmioFOURCC = MAKEFOURCC(Asc(ch0), Asc(ch1), Asc(ch2), Asc(ch3))
1358End Function
1359
1360' MMIO function prototypes
1361Declare Function mmioStringToFOURCC Lib "winmm" Alias "mmioStringToFOURCCA" (sz As LPSTR, uFlags As DWord) As FOURCC
1362Declare Function mmioInstallIOProc Lib "winmm" Alias "mmioInstallIOProcA" (fccIOProc As FOURCC, pIOProc As LPMMIOPROC, dwFlags As DWord) As LPMMIOPROC
1363Declare Function mmioOpen Lib "winmm" Alias "mmioOpenA" (pszFileName As LPSTR, pmmioinfo As *MMIOINFO, fdwOpen As DWord) As HMMIO
1364Declare Function mmioRename Lib "winmm" Alias "mmioRenameA" (pszFileName As LPSTR, pszNewFileName As LPSTR, pmmioinfo As *MMIOINFO, fdwRename As DWord) As MMRESULT
1365Declare Function mmioClose Lib "winmm" (hmmio As HMMIO, fuClose As DWord) As MMRESULT
1366Declare Function mmioRead Lib "winmm" (hmmio As HMMIO, pch As HPSTR, cch As Long) As Long
1367Declare Function mmioWrite Lib "winmm" (hmmio As HMMIO, pch As HPSTR, cch As Long) As Long
1368Declare Function mmioSeek Lib "winmm" (hmmio As HMMIO, lOffset As Long, iOrigin As Long) As Long
1369Declare Function mmioGetInfo Lib "winmm" (hmmio As HMMIO, pmmioinfo As *MMIOINFO, fuInfo As DWord) As MMRESULT
1370Declare Function mmioSetInfo Lib "winmm" (hmmio As HMMIO, pmmioinfo As *MMIOINFO, fuInfo As DWord) As MMRESULT
1371Declare Function mmioSetBuffer Lib "winmm" (hmmio As HMMIO, pchBuffer As LPSTR, cchBuffer As Long, fuBuffer As DWord) As MMRESULT
1372Declare Function mmioFlush Lib "winmm" (hmmio As HMMIO, fuFlush As DWord) As MMRESULT
1373Declare Function mmioAdvance Lib "winmm" (hmmio As HMMIO, pmmioinfo As *MMIOINFO, fuAdvance As DWord) As MMRESULT
1374Declare Function mmioSendMessage Lib "winmm" (hmmio As HMMIO, uMsg As DWord, lParam1 As LPARAM, lParam2 As LPARAM) As LRESULT
1375Declare Function mmioDescend Lib "winmm" (hmmio As HMMIO, pmmcki As *MMCKINFO, pmmckiParent As *MMCKINFO, fuDescend As DWord) As MMRESULT
1376Declare Function mmioAscend Lib "winmm" (hmmio As HMMIO, pmmcki As *MMCKINFO, fuAscend As DWord) As MMRESULT
1377Declare Function mmioCreateChunk Lib "winmm" (hmmio As HMMIO, pmmcki As *MMCKINFO, fuCreate As DWord) As MMRESULT
1378
1379
1380'--------------------------------------------------------
1381' MCI support
1382
[95]1383TypeDef MCIERROR = DWord
1384TypeDef MCIDEVICEID = DWord
1385TypeDef YIELDPROC = *Function(mciId As MCIDEVICEID, dwYieldData As DWord) As DWord
1386
1387' MCI Functions
1388Declare Function mciSendCommand Lib "winmm" Alias "mciSendCommandA" (mciId As MCIDEVICEID, uMsg As DWord, dwParam1 As DWord, ByRef dwParam2 As Any) As MCIERROR
1389Declare Function mciSendString Lib "winmm" Alias "mciSendStringA" (lpstrCommand As LPSTR, lpstrReturnString As LPSTR, uReturnLength As DWord, hwndCallback As HWND) As MCIERROR
1390Declare Function mciGetDeviceID Lib "winmm" Alias "mciGetDeviceIDA" (pszDevice As LPSTR) As MCIDEVICEID
1391
1392Declare Function mciGetErrorString Lib "winmm" Alias "mciGetErrorStringA" (mcierr As MCIERROR, pszText As LPSTR, cchText As DWord) As BOOL
1393Declare Function mciSetYieldProc Lib "winmm" (mciId As MCIDEVICEID, fpYieldProc As YIELDPROC, dwYieldData As DWord) As BOOL
1394Declare Function mciGetCreatorTask Lib "winmm" (mciId As MCIDEVICEID) As HTASK
1395Declare Function mciGetYieldProc Lib "winmm" (mciId As MCIDEVICEID, pdwYieldData As *DWord) As YIELDPROC
1396Declare Function mciExecute Lib "winmm" (pszCommand As LPSTR) As BOOL
1397
1398Const MCIERR_INVALID_DEVICE_ID = (MCIERR_BASE + 1)
1399Const MCIERR_UNRECOGNIZED_KEYWORD = (MCIERR_BASE + 3)
1400Const MCIERR_UNRECOGNIZED_COMMAND = (MCIERR_BASE + 5)
1401Const MCIERR_HARDWARE = (MCIERR_BASE + 6)
1402Const MCIERR_INVALID_DEVICE_NAME = (MCIERR_BASE + 7)
1403Const MCIERR_OUT_OF_MEMORY = (MCIERR_BASE + 8)
1404Const MCIERR_DEVICE_OPEN = (MCIERR_BASE + 9)
1405Const MCIERR_CANNOT_LOAD_DRIVER = (MCIERR_BASE + 10)
1406Const MCIERR_MISSING_COMMAND_STRING = (MCIERR_BASE + 11)
1407Const MCIERR_PARAM_OVERFLOW = (MCIERR_BASE + 12)
1408Const MCIERR_MISSING_STRING_ARGUMENT = (MCIERR_BASE + 13)
1409Const MCIERR_BAD_INTEGER = (MCIERR_BASE + 14)
1410Const MCIERR_PARSER_INTERNAL = (MCIERR_BASE + 15)
1411Const MCIERR_DRIVER_INTERNAL = (MCIERR_BASE + 16)
1412Const MCIERR_MISSING_PARAMETER = (MCIERR_BASE + 17)
1413Const MCIERR_UNSUPPORTED_FUNCTION = (MCIERR_BASE + 18)
1414Const MCIERR_FILE_NOT_FOUND = (MCIERR_BASE + 19)
1415Const MCIERR_DEVICE_NOT_READY = (MCIERR_BASE + 20)
1416Const MCIERR_INTERNAL = (MCIERR_BASE + 21)
1417Const MCIERR_DRIVER = (MCIERR_BASE + 22)
1418Const MCIERR_CANNOT_USE_ALL = (MCIERR_BASE + 23)
1419Const MCIERR_MULTIPLE = (MCIERR_BASE + 24)
1420Const MCIERR_EXTENSION_NOT_FOUND = (MCIERR_BASE + 25)
1421Const MCIERR_OUTOFRANGE = (MCIERR_BASE + 26)
1422Const MCIERR_FLAGS_NOT_COMPATIBLE = (MCIERR_BASE + 28)
1423Const MCIERR_FILE_NOT_SAVED = (MCIERR_BASE + 30)
1424Const MCIERR_DEVICE_TYPE_REQUIRED = (MCIERR_BASE + 31)
1425Const MCIERR_DEVICE_LOCKED = (MCIERR_BASE + 32)
1426Const MCIERR_DUPLICATE_ALIAS = (MCIERR_BASE + 33)
1427Const MCIERR_BAD_CONSTANT = (MCIERR_BASE + 34)
1428Const MCIERR_MUST_USE_SHAREABLE = (MCIERR_BASE + 35)
1429Const MCIERR_MISSING_DEVICE_NAME = (MCIERR_BASE + 36)
1430Const MCIERR_BAD_TIME_FORMAT = (MCIERR_BASE + 37)
1431Const MCIERR_NO_CLOSING_QUOTE = (MCIERR_BASE + 38)
1432Const MCIERR_DUPLICATE_FLAGS = (MCIERR_BASE + 39)
1433Const MCIERR_INVALID_FILE = (MCIERR_BASE + 40)
1434Const MCIERR_NULL_PARAMETER_BLOCK = (MCIERR_BASE + 41)
1435Const MCIERR_UNNAMED_RESOURCE = (MCIERR_BASE + 42)
1436Const MCIERR_NEW_REQUIRES_ALIAS = (MCIERR_BASE + 43)
1437Const MCIERR_NOTIFY_ON_AUTO_OPEN = (MCIERR_BASE + 44)
1438Const MCIERR_NO_ELEMENT_ALLOWED = (MCIERR_BASE + 45)
1439Const MCIERR_NONAPPLICABLE_FUNCTION = (MCIERR_BASE + 46)
1440Const MCIERR_ILLEGAL_FOR_AUTO_OPEN = (MCIERR_BASE + 47)
1441Const MCIERR_FILENAME_REQUIRED = (MCIERR_BASE + 48)
1442Const MCIERR_EXTRA_CHARACTERS = (MCIERR_BASE + 49)
1443Const MCIERR_DEVICE_NOT_INSTALLED = (MCIERR_BASE + 50)
1444Const MCIERR_GET_CD = (MCIERR_BASE + 51)
1445Const MCIERR_SET_CD = (MCIERR_BASE + 52)
1446Const MCIERR_SET_DRIVE = (MCIERR_BASE + 53)
1447Const MCIERR_DEVICE_LENGTH = (MCIERR_BASE + 54)
1448Const MCIERR_DEVICE_ORD_LENGTH = (MCIERR_BASE + 55)
1449Const MCIERR_NO_INTEGER = (MCIERR_BASE + 56)
1450
1451Const MCIERR_WAVE_OUTPUTSINUSE = (MCIERR_BASE + 64)
1452Const MCIERR_WAVE_SETOUTPUTINUSE = (MCIERR_BASE + 65)
1453Const MCIERR_WAVE_INPUTSINUSE = (MCIERR_BASE + 66)
1454Const MCIERR_WAVE_SETINPUTINUSE = (MCIERR_BASE + 67)
1455Const MCIERR_WAVE_OUTPUTUNSPECIFIED = (MCIERR_BASE + 68)
1456Const MCIERR_WAVE_INPUTUNSPECIFIED = (MCIERR_BASE + 69)
1457Const MCIERR_WAVE_OUTPUTSUNSUITABLE = (MCIERR_BASE + 70)
1458Const MCIERR_WAVE_SETOUTPUTUNSUITABLE = (MCIERR_BASE + 71)
1459Const MCIERR_WAVE_INPUTSUNSUITABLE = (MCIERR_BASE + 72)
1460Const MCIERR_WAVE_SETINPUTUNSUITABLE = (MCIERR_BASE + 73)
1461
1462Const MCIERR_SEQ_DIV_INCOMPATIBLE = (MCIERR_BASE + 80)
1463Const MCIERR_SEQ_PORT_INUSE = (MCIERR_BASE + 81)
1464Const MCIERR_SEQ_PORT_NONEXISTENT = (MCIERR_BASE + 82)
1465Const MCIERR_SEQ_PORT_MAPNODEVICE = (MCIERR_BASE + 83)
1466Const MCIERR_SEQ_PORT_MISCERROR = (MCIERR_BASE + 84)
1467Const MCIERR_SEQ_TIMER = (MCIERR_BASE + 85)
1468Const MCIERR_SEQ_PORTUNSPECIFIED = (MCIERR_BASE + 86)
1469Const MCIERR_SEQ_NOMIDIPRESENT = (MCIERR_BASE + 87)
1470
1471Const MCIERR_NO_WINDOW = (MCIERR_BASE + 90)
1472Const MCIERR_CREATEWINDOW = (MCIERR_BASE + 91)
1473Const MCIERR_FILE_READ = (MCIERR_BASE + 92)
1474Const MCIERR_FILE_WRITE = (MCIERR_BASE + 93)
1475Const MCIERR_NO_IDENTITY = (MCIERR_BASE + 94)
1476Const MCIERR_CUSTOM_DRIVER_BASE = (MCIERR_BASE + 256)
1477
1478Const MCI_FIRST = DRV_MCI_FIRST
1479Const MCI_OPEN = &H0803
1480Const MCI_CLOSE = &H0804
1481Const MCI_ESCAPE = &H0805
1482Const MCI_PLAY = &H0806
1483Const MCI_SEEK = &H0807
1484Const MCI_STOP = &H0808
1485Const MCI_PAUSE = &H0809
1486Const MCI_INFO = &H080A
1487Const MCI_GETDEVCAPS = &H080B
1488Const MCI_SPIN = &H080C
1489Const MCI_SET = &H080D
1490Const MCI_STEP = &H080E
1491Const MCI_RECORD = &H080F
1492Const MCI_SYSINFO = &H0810
1493Const MCI_BREAK = &H0811
1494Const MCI_SAVE = &H0813
1495Const MCI_STATUS = &H0814
1496Const MCI_CUE = &H0830
1497Const MCI_REALIZE = &H0840
1498Const MCI_WINDOW = &H0841
1499Const MCI_PUT = &H0842
1500Const MCI_WHERE = &H0843
1501Const MCI_FREEZE = &H0844
1502Const MCI_UNFREEZE = &H0845
1503Const MCI_LOAD = &H0850
1504Const MCI_CUT = &H0851
1505Const MCI_COPY = &H0852
1506Const MCI_PASTE = &H0853
1507Const MCI_UPDATE = &H0854
1508Const MCI_RESUME = &H0855
1509Const MCI_DELETE = &H0856
1510
1511Const MCI_USER_MESSAGES = (DRV_MCI_FIRST + &H400)
1512Const MCI_LAST = &H0FFF
1513
1514Const MCI_ALL_DEVICE_ID = (-1)
1515
1516' constants for predefined MCI device types
1517Const MCI_DEVTYPE_VCR = 513
1518Const MCI_DEVTYPE_VIDEODISC = 514
1519Const MCI_DEVTYPE_OVERLAY = 515
1520Const MCI_DEVTYPE_CD_AUDIO = 516
1521Const MCI_DEVTYPE_DAT = 517
1522Const MCI_DEVTYPE_SCANNER = 518
1523Const MCI_DEVTYPE_ANIMATION = 519
1524Const MCI_DEVTYPE_DIGITAL_VIDEO = 520
1525Const MCI_DEVTYPE_OTHER = 521
1526Const MCI_DEVTYPE_WAVEFORM_AUDIO = 522
1527Const MCI_DEVTYPE_SEQUENCER = 523
1528Const MCI_DEVTYPE_FIRST = MCI_DEVTYPE_VCR
1529Const MCI_DEVTYPE_LAST = MCI_DEVTYPE_SEQUENCER
1530Const MCI_DEVTYPE_FIRST_USER = &H1000
1531
1532' return values for 'status mode' command
1533Const MCI_MODE_NOT_READY = MCI_STRING_OFFSET + 12
1534Const MCI_MODE_STOP = MCI_STRING_OFFSET + 13
1535Const MCI_MODE_PLAY = MCI_STRING_OFFSET + 14
1536Const MCI_MODE_RECORD = MCI_STRING_OFFSET + 15
1537Const MCI_MODE_SEEK = MCI_STRING_OFFSET + 16
1538Const MCI_MODE_PAUSE = MCI_STRING_OFFSET + 17
1539Const MCI_MODE_OPEN = MCI_STRING_OFFSET + 18
1540
[75]1541'--------------------------------------------------------
[1]1542' Time Format(used in MCI_SET_PARAMS, MCI_STATUS_PARAMS)
1543
1544Const MCI_FORMAT_MILLISECONDS = 0
1545Const MCI_FORMAT_HMS = 1
1546Const MCI_FORMAT_MSF = 2
1547Const MCI_FORMAT_FRAMES = 3
1548Const MCI_FORMAT_SMPTE_24 = 4
1549Const MCI_FORMAT_SMPTE_25 = 5
1550Const MCI_FORMAT_SMPTE_30 = 6
1551Const MCI_FORMAT_SMPTE_30DROP = 7
1552Const MCI_FORMAT_BYTES = 8
1553Const MCI_FORMAT_SAMPLES = 9
1554Const MCI_FORMAT_TMSF = 10
1555
[95]1556'------------
1557' MCI Macros
[1]1558
[95]1559'MSF
1560Function MCI_MSF_MINUTE(msf As DWord) As Byte
1561 Return (&HFF AND msf)
1562End Function
1563Function MCI_MSF_SECOND(msf As DWord) As Byte
1564 Return (&HFF AND (msf>> 8))
1565End Function
1566Function MCI_MSF_FRAME(msf As DWord) As Byte
1567 Return (&HFF AND (msf>>16))
1568End Function
1569Function MCI_MAKE_MSF(minutes As Byte, seconds As Byte, frames As Byte) As DWord
1570 Return MAKELONG(minutes,MAKEWORD(seconds,frames))
1571End Function
[1]1572
[95]1573'TMSF
1574Function MCI_TMSF_TRACK(tmsf As DWord) As Byte
1575 Return (&HFF AND (tmsf))
1576End Function
1577Function MCI_TMSF_MINUTE(tmsf As DWord) As Byte
1578 Return (&HFF AND (((tmsf)) >> 8))
1579End Function
1580Function MCI_TMSF_SECOND(tmsf As DWord) As Byte
1581 Return (&HFF AND ((tmsf)>>16))
1582End Function
1583Function MCI_TMSF_FRAME(tmsf As DWord) As Byte
1584 Return (&HFF AND ((tmsf)>>24))
1585End Function
1586Function MCI_MAKE_TMSF(tracks As Byte, minutes As Byte, seconds As Byte, frames As Byte) As DWord
1587 Return MAKELONG(MAKEWORD(tracks,minutes),MAKEWORD(seconds,frames))
1588End Function
1589
1590'HMS
1591Function MCI_HMS_HOUR(hms As DWord) As Byte
1592 Return (&HFF AND (hms))
1593End Function
1594Function MCI_HMS_MINUTE(hms As DWord) As Byte
1595 Return (&HFF AND ((hms)>> 8))
1596End Function
1597Function MCI_HMS_SECOND(hms As DWord) As Byte
1598 Return (&HFF AND ((hms)>>16))
1599End Function
1600Function MCI_MAKE_HMS(hours As Byte, minutes As Byte, seconds As Byte) As DWord
1601 Return MAKELONG(hours,MAKEWORD(minutes,seconds))
1602End Function
1603
1604' flags for wParam of MM_MCINOTIFY message
1605Const MCI_NOTIFY_SUCCESSFUL = &H0001
1606Const MCI_NOTIFY_SUPERSEDED = &H0002
1607Const MCI_NOTIFY_ABORTED = &H0004
1608Const MCI_NOTIFY_FAILURE = &H0008
1609
1610' common flags for dwFlags parameter of MCI command messages
1611Const MCI_NOTIFY = &H00000001
1612Const MCI_WAIT = &H00000002
1613Const MCI_FROM = &H00000004
1614Const MCI_TO = &H00000008
1615Const MCI_TRACK = &H00000010
1616
1617' flags for dwFlags parameter of MCI_OPEN command message
1618Const MCI_OPEN_SHAREABLE = &H00000100
1619Const MCI_OPEN_ELEMENT = &H00000200
1620Const MCI_OPEN_ALIAS = &H00000400
1621Const MCI_OPEN_ELEMENT_ID = &H00000800
1622Const MCI_OPEN_TYPE_ID = &H00001000
1623Const MCI_OPEN_TYPE = &H00002000
1624
1625' flags for dwFlags parameter of MCI_SEEK command message
1626Const MCI_SEEK_TO_START = &H00000100
1627Const MCI_SEEK_TO_END = &H00000200
1628
1629' flags for dwFlags parameter of MCI_STATUS command message
1630Const MCI_STATUS_ITEM = &H00000100
1631Const MCI_STATUS_START = &H00000200
1632
1633' flags for dwItem field of the MCI_STATUS_PARMS parameter block
1634Const MCI_STATUS_LENGTH = &H00000001
1635Const MCI_STATUS_POSITION = &H00000002
1636Const MCI_STATUS_NUMBER_OF_TRACKS = &H00000003
1637Const MCI_STATUS_MODE = &H00000004
1638Const MCI_STATUS_MEDIA_PRESENT = &H00000005
1639Const MCI_STATUS_TIME_FORMAT = &H00000006
1640Const MCI_STATUS_READY = &H00000007
1641Const MCI_STATUS_CURRENT_TRACK = &H00000008
1642
1643' flags for dwFlags parameter of MCI_INFO command message
1644Const MCI_INFO_PRODUCT = &H00000100
1645Const MCI_INFO_FILE = &H00000200
1646Const MCI_INFO_MEDIA_UPC = &H00000400
1647Const MCI_INFO_MEDIA_IDENTITY = &H00000800
1648Const MCI_INFO_NAME = &H00001000
1649Const MCI_INFO_COPYRIGHT = &H00002000
1650
1651' flags for dwFlags parameter of MCI_GETDEVCAPS command message
1652Const MCI_GETDEVCAPS_ITEM = &H00000100
1653
1654' flags for dwItem field of the MCI_GETDEVCAPS_PARMS parameter block
1655Const MCI_GETDEVCAPS_CAN_RECORD = &H00000001
1656Const MCI_GETDEVCAPS_HAS_AUDIO = &H00000002
1657Const MCI_GETDEVCAPS_HAS_VIDEO = &H00000003
1658Const MCI_GETDEVCAPS_DEVICE_TYPE = &H00000004
1659Const MCI_GETDEVCAPS_USES_FILES = &H00000005
1660Const MCI_GETDEVCAPS_COMPOUND_DEVICE = &H00000006
1661Const MCI_GETDEVCAPS_CAN_EJECT = &H00000007
1662Const MCI_GETDEVCAPS_CAN_PLAY = &H00000008
1663Const MCI_GETDEVCAPS_CAN_SAVE = &H00000009
1664
1665' flags for dwFlags parameter of MCI_SYSINFO command message
1666Const MCI_SYSINFO_QUANTITY = &H00000100
1667Const MCI_SYSINFO_OPEN = &H00000200
1668Const MCI_SYSINFO_NAME = &H00000400
1669Const MCI_SYSINFO_INSTALLNAME = &H00000800
1670
1671' flags for dwFlags parameter of MCI_SET command message
1672Const MCI_SET_DOOR_OPEN = &H00000100
1673Const MCI_SET_DOOR_CLOSED = &H00000200
1674Const MCI_SET_TIME_FORMAT = &H00000400
1675Const MCI_SET_AUDIO = &H00000800
1676Const MCI_SET_VIDEO = &H00001000
1677Const MCI_SET_ON = &H00002000
1678Const MCI_SET_OFF = &H00004000
1679
1680' flags for dwAudio field of MCI_SET_PARMS or MCI_SEQ_SET_PARMS
1681Const MCI_SET_AUDIO_ALL = &H00000000
1682Const MCI_SET_AUDIO_LEFT = &H00000001
1683Const MCI_SET_AUDIO_RIGHT = &H00000002
1684
1685' flags for dwFlags parameter of MCI_BREAK command message
1686Const MCI_BREAK_KEY = &H00000100
1687Const MCI_BREAK_HWND = &H00000200
1688Const MCI_BREAK_OFF = &H00000400
1689
1690' flags for dwFlags parameter of MCI_RECORD command message
1691Const MCI_RECORD_INSERT = &H00000100
1692Const MCI_RECORD_OVERWRITE = &H00000200
1693
1694' flags for dwFlags parameter of MCI_SAVE command message
1695Const MCI_SAVE_FILE = &H00000100
1696
1697' flags for dwFlags parameter of MCI_LOAD command message
1698Const MCI_LOAD_FILE = &H00000100
1699
1700Type MCI_GENERIC_PARMS
1701 dwCallback As DWord
1702End Type
1703TypeDef PMCI_GENERIC_PARMS = *MCI_GENERIC_PARMS
1704TypeDef LPMCI_GENERIC_PARMS = *MCI_GENERIC_PARMS
1705
[1]1706Type MCI_OPEN_PARMS
1707 dwCallback As DWord
1708 wDeviceID As DWord
[95]1709 lpstrDeviceType As LPSTR
1710 lpstrElementName As LPSTR
1711 lpstrAlias As LPSTR
[1]1712End Type
[95]1713TypeDef PMCI_OPEN_PARMS = *MCI_OPEN_PARMS
1714TypeDef LPMCI_OPEN_PARMS = *MCI_OPEN_PARMS
[1]1715
1716Type MCI_PLAY_PARMS
1717 dwCallback As DWord
1718 dwFrom As DWord
1719 dwTo As DWord
1720End Type
[95]1721TypeDef PMCI_PLAY_PARMS = *MCI_PLAY_PARMS
1722TypeDef LPMCI_PLAY_PARMS = *MCI_PLAY_PARMS
[1]1723
1724Type MCI_SEEK_PARMS
1725 dwCallback As DWord
1726 dwTo As DWord
1727End Type
[95]1728TypeDef PMCI_SEEK_PARMS = *MCI_SEEK_PARMS
1729TypeDef LPMCI_SEEK_PARMS = *MCI_SEEK_PARMS
[1]1730
[95]1731Type MCI_STATUS_PARMS
1732 dwCallback As DWord
1733 dwReturn As DWord
1734 dwItem As DWord
1735 dwTrack As DWord
1736End Type
1737TypeDef PMCI_STATUS_PARMS = *MCI_STATUS_PARMS
1738TypeDef LPMCI_STATUS_PARMS = *MCI_STATUS_PARMS
1739
1740Type MCI_INFO_PARMSA
1741 dwCallback As DWord
1742 lpstrReturn As LPSTR
1743 dwRetSize As DWord
1744End Type
1745TypeDef PMCI_INFO_PARMSA = *MCI_INFO_PARMSA
1746TypeDef LPMCI_INFO_PARMSA = *MCI_INFO_PARMSA
1747TypeDef MCI_INFO_PARMS = MCI_INFO_PARMSA
1748TypeDef PMCI_INFO_PARMS = PMCI_INFO_PARMSA
1749TypeDef LPMCI_INFO_PARMS = LPMCI_INFO_PARMSA
1750
1751Type MCI_GETDEVCAPS_PARMS
1752 dwCallback As DWord
1753 dwReturn As DWord
1754 dwItem As DWord
1755End Type
1756TypeDef PMCI_GETDEVCAPS_PARMS = *MCI_GETDEVCAPS_PARMS
1757TypeDef LPMCI_GETDEVCAPS_PARMS = *MCI_GETDEVCAPS_PARMS
1758
1759Type MCI_SYSINFO_PARMSA
1760 dwCallback As DWord
1761 lpstrReturn As LPSTR
1762 dwRetSize As DWord
1763 dwNumber As DWord
1764 wDeviceType As DWord
1765End Type
1766TypeDef PMCI_SYSINFO_PARMSA = *MCI_SYSINFO_PARMSA
1767TypeDef LPMCI_SYSINFO_PARMSA = *MCI_SYSINFO_PARMSA
1768TypeDef MCI_SYSINFO_PARMS = MCI_SYSINFO_PARMSA
1769TypeDef PMCI_SYSINFO_PARMS = PMCI_SYSINFO_PARMSA
1770TypeDef LPMCI_SYSINFO_PARMS = LPMCI_SYSINFO_PARMSA
1771
[1]1772Type MCI_SET_PARMS
1773 dwCallback As DWord
1774 dwTimeFormat As DWord
1775 dwAudio As DWord
1776End Type
[95]1777TypeDef PMCI_SET_PARMS = *MCI_SET_PARMS
1778TypeDef LPMCI_SET_PARMS = *MCI_SET_PARMS
[1]1779
[95]1780Type MCI_BREAK_PARMS
[1]1781 dwCallback As DWord
[95]1782 nVirtKey As Long
1783 hwndBreak As HWND
[1]1784End Type
[95]1785TypeDef PMCI_BREAK_PARMS = *MCI_BREAK_PARMS
1786TypeDef LPMCI_BREAK_PARMS = *MCI_BREAK_PARMS
[1]1787
[95]1788Type MCI_SAVE_PARMSA
1789 dwCallback As DWord
1790 lpfilename As LPSTR
1791End Type
1792TypeDef PMCI_SAVE_PARMSA = *MCI_SAVE_PARMSA
1793TypeDef LPMCI_SAVE_PARMSA = *MCI_SAVE_PARMSA
1794TypeDef MCI_SAVE_PARMS = MCI_SAVE_PARMSA
1795TypeDef PMCI_SAVE_PARMS = PMCI_SAVE_PARMSA
1796TypeDef LPMCI_SAVE_PARMS = LPMCI_SAVE_PARMSA
[1]1797
[95]1798Type MCI_LOAD_PARMSA
1799 dwCallback As DWord
1800 lpfilename As LPSTR
1801End Type
1802TypeDef PMCI_LOAD_PARMSA = *MCI_LOAD_PARMSA
1803TypeDef LPMCI_LOAD_PARMSA = *MCI_LOAD_PARMSA
1804TypeDef MCI_LOAD_PARMS = MCI_LOAD_PARMSA
1805TypeDef PMCI_LOAD_PARMS = PMCI_LOAD_PARMSA
1806TypeDef LPMCI_LOAD_PARMS = LPMCI_LOAD_PARMSA
[1]1807
[95]1808Type MCI_RECORD_PARMS
1809 dwCallback As DWord
1810 dwFrom As DWord
1811 dwTo As DWord
1812End Type
1813TypeDef PMCI_RECORD_PARMS = *MCI_RECORD_PARMS
1814TypeDef LPMCI_RECORD_PARMS = *MCI_RECORD_PARMS
[1]1815
[95]1816' MCI extensions for videodisc devices
1817Const MCI_VD_MODE_PARK = (MCI_VD_OFFSET + 1)
1818Const MCI_VD_MEDIA_CLV = (MCI_VD_OFFSET + 2)
1819Const MCI_VD_MEDIA_CAV = (MCI_VD_OFFSET + 3)
1820Const MCI_VD_MEDIA_OTHER = (MCI_VD_OFFSET + 4)
1821Const MCI_VD_FORMAT_TRACK = &H4001
1822Const MCI_VD_PLAY_REVERSE = &H00010000
1823Const MCI_VD_PLAY_FAST = &H00020000
1824Const MCI_VD_PLAY_SPEED = &H00040000
1825Const MCI_VD_PLAY_SCAN = &H00080000
1826Const MCI_VD_PLAY_SLOW = &H00100000
1827Const MCI_VD_SEEK_REVERSE = &H00010000
1828Const MCI_VD_STATUS_SPEED = &H00004002
1829Const MCI_VD_STATUS_FORWARD = &H00004003
1830Const MCI_VD_STATUS_MEDIA_TYPE = &H00004004
1831Const MCI_VD_STATUS_SIDE = &H00004005
1832Const MCI_VD_STATUS_DISC_SIZE = &H00004006
1833Const MCI_VD_GETDEVCAPS_CLV = &H00010000
1834Const MCI_VD_GETDEVCAPS_CAV = &H00020000
1835Const MCI_VD_SPIN_UP = &H00010000
1836Const MCI_VD_SPIN_DOWN = &H00020000
1837Const MCI_VD_GETDEVCAPS_CAN_REVERSE = &H00004002
1838Const MCI_VD_GETDEVCAPS_FAST_RATE = &H00004003
1839Const MCI_VD_GETDEVCAPS_SLOW_RATE = &H00004004
1840Const MCI_VD_GETDEVCAPS_NORMAL_RATE = &H00004005
1841Const MCI_VD_STEP_FRAMES = &H00010000
1842Const MCI_VD_STEP_REVERSE = &H00020000
1843Const MCI_VD_ESCAPE_STRING = &H00000100
[1]1844
[95]1845Type MCI_VD_PLAY_PARMS
1846 dwCallback As DWord
1847 dwFrom As DWord
1848 dwTo As DWord
1849 dwSpeed As DWord
1850End Type
1851TypeDef PMCI_VD_PLAY_PARMS = *MCI_VD_PLAY_PARMS
1852TypeDef LPMCI_VD_PLAY_PARMS = *MCI_VD_PLAY_PARMS
[1]1853
[95]1854Type MCI_VD_STEP_PARMS
1855 dwCallback As DWord
1856 dwFrames As DWord
1857End Type
1858TypeDef PMCI_VD_STEP_PARMS = *MCI_VD_STEP_PARMS
1859TypeDef LPMCI_VD_STEP_PARMS = *MCI_VD_STEP_PARMS
[1]1860
[95]1861Type MCI_VD_ESCAPE_PARMSA
1862 dwCallback As DWord
1863 lpstrCommand As LPSTR
1864End Type
1865TypeDef PMCI_VD_ESCAPE_PARMSA = *MCI_VD_ESCAPE_PARMSA
1866TypeDef LPMCI_VD_ESCAPE_PARMSA = *MCI_VD_ESCAPE_PARMSA
1867TypeDef MCI_VD_ESCAPE_PARMS = MCI_VD_ESCAPE_PARMSA
1868TypeDef PMCI_VD_ESCAPE_PARMS = PMCI_VD_ESCAPE_PARMSA
1869TypeDef LPMCI_VD_ESCAPE_PARMS = LPMCI_VD_ESCAPE_PARMSA
[1]1870
[95]1871' MCI extensions for CD audio devices
1872Const MCI_CDA_STATUS_TYPE_TRACK = &H00004001
1873Const MCI_CDA_TRACK_AUDIO = (MCI_CD_OFFSET + 0)
1874Const MCI_CDA_TRACK_OTHER = (MCI_CD_OFFSET + 1)
[1]1875
[95]1876' MCI extensions for waveform audio devices
1877Const MCI_WAVE_PCM = (MCI_WAVE_OFFSET + 0)
1878Const MCI_WAVE_MAPPER = (MCI_WAVE_OFFSET + 1)
1879Const MCI_WAVE_OPEN_BUFFER = &H00010000
1880Const MCI_WAVE_SET_FORMATTAG = &H00010000
1881Const MCI_WAVE_SET_CHANNELS = &H00020000
1882Const MCI_WAVE_SET_SAMPLESPERSEC = &H00040000
1883Const MCI_WAVE_SET_AVGBYTESPERSEC = &H00080000
1884Const MCI_WAVE_SET_BLOCKALIGN = &H00100000
1885Const MCI_WAVE_SET_BITSPERSAMPLE = &H00200000
1886Const MCI_WAVE_INPUT = &H00400000
1887Const MCI_WAVE_OUTPUT = &H00800000
1888Const MCI_WAVE_STATUS_FORMATTAG = &H00004001
1889Const MCI_WAVE_STATUS_CHANNELS = &H00004002
1890Const MCI_WAVE_STATUS_SAMPLESPERSEC = &H00004003
1891Const MCI_WAVE_STATUS_AVGBYTESPERSEC = &H00004004
1892Const MCI_WAVE_STATUS_BLOCKALIGN = &H00004005
1893Const MCI_WAVE_STATUS_BITSPERSAMPLE = &H00004006
1894Const MCI_WAVE_STATUS_LEVEL = &H00004007
1895Const MCI_WAVE_SET_ANYINPUT = &H04000000
1896Const MCI_WAVE_SET_ANYOUTPUT = &H08000000
1897Const MCI_WAVE_GETDEVCAPS_INPUTS = &H00004001
1898Const MCI_WAVE_GETDEVCAPS_OUTPUTS = &H00004002
[1]1899
[95]1900Type MCI_WAVE_OPEN_PARMSA
1901 dwCallback As DWord
1902 wDeviceID As MCIDEVICEID
1903 lpstrDeviceType As LPSTR
1904 lpstrElementName As LPSTR
1905 lpstrAlias As LPSTR
1906 dwBufferSeconds As DWord
1907End Type
1908TypeDef PMCI_WAVE_OPEN_PARMSA = *MCI_WAVE_OPEN_PARMSA
1909TypeDef LPMCI_WAVE_OPEN_PARMSA = *MCI_WAVE_OPEN_PARMSA
1910TypeDef MCI_WAVE_OPEN_PARMS = MCI_WAVE_OPEN_PARMSA
1911TypeDef PMCI_WAVE_OPEN_PARMS = PMCI_WAVE_OPEN_PARMSA
1912TypeDef LPMCI_WAVE_OPEN_PARMS = LPMCI_WAVE_OPEN_PARMSA
[1]1913
[95]1914Type MCI_WAVE_DELETE_PARMS
1915 dwCallback As DWord
1916 dwFrom As DWord
1917 dwTo As DWord
1918End Type
1919TypeDef PMCI_WAVE_DELETE_PARMS = *MCI_WAVE_DELETE_PARMS
1920TypeDef LPMCI_WAVE_DELETE_PARMS = *MCI_WAVE_DELETE_PARMS
[1]1921
[95]1922Type MCI_WAVE_SET_PARMS
1923 dwCallback As DWord
1924 dwTimeFormat As DWord
1925 dwAudio As DWord
1926 wInput As DWord
1927 wOutput As DWord
1928 wFormatTag As Word
1929 wReserved2 As Word
1930 nChannels As Word
1931 wReserved3 As Word
1932 nSamplesPerSec As DWord
1933 nAvgBytesPerSec As DWord
1934 nBlockAlign As Word
1935 wReserved4 As Word
1936 wBitsPerSample As Word
1937 wReserved5 As Word
1938End Type
1939TypeDef PMCI_WAVE_SET_PARMS = *MCI_WAVE_SET_PARMS
1940TypeDef LPMCI_WAVE_SET_PARMS = *MCI_WAVE_SET_PARMS
[1]1941
[95]1942' MCI extensions for MIDI sequencer devices
1943Const MCI_SEQ_DIV_PPQN = (0 + MCI_SEQ_OFFSET)
1944Const MCI_SEQ_DIV_SMPTE_24 = (1 + MCI_SEQ_OFFSET)
1945Const MCI_SEQ_DIV_SMPTE_25 = (2 + MCI_SEQ_OFFSET)
1946Const MCI_SEQ_DIV_SMPTE_30DROP = (3 + MCI_SEQ_OFFSET)
1947Const MCI_SEQ_DIV_SMPTE_30 = (4 + MCI_SEQ_OFFSET)
1948Const MCI_SEQ_FORMAT_SONGPTR = &H4001
1949Const MCI_SEQ_FILE = &H4002
1950Const MCI_SEQ_MIDI = &H4003
1951Const MCI_SEQ_SMPTE = &H4004
1952Const MCI_SEQ_NONE = 65533
1953Const MCI_SEQ_MAPPER = 65535
1954Const MCI_SEQ_STATUS_TEMPO = &H00004002
1955Const MCI_SEQ_STATUS_PORT = &H00004003
1956Const MCI_SEQ_STATUS_SLAVE = &H00004007
1957Const MCI_SEQ_STATUS_MASTER = &H00004008
1958Const MCI_SEQ_STATUS_OFFSET = &H00004009
1959Const MCI_SEQ_STATUS_DIVTYPE = &H0000400A
1960Const MCI_SEQ_STATUS_NAME = &H0000400B
1961Const MCI_SEQ_STATUS_COPYRIGHT = &H0000400C
1962Const MCI_SEQ_SET_TEMPO = &H00010000
1963Const MCI_SEQ_SET_PORT = &H00020000
1964Const MCI_SEQ_SET_SLAVE = &H00040000
1965Const MCI_SEQ_SET_MASTER = &H00080000
1966Const MCI_SEQ_SET_OFFSET = &H01000000
[1]1967
[95]1968Type MCI_SEQ_SET_PARMS
1969 dwCallback As DWord
1970 dwTimeFormat As DWord
1971 dwAudio As DWord
1972 dwTempo As DWord
1973 dwPort As DWord
1974 dwSlave As DWord
1975 dwMaster As DWord
1976 dwOffset As DWord
1977End Type
1978TypeDef PMCI_SEQ_SET_PARMS = *MCI_SEQ_SET_PARMS
1979TypeDef LPMCI_SEQ_SET_PARMS = *MCI_SEQ_SET_PARMS
[1]1980
[95]1981' MCI extensions for animation devices
1982Const MCI_ANIM_OPEN_WS = &H00010000
1983Const MCI_ANIM_OPEN_PARENT = &H00020000
1984Const MCI_ANIM_OPEN_NOSTATIC = &H00040000
1985Const MCI_ANIM_PLAY_SPEED = &H00010000
1986Const MCI_ANIM_PLAY_REVERSE = &H00020000
1987Const MCI_ANIM_PLAY_FAST = &H00040000
1988Const MCI_ANIM_PLAY_SLOW = &H00080000
1989Const MCI_ANIM_PLAY_SCAN = &H00100000
1990Const MCI_ANIM_STEP_REVERSE = &H00010000
1991Const MCI_ANIM_STEP_FRAMES = &H00020000
1992Const MCI_ANIM_STATUS_SPEED = &H00004001
1993Const MCI_ANIM_STATUS_FORWARD = &H00004002
1994Const MCI_ANIM_STATUS_HWND = &H00004003
1995Const MCI_ANIM_STATUS_HPAL = &H00004004
1996Const MCI_ANIM_STATUS_STRETCH = &H00004005
1997Const MCI_ANIM_INFO_TEXT = &H00010000
1998Const MCI_ANIM_GETDEVCAPS_CAN_REVERSE = &H00004001
1999Const MCI_ANIM_GETDEVCAPS_FAST_RATE = &H00004002
2000Const MCI_ANIM_GETDEVCAPS_SLOW_RATE = &H00004003
2001Const MCI_ANIM_GETDEVCAPS_NORMAL_RATE = &H00004004
2002Const MCI_ANIM_GETDEVCAPS_PALETTES = &H00004006
2003Const MCI_ANIM_GETDEVCAPS_CAN_STRETCH = &H00004007
2004Const MCI_ANIM_GETDEVCAPS_MAX_WINDOWS = &H00004008
2005Const MCI_ANIM_REALIZE_NORM = &H00010000
2006Const MCI_ANIM_REALIZE_BKGD = &H00020000
2007Const MCI_ANIM_WINDOW_HWND = &H00010000
2008Const MCI_ANIM_WINDOW_STATE = &H00040000
2009Const MCI_ANIM_WINDOW_TEXT = &H00080000
2010Const MCI_ANIM_WINDOW_ENABLE_STRETCH = &H00100000
2011Const MCI_ANIM_WINDOW_DISABLE_STRETCH = &H00200000
2012Const MCI_ANIM_WINDOW_DEFAULT = &H00000000
2013Const MCI_ANIM_RECT = &H00010000
2014Const MCI_ANIM_PUT_SOURCE = &H00020000
2015Const MCI_ANIM_PUT_DESTINATION = &H00040000
2016Const MCI_ANIM_WHERE_SOURCE = &H00020000
2017Const MCI_ANIM_WHERE_DESTINATION = &H00040000
2018Const MCI_ANIM_UPDATE_HDC = &H00020000
[1]2019
[95]2020Type MCI_ANIM_OPEN_PARMSA
2021 dwCallback As DWord
2022 wDeviceID As MCIDEVICEID
2023 lpstrDeviceType As LPSTR
2024 lpstrElementName As LPSTR
2025 lpstrAlias As LPSTR
2026 dwStyle As DWord
2027 hWndParent As HWND
2028End Type
2029TypeDef PMCI_ANIM_OPEN_PARMSA = *MCI_ANIM_OPEN_PARMSA
2030TypeDef LPMCI_ANIM_OPEN_PARMSA = *MCI_ANIM_OPEN_PARMSA
2031TypeDef MCI_ANIM_OPEN_PARMS = MCI_ANIM_OPEN_PARMSA
2032TypeDef PMCI_ANIM_OPEN_PARMS = PMCI_ANIM_OPEN_PARMSA
2033TypeDef LPMCI_ANIM_OPEN_PARMS = LPMCI_ANIM_OPEN_PARMSA
[1]2034
[95]2035Type MCI_ANIM_PLAY_PARMS
2036 dwCallback As DWord
2037 dwFrom As DWord
2038 dwTo As DWord
2039 dwSpeed As DWord
2040End Type
2041TypeDef PMCI_ANIM_PLAY_PARMS = *MCI_ANIM_PLAY_PARMS
2042TypeDef LPMCI_ANIM_PLAY_PARMS = *MCI_ANIM_PLAY_PARMS
[1]2043
[95]2044Type MCI_ANIM_STEP_PARMS
2045 dwCallback As DWord
2046 dwFrames As DWord
2047End Type
2048TypeDef PMCI_ANIM_STEP_PARMS = *MCI_ANIM_STEP_PARMS
2049TypeDef LPMCI_ANIM_STEP_PARMS = *MCI_ANIM_STEP_PARMS
[1]2050
[95]2051Type MCI_ANIM_WINDOW_PARMSA
2052 dwCallback As DWord
2053 hWnd As HWND
2054 nCmdShow As DWord
2055 lpstrText As LPSTR
2056End Type
2057TypeDef PMCI_ANIM_WINDOW_PARMSA = *MCI_ANIM_WINDOW_PARMSA
2058TypeDef LPMCI_ANIM_WINDOW_PARMSA = *MCI_ANIM_WINDOW_PARMSA
2059TypeDef MCI_ANIM_WINDOW_PARMS = MCI_ANIM_WINDOW_PARMSA
2060TypeDef PMCI_ANIM_WINDOW_PARMS = PMCI_ANIM_WINDOW_PARMSA
2061TypeDef LPMCI_ANIM_WINDOW_PARMS = LPMCI_ANIM_WINDOW_PARMSA
2062
2063Type MCI_ANIM_RECT_PARMS
2064 dwCallback As DWord
2065 rc As RECT
2066End Type
2067TypeDef PMCI_ANIM_RECT_PARMS = *MCI_ANIM_RECT_PARMS
2068TypeDef LPMCI_ANIM_RECT_PARMS = *MCI_ANIM_RECT_PARMS
2069
2070Type MCI_ANIM_UPDATE_PARMS
2071 dwCallback As DWord
2072 rc As RECT
2073 hDC As HDC
2074End Type
2075TypeDef PMCI_ANIM_UPDATE_PARMS = *MCI_ANIM_UPDATE_PARMS
2076TypeDef LPMCI_ANIM_UPDATE_PARMS = *MCI_ANIM_UPDATE_PARMS
2077
2078' MCI extensions for video overlay devices
2079Const MCI_OVLY_OPEN_WS = &H00010000
2080Const MCI_OVLY_OPEN_PARENT = &H00020000
2081Const MCI_OVLY_STATUS_HWND = &H00004001
2082Const MCI_OVLY_STATUS_STRETCH = &H00004002
2083Const MCI_OVLY_INFO_TEXT = &H00010000
2084Const MCI_OVLY_GETDEVCAPS_CAN_STRETCH = &H00004001
2085Const MCI_OVLY_GETDEVCAPS_CAN_FREEZE = &H00004002
2086Const MCI_OVLY_GETDEVCAPS_MAX_WINDOWS = &H00004003
2087Const MCI_OVLY_WINDOW_HWND = &H00010000
2088Const MCI_OVLY_WINDOW_STATE = &H00040000
2089Const MCI_OVLY_WINDOW_TEXT = &H00080000
2090Const MCI_OVLY_WINDOW_ENABLE_STRETCH = &H00100000
2091Const MCI_OVLY_WINDOW_DISABLE_STRETCH = &H00200000
2092Const MCI_OVLY_WINDOW_DEFAULT = &H00000000
2093Const MCI_OVLY_RECT = &H00010000
2094Const MCI_OVLY_PUT_SOURCE = &H00020000
2095Const MCI_OVLY_PUT_DESTINATION = &H00040000
2096Const MCI_OVLY_PUT_FRAME = &H00080000
2097Const MCI_OVLY_PUT_VIDEO = &H00100000
2098Const MCI_OVLY_WHERE_SOURCE = &H00020000
2099Const MCI_OVLY_WHERE_DESTINATION = &H00040000
2100Const MCI_OVLY_WHERE_FRAME = &H00080000
2101Const MCI_OVLY_WHERE_VIDEO = &H00100000
2102
2103Type MCI_OVLY_OPEN_PARMSA
2104 dwCallback As DWord
2105 wDeviceID As MCIDEVICEID
2106 lpstrDeviceType As LPSTR
2107 lpstrElementName As LPSTR
2108 lpstrAlias As LPSTR
2109 dwStyle As DWord
2110 hWndParent As HWND
2111End Type
2112TypeDef PMCI_OVLY_OPEN_PARMSA = *MCI_OVLY_OPEN_PARMSA
2113TypeDef LPMCI_OVLY_OPEN_PARMSA = *MCI_OVLY_OPEN_PARMSA
2114TypeDef MCI_OVLY_OPEN_PARMS = MCI_OVLY_OPEN_PARMSA
2115TypeDef PMCI_OVLY_OPEN_PARMS = PMCI_OVLY_OPEN_PARMSA
2116TypeDef LPMCI_OVLY_OPEN_PARMS = LPMCI_OVLY_OPEN_PARMSA
2117
2118Type MCI_OVLY_WINDOW_PARMSA
2119 dwCallback As DWord
2120 hWnd As HWND
2121 nCmdShow As DWord
2122 lpstrText As LPSTR
2123End Type
2124TypeDef PMCI_OVLY_WINDOW_PARMSA = *MCI_OVLY_WINDOW_PARMSA
2125TypeDef LPMCI_OVLY_WINDOW_PARMSA = *MCI_OVLY_WINDOW_PARMSA
2126TypeDef MCI_OVLY_WINDOW_PARMS = MCI_OVLY_WINDOW_PARMSA
2127TypeDef PMCI_OVLY_WINDOW_PARMS = PMCI_OVLY_WINDOW_PARMSA
2128TypeDef LPMCI_OVLY_WINDOW_PARMS = LPMCI_OVLY_WINDOW_PARMSA
2129
2130Type MCI_OVLY_RECT_PARMS
2131 dwCallback As DWord
2132 rc As RECT
2133End Type
2134TypeDef PMCI_OVLY_RECT_PARMS = *MCI_OVLY_RECT_PARMS
2135TypeDef LPMCI_OVLY_RECT_PARMS = *MCI_OVLY_RECT_PARMS
2136
2137Type MCI_OVLY_SAVE_PARMSA
2138 dwCallback As DWord
2139 lpfilename As LPSTR
2140 rc As RECT
2141End Type
2142TypeDef PMCI_OVLY_SAVE_PARMSA = *MCI_OVLY_SAVE_PARMSA
2143TypeDef LPMCI_OVLY_SAVE_PARMSA = *MCI_OVLY_SAVE_PARMSA
2144TypeDef MCI_OVLY_SAVE_PARMS = MCI_OVLY_SAVE_PARMSA
2145TypeDef PMCI_OVLY_SAVE_PARMS = PMCI_OVLY_SAVE_PARMSA
2146TypeDef LPMCI_OVLY_SAVE_PARMS = LPMCI_OVLY_SAVE_PARMSA
2147
2148Type MCI_OVLY_LOAD_PARMSA
2149 dwCallback As DWord
2150 lpfilename As LPSTR
2151 rc As RECT
2152End Type
2153TypeDef PMCI_OVLY_LOAD_PARMSA = *MCI_OVLY_LOAD_PARMSA
2154TypeDef LPMCI_OVLY_LOAD_PARMSA = *MCI_OVLY_LOAD_PARMSA
2155TypeDef MCI_OVLY_LOAD_PARMS = MCI_OVLY_LOAD_PARMSA
2156TypeDef PMCI_OVLY_LOAD_PARMS = PMCI_OVLY_LOAD_PARMSA
2157TypeDef LPMCI_OVLY_LOAD_PARMS = LPMCI_OVLY_LOAD_PARMSA
2158
2159' DISPLAY Driver extensions
2160Const NEWTRANSPARENT = 3
2161Const QUERYROPSUPPORT = 40
2162
2163' DIB Driver extensions
2164Const SELECTDIB = 41
2165Const DIBINDEX(n) = MAKELONG(n,&H10FF)
2166
[1]2167#endif '_INC_MMSYS
Note: See TracBrowser for help on using the repository browser.