mci.pas 118 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537
  1. {
  2. $Id$
  3. Copyright (c) 1991, 1992, 1993 International Business Machines Corporation
  4. Copyright (c) 2002 by Andry Svirgunov ([email protected])
  5. Copyright (c) 2002-2003 by Yuri Prokushev ([email protected])
  6. This is Media Control Interface of MMPM/2
  7. This program is free software; you can redistribute it and/or modify it
  8. under the terms of the GNU Library General Public License (LGPL) as
  9. published by the Free Software Foundation; either version 2 of the
  10. License, or (at your option) any later version. This program is
  11. distributed in the hope that it will be useful, but WITHOUT ANY
  12. WARRANTY; without even the implied warranty of MERCHANTABILITY or
  13. FITNESS FOR A PARTICULAR PURPOSE.
  14. See the GNU Library General Public License for more details. You should
  15. have received a copy of the GNU Library General Public License along
  16. with this program; if not, write to the Free Software Foundation, Inc.,
  17. 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
  18. **********************************************************************}
  19. {
  20. @abstract(Media Control Interface of MMPM/2)
  21. @author(Andry Svirgunov ([email protected]))
  22. @author(Yuri Prokushev ([email protected]))
  23. @created(29 Nov 2002)
  24. @lastmod(05 Dec 2002)
  25. This is Media Control Interface of MMPM/2.
  26. Warning: This code is alfa. Future versions of this unit will propably
  27. not be compatible.
  28. }
  29. Unit mci;
  30. Interface
  31. Uses
  32. mmbase,
  33. os2def,
  34. pmgpi;
  35. Const
  36. MCI_TRUE = 1;
  37. MCI_FALSE = 0;
  38. // MCI command message identifiers
  39. MCI_OPEN = 1;
  40. MCI_CLOSE = 2;
  41. MCI_ESCAPE = 3;
  42. MCI_PLAY = 4;
  43. MCI_SEEK = 5;
  44. MCI_STOP = 6;
  45. MCI_PAUSE = 7;
  46. MCI_INFO = 8;
  47. MCI_GETDEVCAPS = 9;
  48. MCI_STATUS = 10;
  49. MCI_SPIN = 11;
  50. MCI_SET = 12;
  51. MCI_STEP = 13;
  52. MCI_RECORD = 14;
  53. MCI_SYSINFO = 15;
  54. MCI_SAVE = 16;
  55. MCI_CUE = 17;
  56. MCI_UPDATE = 18;
  57. MCI_SET_CUEPOINT = 19;
  58. MCI_SET_POSITION_ADVISE = 20;
  59. MCI_SET_SYNC_OFFSET = 21;
  60. MCI_LOAD = 22;
  61. MCI_ACQUIREDEVICE = 23;
  62. MCI_RELEASEDEVICE = 24;
  63. MCI_MASTERAUDIO = 25;
  64. MCI_GETTOC = 26;
  65. MCI_DEVICESETTINGS = 27;
  66. MCI_CONNECTOR = 28;
  67. MCI_RESUME = 29;
  68. MCI_CONNECTORINFO = 31;
  69. MCI_DEFAULT_CONNECTION = 32;
  70. MCI_CONNECTION = 33;
  71. MCI_GROUP = 34;
  72. MCI_NETWORD_DEFAULT_CONNECTION= 35;
  73. // MCI command message identifiers reserved for Digital Video and Video Overlay
  74. MCI_CAPTURE = 40;
  75. MCI_FREEZE = 41;
  76. MCI_GETIMAGEBUFFER = 42;
  77. MCI_GETIMAGEPALETTE = 43;
  78. MCI_PUT = 44;
  79. MCI_REALIZE = 45;
  80. MCI_REWIND = 46;
  81. MCI_RESTORE = 47;
  82. MCI_SETIMAGEBUFFER = 48;
  83. MCI_SETIMAGEPALETTE = 49;
  84. MCI_UNFREEZE = 50;
  85. MCI_WHERE = 51;
  86. MCI_WINDOW = 52;
  87. MCI_DELETE = 53;
  88. MCI_CUT = 54;
  89. MCI_PASTE = 55;
  90. MCI_COPY = 56;
  91. MCI_REDO = 57;
  92. MCI_UNDO = 58;
  93. MCI_MIXNOTIFY = 59;
  94. MCI_SETTUNER = 60;
  95. MCI_FILTER = 61;
  96. MCI_BUFFER = 62;
  97. MCI_MIXSETUP = 63;
  98. MCI_MAX_COMMAND = 64;
  99. Type
  100. RECT = LongInt;
  101. HDCT = LongInt;
  102. Const
  103. // this and all subsequent message ID's are reserved for the user
  104. MCI_USER_MESSAGES = 2000;
  105. // Special Device ID for "all"
  106. MCI_ALL_DEVICE_ID = $FFFF;
  107. // MCI implementation limits
  108. MAX_DEVICE_NAME = 20;
  109. MAX_ALIAS_NAME = 20;
  110. MAX_PRODINFO = 40;
  111. MAX_EXTENSION_NAME = 4;
  112. MAX_DEV_PARAMS = 128;
  113. MAX_VERSION_NUMBER = 6;
  114. MAX_PDD_NAME = 9;
  115. MAX_DLL_NAME = 260;
  116. MAX_CLASSES = 10;
  117. MAX_CONNECTORS = 10;
  118. MAX_EXTENSIONS = 25;
  119. MAX_TYPEBUFFER = 256;
  120. // MCI Device Type Constants
  121. MCI_DEVTYPE_VIDEOTAPE = 1;
  122. MCI_DEVTYPE_VIDEODISC = 2;
  123. MCI_DEVTYPE_CD_AUDIO = 3;
  124. MCI_DEVTYPE_DAT = 4;
  125. MCI_DEVTYPE_AUDIO_TAPE = 5;
  126. MCI_DEVTYPE_OTHER = 6;
  127. MCI_DEVTYPE_WAVEFORM_AUDIO = 7;
  128. MCI_DEVTYPE_SEQUENCER = 8;
  129. MCI_DEVTYPE_AUDIO_AMPMIX = 9;
  130. MCI_DEVTYPE_OVERLAY = 10;
  131. MCI_DEVTYPE_ANIMATION = 11;
  132. MCI_DEVTYPE_DIGITAL_VIDEO = 12;
  133. MCI_DEVTYPE_SPEAKER = 13;
  134. MCI_DEVTYPE_HEADPHONE = 14;
  135. MCI_DEVTYPE_MICROPHONE = 15;
  136. MCI_DEVTYPE_MONITOR = 16;
  137. MCI_DEVTYPE_CDXA = 17;
  138. MCI_DEVTYPE_FILTER = 18;
  139. MCI_DEVTYPE_TTS = 19;
  140. // MCI Device Type Names
  141. MCI_DEVTYPE_VIDEOTAPE_NAME = 'Videotape';
  142. MCI_DEVTYPE_VIDEODISC_NAME = 'Videodisc';
  143. MCI_DEVTYPE_CD_AUDIO_NAME = 'CDaudio';
  144. MCI_DEVTYPE_DAT_NAME = 'DAT';
  145. MCI_DEVTYPE_AUDIO_TAPE_NAME = 'Audiotape';
  146. MCI_DEVTYPE_OTHER_NAME = 'Other';
  147. MCI_DEVTYPE_WAVEFORM_AUDIO_NAME = 'Waveaudio';
  148. MCI_DEVTYPE_SEQUENCER_NAME = 'Sequencer';
  149. MCI_DEVTYPE_AUDIO_AMPMIX_NAME = 'Ampmix';
  150. MCI_DEVTYPE_OVERLAY_NAME = 'Overlay';
  151. MCI_DEVTYPE_ANIMATION_NAME = 'Animation';
  152. MCI_DEVTYPE_DIGITAL_VIDEO_NAME= 'Digitalvideo';
  153. MCI_DEVTYPE_SPEAKER_NAME = 'Speaker';
  154. MCI_DEVTYPE_HEADPHONE_NAME = 'Headphone';
  155. MCI_DEVTYPE_MICROPHONE_NAME = 'Microphone';
  156. MCI_DEVTYPE_MONITOR_NAME = 'Monitor';
  157. MCI_DEVTYPE_CDXA_NAME = 'CDXA';
  158. MCI_DEVTYPE_FILTER_NAME = 'Filter';
  159. MCI_DEVTYPE_TTS_NAME = 'Texttospeech';
  160. MCI_MAX_SYSTEM_DEVICE_NAMES = 19;
  161. // Getdevcaps, set, and status item base values
  162. MCI_AMP_ITEM_BASE = $1000;
  163. MCI_CD_ITEM_BASE = $2000;
  164. MCI_CDXA_ITEM_BASE = $3000;
  165. MCI_VD_ITEM_BASE = $4000;
  166. MCI_SEQ_ITEM_BASE = $5000;
  167. MCI_WAVE_ITEM_BASE = $6000;
  168. MCI_VID_ITEM_BASE = $7000;
  169. MCI_DGV_ITEM_BASE = $8000;
  170. MCI_OVLY_ITEM_BASE = $9000;
  171. // Flags for mciDriverNotify
  172. MCI_NOTIFY_SUCCESSFUL = $0000;
  173. MCI_NOTIFY_SUPERSEDED = $0001;
  174. MCI_NOTIFY_ABORTED = $0002;
  175. MCI_NOTIFY_ERROR = $0003;
  176. // mciDriverNotify Message Types
  177. MM_MCINOTIFY = $0500;
  178. MM_MCIPASSDEVICE = $0501;
  179. MM_MCIPOSITIONCHANGE = $0502;
  180. MM_MCICUEPOINT = $0503;
  181. MM_MCIPLAYLISTMESSAGE = $0504;
  182. MM_MCIEVENT = $0505;
  183. MM_MCISYNCH = $0506;
  184. MCI_LOSING_USE = $00000001;
  185. MCI_GAINING_USE = $00000002;
  186. // Common message flags 0x000000XX are reserved for common flags */
  187. MCI_NOTIFY = $00000001;
  188. MCI_WAIT = $00000002;
  189. MCI_FROM = $00000004;
  190. MCI_TO = $00000008;
  191. MCI_MILLISECONDS = $00000010;
  192. MCI_TRACK = $00000020;
  193. MCI_OVER = $00000040;
  194. MCI_TEST = $00000080;
  195. MCI_TO_BUFFER = $00000100;
  196. MCI_FROM_BUFFER = $00000200;
  197. MCI_CONVERT_FORMAT = $00000400;
  198. // Time formats
  199. MCI_FORMAT_MILLISECONDS = $00000001;
  200. MCI_FORMAT_mmTime = $00000002;
  201. MCI_FORMAT_MSF = $00000005;
  202. MCI_FORMAT_TMSF = $00000006;
  203. MCI_FORMAT_CHAPTERS = $00000007;
  204. MCI_FORMAT_FRAMES = $00000008;
  205. MCI_FORMAT_HMS = $00000009;
  206. MCI_FORMAT_TRACKS = $0000000A;
  207. MCI_FORMAT_BYTES = $0000000B;
  208. MCI_FORMAT_SAMPLES = $0000000C;
  209. MCI_FORMAT_HMSF = $0000000D;
  210. MCI_FORMAT_SET_SMPTE_24 = $0000000E;
  211. MCI_FORMAT_SET_SMPTE_25 = $0000000F;
  212. MCI_FORMAT_SET_SMPTE_30 = $00000010;
  213. MCI_FORMAT_SET_SMPTE_30DROP = $00000011;
  214. MCI_FORMAT_SET_SONGPTR = $00000012;
  215. MCI_FORMAT_uSec = $00000013;
  216. // Speed formats
  217. MCI_FORMAT_PERCENTAGE = $00000003;
  218. MCI_FORMAT_FPS = $00000004;
  219. // Time format conversions functions
  220. function mSecFromMM(Value: mmTime): LongInt;
  221. function mSecToMM(Value: Cardinal): mmTime;
  222. function RedBookToMM(Value: Cardinal): mmTime;
  223. function fps24ToMM(Value: Cardinal): mmTime;
  224. function fps25ToMM(Value: Cardinal): mmTime;
  225. function fps30ToMM(Value: Cardinal): mmTime;
  226. function HMSToMM(Value: Cardinal): mmTime;
  227. // The +20 is used for rounding purposes. It is derived by:
  228. // 1/2 * ((300 MMTIME/SEC / (75 FRAMES/SEC)) = 20 MMTIME/HALF-FRAME
  229. function RedBookFromMM(Value: mmTime): Cardinal;
  230. function FPS24FromMM(Value: mmTime): Cardinal;
  231. function FPS25FromMM(value: mmTime): Cardinal;
  232. function FPS30FromMM(value: mmTime): Cardinal;
  233. function HMSFromMM(value: mmTime): Cardinal;
  234. function tmsf_track(time: mmTime): Byte;
  235. function tmsf_minute(time: mmTime): Byte;
  236. function tmsf_second(time: mmTime): Byte;
  237. function tmsf_frame(time: mmTime): Byte;
  238. function msf_minute(time: mmTime): Byte;
  239. function msf_second(time: mmTime): Byte;
  240. function msf_frame(time: mmTime): Byte;
  241. // BYTE ACCESS WITH A DWORD MACROS
  242. function uLong_lwlb(var ul): Byte; // Low word low byte
  243. function uLong_lwhb(var ul): Byte; // Low word high byte
  244. function uLong_hwlb(var ul): Byte; // High word low byte
  245. function uLong_hwhb(var ul): Byte; // High word high byte
  246. function uLong_lowd(var ul): Word; // Low word
  247. function uLong_hiwd(var ul): Word; // High word
  248. // parameters for default command messages with empty parameter lists
  249. type
  250. mci_Generic_Parms = record
  251. hwndCallback : hwnd;
  252. end;
  253. pmci_Generic_Parms = ^mci_Generic_Parms;
  254. // flags for the MCI_ACQUIREDEVICE message
  255. // 0x00000X00 are reserved for MCI_ACQUIREDEVICE flags
  256. Const
  257. MCI_EXCLUSIVE = $00000100;
  258. MCI_EXCLUSIVE_INSTANCE = $00000200;
  259. MCI_ACQUIRE_QUEUE = $00000400;
  260. // flags for the MCI_CAPTURE message */
  261. // 0x0000XX00 are reserved for MCI_CAPTURE flags */
  262. // MCI_CONVERT is used by MCI_GETIMAGEBUFFER, MCI_SETIMAGEBUFFER */
  263. // MCI_CAPTURE, and MCI_RESTORE */
  264. MCI_CAPTURE_RECT = $00000100;
  265. MCI_CONVERT = $00001000;
  266. type
  267. // parameter structure for the MCI_CAPTURE message */
  268. mci_Capture_Parms = record
  269. hwndCallback : hwnd;
  270. Rect : RectL;
  271. end;
  272. pmci_Capture_Parms = ^mci_Capture_Parms;
  273. // flags for MCI_CONNECTOR and MCI_CONNECTION messages */
  274. Const
  275. MCI_ENABLE_CONNECTOR = $00000100;
  276. MCI_DISABLE_CONNECTOR = $00000200;
  277. MCI_QUERY_CONNECTOR_STATUS = $00000400;
  278. MCI_CONNECTOR_TYPE = $00000800;
  279. MCI_CONNECTOR_INDEX = $00001000;
  280. MCI_TO_CONNECTOR_INDEX = $00002000;
  281. MCI_TO_CONNECTOR_TYPE = $00004000;
  282. MCI_QUERY_CONNECTION = $00008000;
  283. MCI_MAKE_CONNECTION = $00010000;
  284. MCI_BREAK_CONNECTION = $00020000;
  285. MCI_ENUMERATE_CONNECTORS = $00040000;
  286. MCI_QUERY_CONNECTOR_TYPE = $00080000;
  287. MCI_QUERY_VALID_CONNECTION = $00100000;
  288. MCI_CONNECTOR_ALIAS = $00200000;
  289. MCI_EXTERNAL_CONNECTION = $00400000;
  290. // Connector types
  291. MCI_MIDI_STREAM_CONNECTOR = $00000001;
  292. MCI_CD_STREAM_CONNECTOR = $00000002;
  293. MCI_WAVE_STREAM_CONNECTOR = $00000003;
  294. MCI_AMP_STREAM_CONNECTOR = $00000004;
  295. MCI_XA_STREAM_CONNECTOR = $00000005;
  296. MCI_HEADPHONES_CONNECTOR = $00000006;
  297. MCI_SPEAKERS_CONNECTOR = $00000007;
  298. MCI_MICROPHONE_CONNECTOR = $00000008;
  299. MCI_LINE_IN_CONNECTOR = $00000009;
  300. MCI_LINE_OUT_CONNECTOR = $0000000a;
  301. MCI_VIDEO_IN_CONNECTOR = $0000000b;
  302. MCI_VIDEO_OUT_CONNECTOR = $0000000c;
  303. MCI_PHONE_SET_CONNECTOR = $0000000d;
  304. MCI_PHONE_LINE_CONNECTOR = $0000000e;
  305. MCI_AUDIO_IN_CONNECTOR = $0000000f;
  306. MCI_AUDIO_OUT_CONNECTOR = $00000010;
  307. MCI_UNIVERSAL_CONNECTOR = $00000011;
  308. MCI_INTERNAL_AUDIO_CONNECTOR = $00000012;
  309. MCI_MIDI_IN_CONNECTOR = $00000013;
  310. MCI_MIDI_OUT_CONNECTOR = $00000014;
  311. MCI_NULL_CONNECTOR = $00000015;
  312. Type
  313. // parameter structure for the MCI_CONNECTION message
  314. mci_Connection_Parms = record
  315. hwndCallback : hwnd; // PM window handle for MCI notify message
  316. ulConnectorType : LongInt; // Connector type
  317. ulConnectorIndex : LongInt; // Connector index
  318. pszAlias : pChar; // Connection device alias
  319. usToDeviceID : Integer; // Connected to device ID
  320. usReserved0 : Integer; // Reserved field
  321. ulReserved1 : LongInt; // Reserved field
  322. ulReserved2 : LongInt; // Reserved field
  323. end;
  324. pmci_Connection_Parms = ^mci_Connection_Parms;
  325. //********************************************************************/
  326. // parameter structure for the MCI_CONNECTOR message */
  327. //********************************************************************/
  328. mci_Connector_Parms = record
  329. hwndCallback : hwnd; // PM window handle for MCI notify message
  330. ulReturn : LongInt; // Return information
  331. ulConnectorType : LongInt; // If specified, ulConnectorIndex is relative
  332. // to the specified connector type
  333. ulConnectorIndex : LongInt; // Connector number
  334. end;
  335. pmci_Connector_Parms = ^mci_Connector_Parms;
  336. //********************************************************************/
  337. // Flags for use with ulParam1 */
  338. //********************************************************************/
  339. CONST
  340. MCI_MIXSETUP_INIT =$00010000;
  341. MCI_MIXSETUP_DEINIT =$00020000;
  342. MCI_MIXSETUP_QUERYMODE =$00040000;
  343. //********************************************************************/
  344. // parameter structure for the MCI_BUFFER message */
  345. //********************************************************************/
  346. Type
  347. mci_mix_buffer = record
  348. ulStructLength:LongInt; // Length of the structure */
  349. pBuffer:Pointer; // Pointer to a buffer */
  350. ulBufferLength:LongInt; // Length of the buffer */
  351. ulFlags:LongInt; // Flags */
  352. ulUserParm:LongInt; // Caller parameter */
  353. ulTime:LongInt; // OUT--Current time in MS */
  354. ulReserved1:LongInt; // Unused. */
  355. ulReserved2:LongInt; // Unused. */
  356. end;
  357. PMCI_MIX_BUFFER=^mci_mix_buffer;
  358. //********************************************************************/
  359. // valid options for the ulFlags field of MCI_MIX_BUFFER */
  360. //********************************************************************/
  361. CONST
  362. MIX_BUFFER_EOS =$00000001;
  363. type
  364. MixerProc=Function(ulHandle:LongInt;pBuffer:PMCI_MIX_BUFFER;ulFlags:LongInt):Longint; cdecl;
  365. MixerEvent=Function(ulStatus:LongInt;pBuffer:PMCI_MIX_BUFFER;ulFlags:LongInt):LongInt; cdecl;
  366. //********************************************************************/
  367. // valid returns for the ulFlags param of the MIXEREVENT entry */
  368. //********************************************************************/
  369. CONST
  370. MIX_STREAM_ERROR =$00000080;
  371. MIX_READ_COMPLETE =$00000001;
  372. MIX_WRITE_COMPLETE =$00000002;
  373. //********************************************************************/
  374. // parameter structure for the MCI_MIXSETUP_PARMS message */
  375. //********************************************************************/
  376. TYPE MCI_MIXSETUP_PARMS = record
  377. hwndCallback:HWND; // PM window handle for MCI notify message */
  378. ulBitsPerSample:LongInt; // IN Number of Bits per Sample */
  379. ulFormatTag:LongInt; // IN Format Tag */
  380. ulSamplesPerSec:LongInt; // IN Sampling Rate */
  381. ulChannels:LongInt; // IN Number of channels */
  382. ulFormatMode:LongInt; // IN Either MCI_RECORD or MCI_PLAY */
  383. ulDeviceType:LongInt; // IN MCI_DEVTYPE (i.e. DEVTYPE_WAVEFORM etc.) */
  384. ulMixHandle:LongInt; // OUT--mixer returns handle for write/read */
  385. pmixWrite:MixerProc; // OUT-Mixer Write Routine entry point */
  386. pmixRead:MixerProc; // OUT-Mixer Read Routine entry point */
  387. pmixEvent:MixerEvent; // IN--Mixer Read Routine entry point */
  388. pExtendedInfo:Pointer; // Ptr to extended wave information */
  389. ulBufferSize:longInt; // OUT--suggested buffer size for current mode */
  390. ulNumBuffers:LongInt; // OUT--suggested # of buffers for current mode */
  391. end;
  392. pmci_mixsetup_parms=^mci_mixsetup_parms;
  393. //********************************************************************/
  394. // Flags for use with ulParam1 */
  395. //********************************************************************/
  396. CONST
  397. MCI_BUFFER_QUERY =$00010000;
  398. MCI_BUFFER_SET =$00020000;
  399. MCI_ALLOCATE_MEMORY =$00040000;
  400. MCI_DEALLOCATE_MEMORY =$00080000;
  401. //********************************************************************/
  402. // parameter structure for the MCI_BUFFER message */
  403. //********************************************************************/
  404. type mci_buffer_parms=record
  405. hwndCallback:hwnd; // PM window handle for MCI notify message */
  406. ulStructLength:longint; // Length of the MCI Buffer command */
  407. ulNumBuffers:longInt; // Number of buffers MCI driver should use */
  408. ulBufferSize:longint; // Size of buffers MCI driver should use */
  409. ulMinToStart:longint; // Min number of buffers to create a stream. */
  410. ulSrcStart:longint; // # of EMPTY buffers required to start Source*/
  411. ulTgtStart:longint; // # of FULL buffers required to start Target */
  412. pBufList:pointer; // Pointer to a list of buffers */
  413. end;
  414. pmci_buffer_parms=^mci_buffer_parms;
  415. //********************************************************************/
  416. // parameter structure for the MCI_CONNECTORINFO message */
  417. //********************************************************************/
  418. mci_ConnectorInfo_Parms = record
  419. hwndCallback : hwnd; // PM window handle for MCI notify message
  420. ulReturn : Longint; // Return information
  421. ulDeviceTypeID : Longint; // MCI device type
  422. ulConnectorType : Longint; // If specified, ulConnectorIndex is relative
  423. // to the specified connector type
  424. ulConnectorIndex : Longint; // Connector number
  425. ulToConnectorType: Longint; // Connector type to test if
  426. // MCI_QUERY_VALID_CONNECTION is specified
  427. end;
  428. pmci_ConnectorInfo_Parms = ^mci_ConnectorInfo_Parms;
  429. //********************************************************************/
  430. // flags for the MCI_CUE message */
  431. // 0x00000x00 are reserved for MCI_CUE flags */
  432. //********************************************************************/
  433. CONST
  434. MCI_CUE_INPUT = $00000100;
  435. MCI_CUE_OUTPUT = $00000200;
  436. MCI_SHOW = $00000400;
  437. MCI_NOSHOW = $00000800;
  438. //************************************************/
  439. // Additional flags for Wave Audio for MCI_CUE */
  440. //************************************************/
  441. MCI_WAVE_INPUT = $00001000;
  442. MCI_WAVE_OUTPUT = $00002000;
  443. //****************************************************************************/
  444. // the MCI_CONNLIST structure used in the NETWORK_DEFAULT_CONNECTION message */
  445. //****************************************************************************/
  446. type mci_connlist=record
  447. ulFromDevice: LongInt; // Ordinal position of device within pDevices array */
  448. ulSrcConnType: LongInt; // Type of source connector */
  449. ulSrcConnNum: LongInt; // Source Connector Number */
  450. ulToDevice: LongInt; // Ordinal position of device within pDevices array */
  451. ulTgtConnType: LongInt; // Type of target connector */
  452. ulTgtConnNum: Longint; // Target Connector Number */
  453. end;
  454. pmci_connlist=^mci_connlist;
  455. //****************************************************************************/
  456. // parameter structure for the MCI_NETWORK_DEFAULT_CONNECTION message */
  457. //****************************************************************************/
  458. type mci_network_default_connection_parms=record
  459. hwndCallback:HWND; // PM window handle for MCI notify message */
  460. szInstallName:ARRAY [0..MAX_DEVICE_NAME] of Char; // Name of section containing default conn. */
  461. ulNumDevices:LongInt; // Number of additional devices in connection */
  462. ulNumPlayConnections:LongInt; // Number of Play connections */
  463. ulNumRecordConnections:LongInt; // Number of Record connections */
  464. pDevices:ARRAY [0..MAX_DEVICE_NAME] of ^Char; // Pointer to array of device names to open */
  465. pPlayConnections:PMCI_CONNLIST; // Pointer to array of connections to "make" */
  466. pRecordConnections:PMCI_CONNLIST; // Pointer to array of connections to "make" */
  467. end;
  468. type pmci_network_default_connection_parms=^mci_network_default_connection_parms;
  469. //******************************************************/
  470. // Additional flags for MCI_NETWORK_DEFAULT_CONNECTION */
  471. //******************************************************/
  472. CONST
  473. MCI_RECORD_DEFAULTS =$00000004;
  474. MCI_PLAY_DEFAULTS =$00000008;
  475. //********************************************************************/
  476. // parameter structure for the MCI_DEFAULT_CONNECTION message */
  477. //********************************************************************/
  478. type mci_Default_Connection_Parms = record
  479. hwndCallback : hwnd; // PM window handle for MCI notify message
  480. pszDevice : pChar; // Device name
  481. ulConnectorType : LongInt; // If specified, ulConnectorIndex is relative
  482. // to the specified connector type
  483. ulConnectorIndex : LongInt; // Connector number
  484. pszToDevice : pChar; // Return device name to which the connection exists
  485. ulToConnectorType: LongInt; // Connector type
  486. ulToConnectorIndex:LongInt; // Connector number
  487. end;
  488. pmci_Default_Connection_Parms = ^mci_Default_Connection_Parms;
  489. //********************************************************************/
  490. // parameter structure for the MCI_DEVICESETTINGS message */
  491. //********************************************************************/
  492. mci_DeviceSettings_Parms = record
  493. hwndCallback : hwnd; // PM window handle for MCI notify message
  494. hwndNotebook : hwnd; // Hwhd to notebook window
  495. usDeviceType : Integer; // Device type
  496. pszDeviceName : pChar; // Device name
  497. end;
  498. pmci_DeviceSettings_Parms = ^mci_DeviceSettings_Parms;
  499. //*********************************************************************/
  500. // parameter structure for the MCI_CUT / COPY / DELETE / UNDO / etc...*/
  501. //*********************************************************************/
  502. mci_Edit_Parms = record
  503. hwndCallback : hwnd; // PM window handle for MCI notify message
  504. ulStructLen : Longint; // Length of the Structure
  505. ulFrom : Longint; // Beginning Point of Range
  506. ulTo : Longint; // ending point of range
  507. pBuff : Pointer; // user buffer
  508. ulBufLen : Longint; // length of user buffer
  509. pHeader : Pointer; // header which describes the buffer
  510. end;
  511. pmci_Edit_Parms = ^mci_Edit_Parms;
  512. //********************************************************************/
  513. // flags and parameter structure for the MCI_ESCAPE message */
  514. // 0x00000X00 are reserved for MCI_ESCAPE flags */
  515. //********************************************************************/
  516. const
  517. mci_Escape_String = $00000100;
  518. type
  519. mci_Escape_Parms = record
  520. hwndCallback : hwnd; // PM window handle for MCI notify message
  521. pszCommand : pChar; // Command to send to the device
  522. end;
  523. pmci_Escape_Parms = ^mci_Escape_Parms;
  524. //********************************************************************/
  525. // flags for the MCI_FREEZE message */
  526. // 0x0000XX00 are reserved for MCI_FREEZE flags */
  527. //********************************************************************/
  528. CONST
  529. MCI_OVLY_FREEZE_RECT = $00000100;
  530. MCI_OVLY_FREEZE_RECT_OUTSIDE = $00000200;
  531. //********************************************************************/
  532. // flags for the MCI_GETDEVCAPS message */
  533. // 0x00XXXX00 are reserved for MCI_GETDEVCAPS flags */
  534. //********************************************************************/
  535. MCI_GETDEVCAPS_MESSAGE = $00000100;
  536. MCI_GETDEVCAPS_ITEM = $00000200;
  537. MCI_GETDEVCAPS_EXTENDED = $00000400;
  538. //************************************************/
  539. // General MCI_GETDEVCAPS item values */
  540. //************************************************/
  541. MCI_GETDEVCAPS_CAN_EJECT = $00000001;
  542. MCI_GETDEVCAPS_CAN_LOCKEJECT = $00000002;
  543. MCI_GETDEVCAPS_CAN_PLAY = $00000003;
  544. MCI_GETDEVCAPS_CAN_PROCESS_INTERNAL = $00000004;
  545. MCI_GETDEVCAPS_CAN_RECORD = $00000005;
  546. MCI_GETDEVCAPS_CAN_RECORD_INSERT = $00000006;
  547. MCI_GETDEVCAPS_CAN_SAVE = $00000007;
  548. MCI_GETDEVCAPS_CAN_SETVOLUME = $00000008;
  549. MCI_GETDEVCAPS_CAN_STREAM = $00000009;
  550. MCI_GETDEVCAPS_DEVICE_TYPE = $0000000A;
  551. MCI_GETDEVCAPS_HAS_AUDIO = $0000000B;
  552. MCI_GETDEVCAPS_HAS_VIDEO = $0000000C;
  553. MCI_GETDEVCAPS_PREROLL_TIME = $0000000D;
  554. MCI_GETDEVCAPS_PREROLL_TYPE = $0000000E;
  555. MCI_GETDEVCAPS_USES_FILES = $0000000F;
  556. MCI_GETDEVCAPS_HAS_IMAGE = $00000010;
  557. MCI_GETDEVCAPS_WAVE_FORMAT = $00000011;
  558. MCI_GETDEVCAPS_CAN_CLOSE_DOOR = $00000012;
  559. //**********************************************/
  560. // return ID's for videodisc MCI_GETDEVCAPS */
  561. //**********************************************/
  562. MCI_VD_MEDIA_CLV=$00000001;
  563. MCI_VD_MEDIA_CAV=$00000002;
  564. MCI_VD_MEDIA_OTHER=$00000003;
  565. //************************************************/
  566. // MCI_GETDEVCAPS item values for video devices */
  567. //************************************************/
  568. MCI_VID_GETDEVCAPS_CAN_STRETCH = MCI_VID_ITEM_BASE;
  569. MCI_VID_GETDEVCAPS_CAN_DISTORT = MCI_VID_ITEM_BASE+1;
  570. MCI_VID_GETDEVCAPS_VIDEO_X_EXTENT = MCI_VID_ITEM_BASE+2;
  571. MCI_VID_GETDEVCAPS_VIDEO_Y_EXTENT = MCI_VID_ITEM_BASE+3;
  572. MCI_VID_GETDEVCAPS_IMAGE_X_EXTENT = MCI_VID_ITEM_BASE+4;
  573. MCI_VID_GETDEVCAPS_IMAGE_Y_EXTENT = MCI_VID_ITEM_BASE+5;
  574. MCI_VID_GETDEVCAPS_MAX_WINDOWS = MCI_VID_ITEM_BASE+6;
  575. MCI_VID_GETDEVCAPS_CAN_FREEZE = MCI_VID_ITEM_BASE+7;
  576. MCI_VID_GETDEVCAPS_OVERLAY_GRAPHICS = MCI_VID_ITEM_BASE+8;
  577. MCI_VID_GETDEVCAPS_CAN_REVERSE = MCI_VID_ITEM_BASE+9;
  578. MCI_VID_GETDEVCAPS_FAST_RATE = MCI_VID_ITEM_BASE+10;
  579. MCI_VID_GETDEVCAPS_SLOW_RATE = MCI_VID_ITEM_BASE+11;
  580. MCI_VID_GETDEVCAPS_NORMAL_RATE = MCI_VID_ITEM_BASE+12;
  581. MCI_VID_GETDEVCAPS_MINIMUM_RATE = MCI_VID_ITEM_BASE+13;
  582. MCI_VID_GETDEVCAPS_MAXIMUM_RATE = MCI_VID_ITEM_BASE+14;
  583. //************************************************/
  584. // MCI_GETDEVCAPS flag values for Videodisc */
  585. //************************************************/
  586. MCI_VD_GETDEVCAPS_CLV = $00000400;
  587. MCI_VD_GETDEVCAPS_CAV = $00000800;
  588. //************************************************/
  589. // MCI_GETDEVCAPS item values for Videodisc */
  590. //************************************************/
  591. MCI_VD_GETDEVCAPS_CAN_REVERSE = MCI_VID_GETDEVCAPS_CAN_REVERSE;
  592. MCI_VD_GETDEVCAPS_FAST_RATE = MCI_VID_GETDEVCAPS_FAST_RATE;
  593. MCI_VD_GETDEVCAPS_SLOW_RATE = MCI_VID_GETDEVCAPS_SLOW_RATE;
  594. MCI_VD_GETDEVCAPS_NORMAL_RATE = MCI_VID_GETDEVCAPS_NORMAL_RATE;
  595. MCI_VD_GETDEVCAPS_MINIMUM_RATE = MCI_VID_GETDEVCAPS_MINIMUM_RATE;
  596. MCI_VD_GETDEVCAPS_MAXIMUM_RATE = MCI_VID_GETDEVCAPS_MAXIMUM_RATE;
  597. //***********************************************/
  598. // MCI_GETDEVCAPS item values for Digital Video */
  599. //***********************************************/
  600. MCI_DGV_GETDEVCAPS_CAN_REVERSE = MCI_VID_GETDEVCAPS_CAN_REVERSE;
  601. MCI_DGV_GETDEVCAPS_CAN_STRETCH = MCI_VID_GETDEVCAPS_CAN_STRETCH;
  602. MCI_DGV_GETDEVCAPS_CAN_DISTORT = MCI_VID_GETDEVCAPS_CAN_DISTORT;
  603. MCI_DGV_GETDEVCAPS_FAST_RATE = MCI_VID_GETDEVCAPS_FAST_RATE;
  604. MCI_DGV_GETDEVCAPS_SLOW_RATE = MCI_VID_GETDEVCAPS_SLOW_RATE;
  605. MCI_DGV_GETDEVCAPS_NORMAL_RATE = MCI_VID_GETDEVCAPS_NORMAL_RATE;
  606. MCI_DGV_GETDEVCAPS_MINIMUM_RATE = MCI_VID_GETDEVCAPS_MINIMUM_RATE;
  607. MCI_DGV_GETDEVCAPS_MAXIMUM_RATE = MCI_VID_GETDEVCAPS_MAXIMUM_RATE;
  608. MCI_DGV_GETDEVCAPS_VIDEO_X_EXTENT = MCI_VID_GETDEVCAPS_VIDEO_X_EXTENT;
  609. MCI_DGV_GETDEVCAPS_VIDEO_Y_EXTENT = MCI_VID_GETDEVCAPS_VIDEO_Y_EXTENT;
  610. MCI_DGV_GETDEVCAPS_IMAGE_X_EXTENT = MCI_VID_GETDEVCAPS_IMAGE_X_EXTENT;
  611. MCI_DGV_GETDEVCAPS_IMAGE_Y_EXTENT = MCI_VID_GETDEVCAPS_IMAGE_Y_EXTENT;
  612. MCI_DGV_GETDEVCAPS_MAX_WINDOWS = MCI_VID_GETDEVCAPS_MAX_WINDOWS;
  613. MCI_DGV_GETDEVCAPS_OVERLAY_GRAPHICS = MCI_VID_GETDEVCAPS_OVERLAY_GRAPHICS;
  614. MCI_DGV_GETDEVCAPS_HAS_TUNER = MCI_DGV_ITEM_BASE;
  615. MCI_DGV_GETDEVCAPS_HAS_TELETEX = MCI_DGV_ITEM_BASE+1;
  616. MCI_DGV_GETDEVCAPS_HAS_AFC = MCI_DGV_ITEM_BASE+2;
  617. //************************************************/
  618. // MCI_GETDEVCAPS item values for Video Overlay */
  619. //************************************************/
  620. MCI_OVLY_GETDEVCAPS_CAN_STRETCH = MCI_VID_GETDEVCAPS_CAN_STRETCH;
  621. MCI_OVLY_GETDEVCAPS_CAN_DISTORT = MCI_VID_GETDEVCAPS_CAN_DISTORT;
  622. MCI_OVLY_GETDEVCAPS_VIDEO_X_EXTENT = MCI_VID_GETDEVCAPS_VIDEO_X_EXTENT;
  623. MCI_OVLY_GETDEVCAPS_VIDEO_Y_EXTENT = MCI_VID_GETDEVCAPS_VIDEO_Y_EXTENT;
  624. MCI_OVLY_GETDEVCAPS_IMAGE_X_EXTENT = MCI_VID_GETDEVCAPS_IMAGE_X_EXTENT;
  625. MCI_OVLY_GETDEVCAPS_IMAGE_Y_EXTENT = MCI_VID_GETDEVCAPS_IMAGE_Y_EXTENT;
  626. MCI_OVLY_GETDEVCAPS_MAX_WINDOWS = MCI_VID_GETDEVCAPS_MAX_WINDOWS;
  627. MCI_OVLY_GETDEVCAPS_CAN_FREEZE = MCI_VID_GETDEVCAPS_CAN_FREEZE;
  628. MCI_OVLY_GETDEVCAPS_OVERLAY_GRAPHICS = MCI_VID_GETDEVCAPS_OVERLAY_GRAPHICS;
  629. MCI_PREROLL_NOTIFIED = $00000001;
  630. MCI_PREROLL_DETERMINISTIC = $00000002;
  631. MCI_PREROLL_NONE = $00000003;
  632. //********************************************************************/
  633. // parameter structure for the MCI_GETDEVCAPS message */
  634. //********************************************************************/
  635. TYPE
  636. mci_GetDevCaps_Parms = record
  637. hwndCallback : hwnd; // PM window handle for MCI notify message
  638. ulReturn : Longint; // Return field
  639. ulItem : Longint; // Item field for GETDEVCAPS item to query
  640. usMessage : integer; // Field to hold MCI message to query
  641. usReserved0 : integer; // Reserved field
  642. end;
  643. pmci_GetDevCaps_Parms = ^mci_GetDevCaps_Parms;
  644. //********************************************************************/
  645. // parameter structure for the MCI_WAVE_GETDEVCAPS */
  646. //********************************************************************/
  647. mci_Wave_GetDevCaps_Parms = record
  648. hwndCallback : hwnd; // PM window handle for MCI notify message
  649. ulReturn : Longint; // Return field
  650. ulItem : Longint; // Item field for GETDEVCAPS item to query
  651. usMessage : Integer; // Field to hold MCI message to query
  652. usReserved0 : Integer; // Reserved field
  653. ulLength : Longint; // Length of structure in ULONGS
  654. ulBitsPerSample : Longint; // Number of Bits per Sample
  655. ulFormatTag : Longint; // Format Tag
  656. ulSamplesPerSec : Longint; // Sampling Rate
  657. ulChannels : Longint; // Number of channels
  658. ulFormatMode : Longint; // Either MCI_RECORD or MCI_PLAY
  659. end;
  660. pmci_Wave_GetDevCaps_Parms = ^mci_Wave_GetDevCaps_Parms;
  661. //********************************************************************/
  662. // potential values for the ulValue field of MCI_AMP_GETDEVCAPS */
  663. //********************************************************************/
  664. CONST
  665. MCI_SET_MONITOR = $00000001;
  666. MCI_SET_MONITOR_AUDIO = $00000002;
  667. MCI_SET_MONITOR_VIDEO = $00000003;
  668. MCI_SET_RECORD = $00000004;
  669. // MCI_SET flags for amp/mixer;
  670. MCI_AMP_SET_BALANCE = $00100000;
  671. MCI_AMP_SET_PITCH = $00200000;
  672. MCI_AMP_SET_TREBLE = $00400000;
  673. MCI_AMP_SET_BASS = $00800000;
  674. MCI_AMP_SET_GAIN = $01000000;
  675. MCI_AMP_SET_ALC = $00000004;
  676. MCI_AMP_SET_AUDIO = $00000008;
  677. MCI_AMP_SET_CROSSOVER = $00000010;
  678. MCI_AMP_SET_LOUDNESS = $00000020;
  679. MCI_AMP_SET_MUTE = $00000040;
  680. MCI_AMP_SET_REVERB = $00000080;
  681. MCI_AMP_SET_STEREOENHANCE = $00000100;
  682. MCI_AMP_SET_CUSTOM1 = $00000200;
  683. MCI_AMP_SET_CUSTOM2 = $00000400;
  684. MCI_AMP_SET_CUSTOM3 = $00000800;
  685. MCI_AMP_SET_LRVOLUME = $00001000;
  686. MCI_AMP_SET_MID = $00020000;
  687. MCI_AMP_SET_CHORUS = $00004000; // typo? 40000?
  688. MCI_AMP_SET_VOLUME = $00080000; // MCI_SET_VOLUME;
  689. MCI_AMP_SET_MONITOR = MCI_SET_MONITOR_AUDIO;
  690. // Potential values for the ulValue field of MCI_AMP_GETDEVCAPS
  691. MCI_AMP_CAN_SET_MONITOR = MCI_AMP_SET_MONITOR;
  692. MCI_AMP_CAN_SET_BALANCE = MCI_AMP_SET_BALANCE;
  693. MCI_AMP_CAN_SET_ALC = MCI_AMP_SET_ALC;
  694. MCI_AMP_CAN_SET_CROSSOVER = MCI_AMP_SET_CROSSOVER;
  695. MCI_AMP_CAN_SET_LOUDNESS = MCI_AMP_SET_LOUDNESS;
  696. MCI_AMP_CAN_SET_MUTE = MCI_AMP_SET_MUTE;
  697. MCI_AMP_CAN_SET_REVERB = MCI_AMP_SET_REVERB;
  698. MCI_AMP_CAN_SET_STEREOENHANCE = MCI_AMP_SET_STEREOENHANCE;
  699. MCI_AMP_CAN_SET_CUSTOM1 = MCI_AMP_SET_CUSTOM1;
  700. MCI_AMP_CAN_SET_CUSTOM2 = MCI_AMP_SET_CUSTOM2;
  701. MCI_AMP_CAN_SET_CUSTOM3 = MCI_AMP_SET_CUSTOM3;
  702. MCI_AMP_CAN_SET_LRVOLUME = MCI_AMP_SET_LRVOLUME;
  703. MCI_AMP_CAN_SET_BASS = MCI_AMP_SET_BASS;
  704. MCI_AMP_CAN_SET_MID = MCI_AMP_SET_MID;
  705. MCI_AMP_CAN_SET_TREBLE = MCI_AMP_SET_TREBLE;
  706. MCI_AMP_CAN_SET_PITCH = MCI_AMP_SET_PITCH;
  707. MCI_AMP_CAN_SET_GAIN = MCI_AMP_SET_GAIN;
  708. MCI_AMP_CAN_SET_CHORUS = MCI_AMP_SET_CHORUS;
  709. MCI_AMP_CAN_SET_VOLUME = MCI_AMP_SET_VOLUME;
  710. //************************************************************************/
  711. // potential values for the ulExtended field of MCI_AMP_GETDEVCAPS_PARMS */
  712. //************************************************************************/
  713. MCI_MIXER_LINE = $00000001;
  714. //********************************************************************/
  715. // parameter structure for the MCI_AMP_GETDEVCAPS */
  716. //********************************************************************/
  717. type
  718. mci_Amp_GetDevCaps_Parms = record
  719. hwndCallback : Longint; // PM window handle for MCI notify message
  720. ulReturn : Longint; // Return field
  721. ulItem : Longint; // Item field for GETDEVCAPS item to query
  722. usMessage : Integer; // Field to hold MCI message to query
  723. usReserved0 : Integer; // Reserved field
  724. ulLength : LongInt; // Length of structure in uLongS
  725. ulValue : LongInt; // Value to determine caps
  726. ulAttribute : LongInt; // Flags to modified the extended parms
  727. ulExtended : LongInt; // Extended flags field
  728. end;
  729. pmci_Amp_GetDevCaps_Parms = ^mci_Amp_GetDevCaps_Parms;
  730. //********************************************************************/
  731. // values for the ulFlags field of MCI_MIXEVENT_PARMS */
  732. //********************************************************************/
  733. CONST
  734. MCI_MIX_ATTRIBUTE = $00000001;
  735. MCI_MIX_CONNECTOR = $00000002;
  736. //********************************************************************/
  737. // values for the lParam field for mix_notify */
  738. //********************************************************************/
  739. MCI_MIXNOTIFY_ON = $00000004;
  740. MCI_MIXNOTIFY_OFF = $00000008;
  741. //********************************************************************/
  742. // value to indicate type of MM_MCIEVENT */
  743. //********************************************************************/
  744. MCI_MIXEVENT = $00000001;
  745. //********************************************************************/
  746. // parameter structure for the MCI_MIXEVENT_PARMS */
  747. //********************************************************************/
  748. type
  749. mci_MixEvent_Parms = record
  750. ulLength : Longint; // Length of struct
  751. hwndMixer : hwnd; // window to inform of mixer changes
  752. ulFlags : Longint; // Either MCI_MIX_ATTRIBUTE
  753. // or MCI_MIX_CONNECTOR
  754. usDeviceID : Integer; // device id to notify of the change
  755. ulDeviceType : LongInt; // Device Type which generated the change
  756. ulDeviceOrdinal : LongInt; // Ordinal of device Type
  757. ulAttribute : LongInt; // Attribute that changed(volume, bass etc.)
  758. ulValue : LongInt; // new value of the attribute which changed
  759. ulConnectorType : LongInt; // Connector Type
  760. ulConnectorIndex : LongInt; // Connector Index
  761. ulConnStatus : LongInt; // Is connector enabled/disabled.
  762. end;
  763. pmci_MixEvent_Parms = ^mci_MixEvent_Parms;
  764. //********************************************************************/
  765. // flag values for the MCI_GETIMAGEBUFFER and MCI_SETIMAGEBUFFER msg */
  766. // 0x0000XX00 are reserved for MCI_GETIMAGEBUFFER and */
  767. // MCI_SETIMAGEBUFFER Flags */
  768. // MCI_CONVERT is defined by MCI_CAPTURE message as 0x00001000L */
  769. //********************************************************************/
  770. CONST
  771. MCI_USE_HW_BUFFER = $00000400;
  772. MCI_GET_HW_BUFFER_PTR = $00000800;
  773. //**************************************************/
  774. // parm structure for MCI_GETIMAGEBUFFER and */
  775. // MCI_SETIMAGEBUFFER messages */
  776. //**************************************************/
  777. type
  778. mci_Image_Parms = record
  779. hwndCallback : hwnd; // PM window handle for MCI notify message
  780. ulPelFormat : Longint; // Format of the image data returned
  781. usBitCount : Integer; // Number of bitsimage data returned
  782. usReserved0 : Integer; // Reserved field
  783. ulImageCompression : LongInt; //
  784. rect : RectL; // Image area to get/set
  785. pPelBuffer : Pointer; // Pel data buffer
  786. ulPelBufferHeight : LongInt; // Number of rows in buffer
  787. ulPelBufferWidth : LongInt; // Pels per row in buffer
  788. ulBufLen : LongInt; // Pel data buffer length in bytes
  789. end;
  790. pmci_Image_Parms = ^mci_Image_Parms;
  791. //********************************************************************/
  792. // flags for the MCI_GETIMAGEPALETTE message */
  793. // 0x0000XX00 are reserved for MCI_GETIMAGEPALETTE flags */
  794. //********************************************************************/
  795. CONST
  796. MCI_FIND_BEST_REGISTERED = $00000100;
  797. MCI_QUERY_REGISTERED_MAP = $00000200;
  798. MCI_QUERY_REGISTERED_MAP_SIZE = $00000400;
  799. //**************************************************/
  800. // parameter structure for MCI_GETIMAGEPALETTE and */
  801. // MCI_SETIMAGEPALETTE messages */
  802. //**************************************************/
  803. type
  804. mci_Palette_Parms = record
  805. hwndCallback : hwnd; // PM window handle for MCI notify message
  806. usRegisteredMap : Integer; // Id of the palette from the registed color map
  807. usReserved0 : Integer; // Reserved field
  808. ulPalEntries : LongInt; // size of the palette returned
  809. pPalette : Pointer; // pointer to the palette
  810. end;
  811. pmci_Palette_Parms = ^mci_Palette_Parms;
  812. //********************************************************************/
  813. // Parameter structure for the MCI_GETTOC message */
  814. //********************************************************************/
  815. mci_Toc_Rec = record
  816. TrackNum : BYTE; // Returned Track Number
  817. ulStartAddr : LongInt; // Starting address of the track in MMTIME format
  818. ulEndAddr : LongInt; // Ending address of the track in MMTIME format
  819. Control : BYTE; // Track Control information
  820. usCountry : Integer; // Country
  821. ulOwner : LongInt; // Owner
  822. ulSerialNum : LongInt; // Serial Number
  823. end;
  824. pTocRec = ^mci_Toc_Rec;
  825. mci_Toc_Parms = record
  826. hwndCallback : hwnd; // PM window handle for MCI notify message
  827. pBuf : pTocRec; // Pointer to array MCI_TOC_REC structures to
  828. // be filled in by the mci device
  829. ulBufSize : LongInt; // Size of the array
  830. end;
  831. pmci_Toc_Parms = ^mci_Toc_Parms;
  832. //********************************************************************/
  833. // parameters for the MCI_GROUP message */
  834. // 0x00XXXX00 are reserved for MCI_GROUP flags */
  835. //********************************************************************/
  836. const
  837. MCI_SYNCHRONIZE = $00000100;
  838. MCI_NOPIECEMEAL = $00000200;
  839. MCI_GROUP_MAKE = $00000400;
  840. MCI_GROUP_DELETE = $00000800;
  841. MCI_GROUP_ALIAS = $00001000;
  842. MCI_GROUP_MASTER = $00002000;
  843. MCI_GROUP_NONE = $00004000; // No group!
  844. type
  845. mci_Group_Parms = record
  846. hwndCallback : hwnd; // PM window handle for MCI notify message.
  847. usGroupID : Integer; // GroupID
  848. usReserved0 : Integer; // RESERVED
  849. ulStructLength : LongInt; // Length of Structure in ULONGS.
  850. usMasterID : Integer; // ID of Master device in Synchrounous groups.
  851. usReserved1 : Integer; // RESERVED
  852. pszGroupAlias : pChar; // Pointer to Alias Name.
  853. ulNumDevices : LongInt; // Number of Devices in group.
  854. paulDeviceID : PLongInt; // Array of Device ids in the group.
  855. end;
  856. pmci_Group_Parms = ^mci_Group_Parms;
  857. //********************************************************************/
  858. // flags for the MCI_INFO message */
  859. // 0x00000X00 are reserved for MCI_INFO flags */
  860. //********************************************************************/
  861. CONST
  862. MCI_INFO_PRODUCT = $00000100;
  863. MCI_INFO_FILE = $00000200;
  864. //***********************************************/
  865. // CD Audio MCI_INFO */
  866. //***********************************************/
  867. MCI_CD_INFO_ID = $00010000;
  868. MCI_CD_INFO_UPC = $00020000;
  869. //***********************************************/
  870. // Videodisc MCI_INFO */
  871. //***********************************************/
  872. MCI_VD_INFO_LABEL = $00001000;
  873. //***********************************************/
  874. // Digital Video MCI_INFO */
  875. //***********************************************/
  876. MCI_DGV_INFO_VIDEO_FILE = $00001000;
  877. MCI_DGV_INFO_IMAGE_FILE = $00002000;
  878. MCI_DGV_INFO_REGION = $00004000;
  879. MCI_DGV_INFO_REGION_TEXT = $00008000;
  880. MCI_DGV_INFO_TEXT = $00010000;
  881. //***********************************************/
  882. // Video Overlay MCI_INFO */
  883. //***********************************************/
  884. MCI_OVLY_INFO_TEXT = $00010000;
  885. type
  886. mci_Info_Parms = record
  887. hwndCallback : hwnd; // PM window handle for MCI notify message
  888. pszReturn : pChar; // Pointer to return buffer
  889. ulRetSize : LongInt; // Return buffer size
  890. end;
  891. pmci_Info_Parms = ^mci_Info_Parms;
  892. //********************************************************************/
  893. // parameters and flags for the MCI_LOAD message */
  894. // 0x00000X00 are reserved for MCI_LOAD flags */
  895. //********************************************************************/
  896. mci_Load_Parms = record
  897. hwndCallback : hwnd; // PM window handle for MCI notify message
  898. pszElementName : pChar; // File name to loads
  899. end;
  900. pmci_Load_Parms = ^mci_Load_Parms;
  901. //********************************************************************/
  902. // parameters and flags for the MCI_MASTERAUDIO */
  903. // 0x000XXX00 are reserved for MCI_MASTERAUDIO flags */
  904. //********************************************************************/
  905. CONST
  906. MCI_ON = $00000100;
  907. MCI_OFF = $00000200;
  908. MCI_HEADPHONES = $00000400;
  909. MCI_SPEAKERS = $00000800;
  910. MCI_MASTERVOL = $00001000;
  911. MCI_SAVESETTING = $00002000;
  912. MCI_QUERYSAVEDSETTING = $00004000;
  913. MCI_QUERYCURRENTSETTING = $00008000;
  914. type
  915. mci_MasterAudio_Parms = record
  916. hwndDummyCallback : hwnd; // Notify not allowed for this message
  917. ulReturn : LongInt; // Return field for query information
  918. ulMasterVolume : LongInt; // Master volume field
  919. end;
  920. pmci_MasterAudio_Parms = ^mci_MasterAudio_Parms;
  921. //********************************************************************/
  922. // parameters and flags for the MCI_OPEN message */
  923. // 0x0000XX00 are reserved for MCI_OPEN flags */
  924. //********************************************************************/
  925. CONST
  926. MCI_OPEN_ELEMENT = $00000100;
  927. MCI_OPEN_ALIAS = $00000200;
  928. MCI_OPEN_ELEMENT_ID = $00000400;
  929. MCI_OPEN_PLAYLIST = $00000800;
  930. MCI_OPEN_TYPE_ID = $00001000;
  931. MCI_OPEN_SHAREABLE = $00002000;
  932. MCI_OPEN_MMIO = $00004000;
  933. MCI_READONLY = $00008000;
  934. //**************************************************/
  935. // parameters and flags for the MCI_OPEN message */
  936. // Digital Video, Video Overlay specific */
  937. //**************************************************/
  938. MCI_VID_OPEN_PARENT = $01000000;
  939. MCI_DGV_OPEN_PARENT = MCI_VID_OPEN_PARENT;
  940. MCI_OVLY_OPEN_PARENT = MCI_VID_OPEN_PARENT;
  941. type
  942. mci_Open_Parms = record
  943. hwndCallback : hwnd; // PM window handle for MCI notify message
  944. usDeviceID : Integer; // Device ID returned to user
  945. usReserved0 : Integer; // Reserved
  946. pszDeviceType : pChar; // Device name from SYSTEM.INI
  947. pszElementName : pChar; // Typically a file name or NULL
  948. pszAlias : pChar; // Optional device alias
  949. end;
  950. pmci_Open_Parms = ^mci_Open_Parms;
  951. //*********************************************************/
  952. // parameters for the AMP MCI_OPEN message */
  953. //*********************************************************/
  954. mci_Amp_Open_Parms = record
  955. hwndCallback : hwnd; // PM window handle for MCI notify message
  956. usDeviceID : Integer; // Device ID returned to user
  957. usReserved0 : Integer; // Reserved field
  958. pszDeviceType : pChar; // Device name from SYSTEM.INI
  959. pszElementName : pChar; // Typically a file name or NULL
  960. pszAlias : pChar; // Optional device alias
  961. pDevDataPtr : Pointer; // Pointer to device data
  962. end;
  963. pmci_Amp_Open_Parms = ^mci_Amp_Open_Parms;
  964. //*********************************************************/
  965. // parameters for MCI_OPEN message for video devices */
  966. //*********************************************************/
  967. mci_Vid_Open_Parms = record
  968. hwndCallback : hwnd; // PM window handle for MCI notify message
  969. usDeviceID : Integer; // Device ID returned to user
  970. usReserved0 : Integer; // Reserved field
  971. pszDeviceType : pChar; // Device name from SYSTEM.INI
  972. pszElementName : pChar; // Typically a file name or NULL
  973. pszAlias : pChar; // Optional device alias
  974. hwndParent : hwnd; // Parent window handle
  975. end;
  976. pmci_Vid_Open_Parms = ^mci_Vid_Open_Parms;
  977. mci_dgv_Open_Parms = mci_Vid_Open_Parms;
  978. pmci_dgv_Open_Parms = ^mci_dgv_Open_Parms;
  979. mci_Ovly_Open_Parms = mci_Vid_Open_Parms;
  980. pmci_Ovly_Open_Parms = ^mci_Ovly_Open_Parms;
  981. //**************************************************/
  982. // MCI_PLAY flag values for videodisc */
  983. //**************************************************/
  984. CONST
  985. MCI_VD_PLAY_REVERSE = $00001000;
  986. MCI_VD_PLAY_FAST = $00002000;
  987. MCI_VD_PLAY_SPEED = $00004000;
  988. MCI_VD_PLAY_SCAN = $00008000;
  989. MCI_VD_PLAY_SLOW = $00010000;
  990. //**************************************************/
  991. // MCI_PLAY flag values for digital video */
  992. //**************************************************/
  993. MCI_DGV_PLAY_REVERSE = $00001000;
  994. MCI_DGV_PLAY_FAST = $00002000;
  995. MCI_DGV_PLAY_SPEED = $00004000;
  996. MCI_DGV_PLAY_SCAN = $00008000;
  997. MCI_DGV_PLAY_SLOW = $00010000;
  998. MCI_DGV_PLAY_REPEAT = $00020000;
  999. type
  1000. mci_Play_Parms = record
  1001. hwndCallback : hwnd;
  1002. ulFrom : LongInt;
  1003. ulTo : LongInt;
  1004. end;
  1005. pmci_Play_Parms = ^mci_Play_Parms;
  1006. mci_VD_Play_Parms = record
  1007. hwndCallback : hwnd;
  1008. ulFrom : LongInt;
  1009. ulTo : LongInt;
  1010. ulFactor : LongInt;
  1011. end;
  1012. pmci_VD_Play_Parms = ^mci_VD_Play_Parms;
  1013. mci_DGV_play_Parms = record
  1014. hwndCallback : hwnd;
  1015. ulFrom : LongInt;
  1016. ulTo : LongInt;
  1017. ulSpeed : LongInt;
  1018. end;
  1019. pmci_DGV_play_Parms = ^mci_DGV_play_Parms;
  1020. //********************************************************************/
  1021. // parameters for the MCI_PUT message */
  1022. // 0x00000X00 are reserved for MCI_PUT flags */
  1023. //********************************************************************/
  1024. CONST
  1025. MCI_VID_PUT_RECT = $00000100;
  1026. MCI_VID_PUT_DESTINATION = $00000200;
  1027. MCI_VID_PUT_SOURCE = $00000400;
  1028. MCI_VID_PUT_WINDOW_MOVE = $00000800;
  1029. MCI_VID_PUT_WINDOW_SIZE = $00001000;
  1030. MCI_DGV_PUT_RECT = MCI_VID_PUT_RECT;
  1031. MCI_DGV_PUT_DESTINATION = MCI_VID_PUT_DESTINATION;
  1032. MCI_DGV_PUT_SOURCE = MCI_VID_PUT_SOURCE;
  1033. MCI_DGV_PUT_WINDOW_MOVE = MCI_VID_PUT_WINDOW_MOVE;
  1034. MCI_DGV_PUT_WINDOW_SIZE = MCI_VID_PUT_WINDOW_SIZE;
  1035. MCI_DGV_MONITOR = $00010000;
  1036. MCI_DGV_RECORD = $00020000;
  1037. MCI_OVLY_PUT_RECT = MCI_VID_PUT_RECT;
  1038. MCI_OVLY_PUT_DESTINATION = MCI_VID_PUT_DESTINATION;
  1039. MCI_OVLY_PUT_SOURCE = MCI_VID_PUT_SOURCE;
  1040. MCI_OVLY_PUT_WINDOW_MOVE = MCI_VID_PUT_WINDOW_MOVE;
  1041. MCI_OVLY_PUT_WINDOW_SIZE = MCI_VID_PUT_WINDOW_SIZE;
  1042. //**************************************************/
  1043. // Rectangle parameters for MCI_PUT, MCI_WHERE, */
  1044. // MCI_FREEZE, and MCI_UNFREEZE */
  1045. //**************************************************/
  1046. type
  1047. mci_Vid_Rect_Parms = record
  1048. hwndCallback : hwnd; // PM window handle for MCI notify message
  1049. rc : RectL; // rectangle array specifying the offset
  1050. // and size of a rectangle
  1051. end;
  1052. mci_Dgv_Rect_Parms = mci_Vid_Rect_Parms;
  1053. pmci_Dgv_Rect_Parms = ^mci_Dgv_Rect_Parms;
  1054. mci_Ovly_Rect_Parms = mci_Vid_Rect_Parms;
  1055. pmci_Ovly_Rect_Parms = ^mci_Ovly_Rect_Parms;
  1056. //********************************************************************/
  1057. // parameters for the MCI_RECORD message */
  1058. // 0x00000X00 are reserved for MCI_RECORD flags */
  1059. //********************************************************************/
  1060. CONST
  1061. MCI_RECORD_INSERT = $00000100;
  1062. MCI_RECORD_OVERWRITE = $00000200;
  1063. MCI_DGV_RECORD_RECT = $00000400;
  1064. type
  1065. mci_Record_Parms = record
  1066. hwndCallback : hwnd; // PM window handle for MCI notify message
  1067. ulFrom : LongInt; // Record from position
  1068. ulTo : LongInt; // Record to position
  1069. end;
  1070. pmci_Record_Parms = ^mci_Record_Parms;
  1071. //********************************************************************/
  1072. // parameters for the MCI_RELEASEDEVICE message */
  1073. // 0xXXXXXX00 are reserved for MCI_RELEASEDEVICE message */
  1074. //********************************************************************/
  1075. CONST
  1076. MCI_RETURN_RESOURCE = $00000100;
  1077. //********************************************************************/
  1078. // parameters for the MCI_RESTORE message */
  1079. // 0x0000XX00 are reserved for MCI_RESTORE flags */
  1080. // MCI_CONVERT is defined by MCI_CAPTURE message as 0x00001000L */
  1081. //********************************************************************/
  1082. MCI_RESTORE_SRC_RECT = $00000100;
  1083. MCI_RESTORE_DEST_RECT = $00000200;
  1084. type mci_Restore_Parms = record
  1085. hwndCallback : hwnd; // PM window handle for MCI notify message
  1086. SrcRect : RectL; // Rectangle array specifying the source
  1087. // area to be restored
  1088. RestRect : RectL; // Rectangle array specifying the destination
  1089. // area to be restored
  1090. end;
  1091. pmci_Restore_Parms = ^mci_Restore_Parms;
  1092. //********************************************************************/
  1093. // parameters for the MCI_SAVE message */
  1094. // 0x00000X00 are reserved for MCI_SAVE flags */
  1095. //********************************************************************/
  1096. const
  1097. MCI_SAVE_FILE = $00000100;
  1098. //************************************************/
  1099. // Digital Video MCI_SAVE */
  1100. //************************************************/
  1101. MCI_DGV_SAVE_VIDEO_FILE = $00001000;
  1102. MCI_DGV_SAVE_IMAGE_FILE = $00002000;
  1103. type
  1104. mci_Save_Parms = record
  1105. hwndCallback : hwnd; // PM window handle for MCI notify message
  1106. pszFileName : pChar; // Filename to save data to
  1107. end;
  1108. pmci_Save_Parms = ^mci_Save_Parms;
  1109. //********************************************************************/
  1110. // parameters for the MCI_SEEK message */
  1111. // 0x00000X00 are reserved for MCI_SEEK flags */
  1112. //********************************************************************/
  1113. const
  1114. MCI_TO_START = $00000100;
  1115. MCI_TO_END = $00000200;
  1116. //************************************************/
  1117. // Digital Video MCI_SEEK */
  1118. //************************************************/
  1119. MCI_DGV_SEEK_TO_NEAREST_IFRAME = $00100000;
  1120. //************************************************/
  1121. // Videodisc MCI_SEEK */
  1122. //************************************************/
  1123. MCI_VD_SEEK_REVERSE = $00001000;
  1124. type
  1125. mci_Seek_Parms = record
  1126. hwndCallback : hwnd; // PM window handle for MCI notify message
  1127. ulTo : LongInt; // Seek to this position
  1128. end;
  1129. pmci_Seek_Parms = ^mci_Seek_Parms;
  1130. //********************************************************************/
  1131. // Flags for the MCI_SET message */
  1132. // 0x00XXXX00 are reserved for MCI_SET flags */
  1133. //********************************************************************/
  1134. const
  1135. MCI_SET_ITEM = $00000100;
  1136. MCI_SET_ON = $00000200;
  1137. MCI_SET_OFF = $00000400;
  1138. MCI_SET_VIDEO = $00000800;
  1139. MCI_SET_AUDIO = $00001000;
  1140. MCI_SET_DOOR_OPEN = $00002000;
  1141. MCI_SET_DOOR_CLOSED = $00004000;
  1142. MCI_SET_SPEED_FORMAT = $00008000;
  1143. MCI_SET_TIME_FORMAT = $00010000;
  1144. MCI_SET_DOOR_LOCK = $00020000;
  1145. MCI_SET_DOOR_UNLOCK = $00040000;
  1146. MCI_SET_VOLUME = $00080000;
  1147. MCI_SET_ITEM_FOURCC = $00100000;
  1148. MCI_SET_REVERSE = $00200000;
  1149. //******************************************************/
  1150. // Values for the ulAudio field */
  1151. //******************************************************/
  1152. MCI_SET_AUDIO_ALL = $00000000;
  1153. MCI_SET_AUDIO_LEFT = $00000001;
  1154. MCI_SET_AUDIO_RIGHT = $00000002;
  1155. //******************************************************/
  1156. // MCI_SET flags for CDXA */
  1157. //******************************************************/
  1158. MCI_CDXA_SET_CHANNEL = $01000000;
  1159. MCI_CDXA_AUDIO_DEVICE = $10000000;
  1160. MCI_CDXA_AUDIO_BUFFER = $02000000;
  1161. MCI_CDXA_VIDEO_BUFFER = $04000000;
  1162. MCI_CDXA_DATA_BUFFER = $08000000;
  1163. //******************************************************/
  1164. // MCI_SET flags for videodisc */
  1165. //******************************************************/
  1166. MCI_VD_SET_ON = MCI_SET_ON;
  1167. MCI_VD_SET_OFF = MCI_SET_OFF;
  1168. MCI_VD_SET_VIDEO = MCI_SET_VIDEO;
  1169. MCI_VD_SET_CHANNEL = $00100000;
  1170. MCI_VD_SET_DISPLAY = $00200000;
  1171. MCI_VD_SET_DONTCARE = $00400000; // Dont care!
  1172. //******************************************************/
  1173. // Generic MCI_SET item values for video devices */
  1174. //******************************************************/
  1175. MCI_VID_SET_VIDEO_COMPRESSION = MCI_VID_ITEM_BASE;
  1176. MCI_VID_SET_IMAGE_COMPRESSION = MCI_VID_ITEM_BASE+1;
  1177. MCI_VID_SET_IMAGE_BITSPERPEL = MCI_VID_ITEM_BASE+2;
  1178. MCI_VID_SET_IMAGE_PELFORMAT = MCI_VID_ITEM_BASE+3;
  1179. MCI_VID_SET_BRIGHTNESS = MCI_VID_ITEM_BASE+4;
  1180. MCI_VID_SET_CONTRAST = MCI_VID_ITEM_BASE+5;
  1181. MCI_VID_SET_HUE = MCI_VID_ITEM_BASE+6;
  1182. MCI_VID_SET_SATURATION = MCI_VID_ITEM_BASE+7;
  1183. MCI_VID_SET_SHARPNESS = MCI_VID_ITEM_BASE+8;
  1184. MCI_VID_SET_GREYSCALE = MCI_VID_ITEM_BASE+9;
  1185. MCI_VID_SET_IMAGE_QUALITY = MCI_VID_ITEM_BASE+10;
  1186. MCI_VID_SET_VIDEO_QUALITY = MCI_VID_ITEM_BASE+11;
  1187. MCI_VID_SET_IMAGE_COMPRESSION_METHOD = MCI_VID_ITEM_BASE+12;
  1188. MCI_VID_SET_MINIMUM_VIDEO_REFRESH_RATE = MCI_VID_ITEM_BASE+13;
  1189. MCI_VID_SET_IMAGE_FILE_FORMAT = MCI_VID_ITEM_BASE+14;
  1190. MCI_VID_SET_REF_INTERVAL = MCI_VID_ITEM_BASE+15;
  1191. MCI_VID_SET_MAXDATARATE = MCI_VID_ITEM_BASE+16;
  1192. MCI_VID_SET_VIDEO_FILE_FORMAT = MCI_VID_ITEM_BASE+17;
  1193. //******************************************************/
  1194. // MCI_SET item values for video overlay */
  1195. //******************************************************/
  1196. MCI_OVLY_SET_IMAGE_COMPRESSION = MCI_VID_SET_IMAGE_COMPRESSION;
  1197. MCI_OVLY_SET_IMAGE_BITSPERPEL = MCI_VID_SET_IMAGE_BITSPERPEL;
  1198. MCI_OVLY_SET_IMAGE_PELFORMAT = MCI_VID_SET_IMAGE_PELFORMAT;
  1199. MCI_OVLY_SET_BRIGHTNESS = MCI_VID_SET_BRIGHTNESS;
  1200. MCI_OVLY_SET_CONTRAST = MCI_VID_SET_CONTRAST;
  1201. MCI_OVLY_SET_HUE = MCI_VID_SET_HUE;
  1202. MCI_OVLY_SET_SATURATION = MCI_VID_SET_SATURATION;
  1203. MCI_OVLY_SET_SHARPNESS = MCI_VID_SET_SHARPNESS;
  1204. MCI_OVLY_SET_GREYSCALE = MCI_VID_SET_GREYSCALE;
  1205. MCI_OVLY_SET_IMAGE_QUALITY = MCI_VID_SET_IMAGE_QUALITY;
  1206. MCI_OVLY_SET_IMAGE_COMPRESSION_METHOD = MCI_VID_SET_IMAGE_COMPRESSION_METHOD;
  1207. MCI_OVLY_SET_MINIMUM_VIDEO_REFRESH_RATE = MCI_VID_SET_MINIMUM_VIDEO_REFRESH_RATE;
  1208. MCI_OVLY_SET_IMAGE_FILE_FORMAT = MCI_VID_SET_IMAGE_FILE_FORMAT;
  1209. //******************************************************/
  1210. // MCI_SET item values for digital video */
  1211. //******************************************************/
  1212. MCI_DGV_SET_VIDEO_COMPRESSION = MCI_VID_SET_VIDEO_COMPRESSION;
  1213. MCI_DGV_SET_IMAGE_COMPRESSION = MCI_VID_SET_IMAGE_COMPRESSION;
  1214. MCI_DGV_SET_IMAGE_BITSPERPEL = MCI_VID_SET_IMAGE_BITSPERPEL;
  1215. MCI_DGV_SET_IMAGE_PELFORMAT = MCI_VID_SET_IMAGE_PELFORMAT;
  1216. MCI_DGV_SET_BRIGHTNESS = MCI_VID_SET_BRIGHTNESS;
  1217. MCI_DGV_SET_CONTRAST = MCI_VID_SET_CONTRAST;
  1218. MCI_DGV_SET_HUE = MCI_VID_SET_HUE;
  1219. MCI_DGV_SET_SATURATION = MCI_VID_SET_SATURATION;
  1220. MCI_DGV_SET_SHARPNESS = MCI_VID_SET_SHARPNESS;
  1221. MCI_DGV_SET_GREYSCALE = MCI_VID_SET_GREYSCALE;
  1222. MCI_DGV_SET_IMAGE_QUALITY = MCI_VID_SET_IMAGE_QUALITY;
  1223. MCI_DGV_SET_VIDEO_QUALITY = MCI_VID_SET_VIDEO_QUALITY;
  1224. MCI_DGV_SET_IMAGE_COMPRESSION_METHOD = MCI_VID_SET_IMAGE_COMPRESSION_METHOD;
  1225. MCI_DGV_SET_MONITOR = MCI_SET_MONITOR;
  1226. MCI_DGV_SET_MINIMUM_VIDEO_REFRESH_RATE = MCI_VID_SET_MINIMUM_VIDEO_REFRESH_RATE;
  1227. MCI_DGV_SET_IMAGE_FILE_FORMAT = MCI_VID_SET_IMAGE_FILE_FORMAT;
  1228. MCI_DGV_SET_REF_INTERVAL = MCI_VID_SET_REF_INTERVAL;
  1229. MCI_DGV_SET_MAXDATARATE = MCI_VID_SET_MAXDATARATE;
  1230. MCI_DGV_SET_VIDEO_FILE_FORMAT = MCI_VID_SET_VIDEO_FILE_FORMAT;
  1231. MCI_DGV_SET_AUDIO_COMPRESSION = MCI_DGV_ITEM_BASE;
  1232. MCI_DGV_SET_AUDIO_QUALITY = MCI_DGV_ITEM_BASE+1;
  1233. MCI_DGV_SET_CHANNELS = MCI_DGV_ITEM_BASE+2;
  1234. MCI_DGV_SET_BITSPERSAMPLE = MCI_DGV_ITEM_BASE+3;
  1235. MCI_DGV_SET_SAMPLESPERSEC = MCI_DGV_ITEM_BASE+4;
  1236. MCI_DGV_SET_FORMATTAG = MCI_DGV_ITEM_BASE+5;
  1237. MCI_DGV_SET_BLOCKALIGN = MCI_DGV_ITEM_BASE+6;
  1238. MCI_DGV_SET_AVGBYTESPERSEC = MCI_DGV_ITEM_BASE+7;
  1239. MCI_DGV_SET_VIDEO_COMPRESSION_SUBTYPE = MCI_DGV_ITEM_BASE+8;
  1240. MCI_DGV_SET_VIDEO_RECORD_RATE = MCI_DGV_ITEM_BASE+9;
  1241. MCI_DGV_SET_VIDEO_RECORD_FRAME_DURATION = MCI_DGV_ITEM_BASE+10;
  1242. MCI_DGV_SET_RECORD_AUDIO = MCI_DGV_ITEM_BASE+11;
  1243. MCI_DGV_SET_TRANSPARENT_COLOR = MCI_DGV_ITEM_BASE+12;
  1244. MCI_DGV_SET_GRAPHIC_TRANSPARENT_COLOR = MCI_DGV_ITEM_BASE+12;
  1245. MCI_DGV_SET_AUDIOSYNC = MCI_DGV_ITEM_BASE+13;
  1246. MCI_DGV_SET_VIDEO_TRANSPARENT_COLOR = MCI_DGV_ITEM_BASE+14;
  1247. //******************************************************/
  1248. // Video file format */
  1249. //******************************************************/
  1250. MCI_VID_FILE_FORMAT_AVI = $20495641;
  1251. //******************************************************/
  1252. // Audio/video/image compression types */
  1253. //******************************************************/
  1254. MCI_AUD_COMP_ADPCM4 = $00000001;
  1255. MCI_AUD_COMP_PCM8 = $00000002;
  1256. MCI_VID_COMP_RTV_2_0 = $00000101;
  1257. MCI_VID_COMP_RTV_2_1 = $00000102;
  1258. MCI_VID_COMP_ULTI = $49544C55;
  1259. MCI_VID_COMP_RT21 = $31325452;
  1260. MCI_VID_COMP_NONE = $20424944; // This is 'DIB ' now.
  1261. MCI_IMG_COMP_NONE = $00000201;
  1262. MCI_IMG_COMP_PIC9_1_0 = $00000202;
  1263. MCI_IMG_COMP_PIC16_1_0 = $00000203;
  1264. MCI_IMG_COMP_JPEG9 = $00000204;
  1265. MCI_IMG_COMP_JPEG9_1_0 = MCI_IMG_COMP_JPEG9;
  1266. MCI_IMG_COMP_BMP_RLE4 = $00000205;
  1267. MCI_IMG_COMP_BMP_RLE8 = $00000206;
  1268. MCI_IMG_COMP_JPEGN = $00000207;
  1269. //******************************************************/
  1270. // PEL Formats (video/image) */
  1271. //******************************************************/
  1272. MCI_VID_PALETTE = $00000001;
  1273. MCI_VID_RGB = $00000002;
  1274. MCI_VID_YUV = $00000003;
  1275. MCI_IMG_PALETTE = MCI_VID_PALETTE;
  1276. MCI_IMG_RGB = MCI_VID_RGB;
  1277. MCI_IMG_YUV = MCI_VID_YUV;
  1278. //******************************************************/
  1279. // Audio/video/image quality levels */
  1280. //******************************************************/
  1281. MCI_AUD_QUALITY_HIGH = $00000001;
  1282. MCI_AUD_QUALITY_MED = $00000002;
  1283. MCI_AUD_QUALITY_LOW = $00000003;
  1284. MCI_VID_QUALITY_HIGH = $00000101;
  1285. MCI_VID_QUALITY_MED = $00000102;
  1286. MCI_VID_QUALITY_LOW = $00000103;
  1287. MCI_VID_QUALITY_BEST = MCI_VID_QUALITY_HIGH;
  1288. MCI_VID_QUALITY_CDROM = MCI_VID_QUALITY_MED;
  1289. MCI_VID_QUALITY_COMPACT = MCI_VID_QUALITY_LOW;
  1290. MCI_VID_QUALITY_BETTER = MCI_VID_QUALITY_MED;
  1291. MCI_VID_QUALITY_GOOD = MCI_VID_QUALITY_LOW;
  1292. MCI_IMG_QUALITY_HIGH = $00000201;
  1293. MCI_IMG_QUALITY_MED = $00000202;
  1294. MCI_IMG_QUALITY_LOW = $00000203;
  1295. //******************************************************/
  1296. // MCI_SET flags for wave audio */
  1297. //******************************************************/
  1298. MCI_WAVE_SET_SAMPLESPERSEC = $01000000;
  1299. MCI_WAVE_SET_AVGBYTESPERSEC = $02000000;
  1300. MCI_WAVE_SET_BLOCKALIGN = $04000000;
  1301. MCI_WAVE_SET_FORMATTAG = $08000000;
  1302. MCI_WAVE_SET_CHANNELS = $10000000;
  1303. MCI_WAVE_SET_BITSPERSAMPLE = $80000000;
  1304. //******************************************************/
  1305. // Wave format tag defines */
  1306. //******************************************************/
  1307. MCI_WAVE_FORMAT_PCM = DATATYPE_WAVEFORM;
  1308. MCI_WAVE_FORMAT_ADPCM = $0002;
  1309. MCI_WAVE_FORMAT_IBM_CVSD = $0005;
  1310. MCI_WAVE_FORMAT_ALAW = DATATYPE_RIFF_ALAW;
  1311. MCI_WAVE_FORMAT_MULAW = DATATYPE_RIFF_MULAW;
  1312. MCI_WAVE_FORMAT_OKI_ADPCM = $0010;
  1313. MCI_WAVE_FORMAT_DVI_ADPCM = $0011;
  1314. MCI_WAVE_FORMAT_DIGISTD = $0015;
  1315. MCI_WAVE_FORMAT_DIGIFIX = $0016;
  1316. MCI_WAVE_FORMAT_AVC_ADPCM = DATATYPE_ADPCM_AVC;
  1317. MCI_WAVE_FORMAT_IBM_ADPCM = DATATYPE_ADPCM_AVC;
  1318. MCI_WAVE_FORMAT_IBM_MULAW = DATATYPE_MULAW;
  1319. MCI_WAVE_FORMAT_IBM_ALAW = DATATYPE_ALAW;
  1320. MCI_WAVE_FORMAT_CT_ADPCM = DATATYPE_CT_ADPCM;
  1321. MCI_WAVE_FORMAT_MPEG1 = DATATYPE_MPEG1AUDIO;
  1322. //******************************************************/
  1323. // MCI_SET flags for sequencer */
  1324. //******************************************************/
  1325. MCI_SEQ_SET_TEMPO = $00100000;
  1326. MCI_SEQ_SET_PORT = $00200000;
  1327. MCI_SEQ_ENABLE_PORT_MAPPER = $00400000;
  1328. MCI_SEQ_DISABLE_PORT_MAPPER = $00800000;
  1329. MCI_SEQ_SET_OFFSET = $01000000;
  1330. MCI_SEQ_SET_MASTER = $02000000;
  1331. MCI_SEQ_SET_SLAVE = $04000000;
  1332. //*********************************************/
  1333. // SEQ time formats */
  1334. //*********************************************/
  1335. MCI_SEQ_SET_SMPTE_24 = $00000100;
  1336. MCI_SEQ_SET_SMPTE_25 = $00000200;
  1337. MCI_SEQ_SET_SMPTE_30 = $00000300;
  1338. MCI_SEQ_SET_SMPTE_30DROP = $00000400;
  1339. MCI_SEQ_SET_SONGPTR = $00000500;
  1340. //*********************************************/
  1341. // SEQ synchronization types */
  1342. //*********************************************/
  1343. MCI_SEQ_MIDI = $00000001;
  1344. MCI_SEQ_SMPTE = $00000002;
  1345. MCI_SEQ_FILE = $00000003;
  1346. MCI_SEQ_NONE = $00000004;
  1347. //*********************************************/
  1348. // SEQ PORT TYPES */
  1349. //*********************************************/
  1350. MCI_SET_NONE = $10000000;
  1351. MIDI_MAPPER = $20000000;
  1352. MCI_MIDI_MAPPER = MIDI_MAPPER;
  1353. type
  1354. mci_Set_Parms = record
  1355. hwndCallback : hwnd; // PM window handle for MCI notify message
  1356. ulTimeFormat : Longint; // Time format to be used by the device
  1357. ulSpeedFormat : Longint; // Speed format used by this device
  1358. ulAudio : Longint; // Channel number for this operation
  1359. // (MCI_SET_AUDIO_LEFT, MCI_SET_AUDIO_RIGHT,
  1360. // MCI_SET_AUDIO_ALL)
  1361. ulLevel : Longint; // Volume, treble or bass level as % of max.
  1362. ulOver : Longint; // Delay time for vectored change in millisecond
  1363. ulItem : Longint; // Item field for set item flags
  1364. ulValue : Longint; // Value associated with item flag
  1365. end;
  1366. pmci_Set_Parms = ^mci_Set_Parms;
  1367. mci_Amp_Set_Parms = mci_Set_Parms;
  1368. pmci_Amp_Set_Parms = ^mci_Amp_Set_Parms;
  1369. mci_DGV_Set_Parms = mci_Set_Parms;
  1370. pmci_DGV_Set_Parms = ^mci_DGV_Set_Parms;
  1371. mci_Ovly_Set_Parms = mci_Set_Parms;
  1372. pmci_Ovly_Set_Parms = ^mci_Ovly_Set_Parms;
  1373. mci_CDXA_Set_Parms = record
  1374. hwndCallback : hwnd; // PM window handle for MCI notify message
  1375. ulTimeFormat : Longint; // Time format to be used by the device
  1376. ulSpeedFormat : Longint; // Speed format used by this device
  1377. ulAudio : Longint; // Channel number for this operation
  1378. // (MCI_SET_AUDIO_LEFT, MCI_SET_AUDIO_RIGHT,
  1379. // MCI_SET_AUDIO_ALL)
  1380. ulLevel : Longint; // Volume, treble or bass level as % of max.
  1381. ulOver : Longint; // Delay time for vectored change in milliseconds
  1382. ulItem : Longint; // Item field for set item flags
  1383. ulValue : Longint; // Value associated with item flag
  1384. ulChannel : Longint; // Channel number
  1385. pPlayList : Pointer; // Pointer to play list
  1386. ulPlayListSize : Longint; // Play list size
  1387. end;
  1388. pmci_CDXA_Set_Parms = ^mci_CDXA_Set_Parms;
  1389. mci_VD_Set_Parms = record
  1390. hwndCallback : hwnd; // PM window handle for MCI notify message
  1391. ulTimeFormat : LongInt; // Time format to be used by the device
  1392. ulSpeedFormat : LongInt; // Speed format used by this device
  1393. ulAudio : LongInt; // Channel number for this operation
  1394. // (MCI_SET_AUDIO_LEFT, MCI_SET_AUDIO_RIGHT,
  1395. // MCI_SET_AUDIO_ALL)
  1396. ulLevel : LongInt; // Volume, treble or bass level as % of max.
  1397. ulOver : LongInt; // Delay time for vectored change in milliseconds
  1398. ulItem : LongInt; // Item field for set item flags
  1399. ulValue : LongInt; // Value associated with item flag
  1400. ulChannel : LongInt; // Videodisc channel
  1401. end;
  1402. pmci_VD_Set_Parms = ^mci_VD_Set_Parms;
  1403. mci_Wave_Set_Parms = record
  1404. hwndCallback : hwnd; // PM window handle for MCI notify message
  1405. ulTimeFormat : Longint; // Time format to be used by the device
  1406. ulSpeedFormat : Longint; // Speed format used by this device
  1407. ulAudio : Longint; // Channel number for this operation
  1408. // (MCI_SET_AUDIO_LEFT, MCI_SET_AUDIO_RIGHT,
  1409. // MCI_SET_AUDIO_ALL)
  1410. ulLevel : Longint; // Volume, trebble or bass level as % of max.
  1411. ulOver : Longint; // Delay time for vectored change in milliseconds
  1412. ulItem : Longint; // Item field for set item flags
  1413. ulValue : Longint; // Value associated with item flag
  1414. usInput : Integer; // Channel for input
  1415. usReserved0 : Integer; // Reserved field
  1416. usOutput : Integer; // Channel for output
  1417. usReserved1 : Integer; // Reserved field
  1418. usFormatTag : Integer; // Format tag
  1419. usReserved2 : Integer; // Reserved field
  1420. usChannels : Integer; // mono(1) or stereo(2)
  1421. usReserved3 : Integer; // Reserved field
  1422. ulSamplesPerSec : Longint; // Samples per seconds
  1423. ulAvgBytesPerSec : LongInt; // Bytes per seconds
  1424. usBlockAlign : Integer; // Block alignment of data
  1425. usReserved4 : Integer; // Reserved field
  1426. usBitsPerSample : Integer; // Bits per seconds
  1427. usReserved5 : Integer; // Reserved field
  1428. end;
  1429. pmci_Wave_Set_Parms = ^mci_Wave_Set_Parms;
  1430. mci_Seq_Set_Parms = record
  1431. hwndCallback : hwnd; // PM window handle for MCI notify message
  1432. ulTimeFormat : Longint; // Time format to be used by the device
  1433. ulSpeedFormat : Longint; // Speed format used by this device
  1434. ulAudio : Longint; // Channel number for this operation
  1435. // (MCI_SET_AUDIO_LEFT, MCI_SET_AUDIO_RIGHT,
  1436. // MCI_SET_AUDIO_ALL)
  1437. ulLevel : Longint; // Volume, trebble or bass level as % of max.
  1438. ulOver : Longint; // Delay time for vectored change in millisecond
  1439. ulItem : Longint; // Item field for set item flags
  1440. ulValue : Longint; // Value associated with item flag
  1441. ulTempo : Longint; // Specified the tempo
  1442. ulPort : Longint; // Output port
  1443. ulSlave : Longint; // Unused field
  1444. ulMaster : Longint; // Unused field
  1445. ulOffset : Longint; // Specified the data offset
  1446. end;
  1447. pmci_Seq_Set_Parms = ^mci_Seq_Set_Parms;
  1448. //********************************************************************/
  1449. // parameters for the MCI_SET_CUEPOINT message */
  1450. // 0x00000x00 are reserved for MCI_SET_CUEPOINT flags */
  1451. //********************************************************************/
  1452. CONST
  1453. MCI_SET_CUEPOINT_ON = $00000100;
  1454. MCI_SET_CUEPOINT_OFF = $00000200;
  1455. type
  1456. mci_CuePoint_Parms = record
  1457. hwndCallback : hwnd; // PM window handle for MCI notify message
  1458. ulCuepoint : Longint; // Specifies the cuepoint location
  1459. usUserParm : Integer; // User parmameter returned on cuepoint
  1460. // notify message
  1461. usReserved0 : Integer; // Reserved field
  1462. end;
  1463. pmci_CuePoint_Parms = ^mci_CuePoint_Parms;
  1464. //********************************************************************/
  1465. // parameters for the MCI_SETIMAGEPALETTE message */
  1466. // 0x000XXX00 are reserved for MCI_SETIMAGEPALETTE flags */
  1467. //********************************************************************/
  1468. CONST
  1469. MCI_SET_REGISTERED = $00000100;
  1470. //********************************************************************/
  1471. // flags and parameter structure for the MCI_SET_POSITION_ADVISE msg */
  1472. // 0x00000X00 are reserved for MCI_SET_POSITION_ADVISE flags */
  1473. //********************************************************************/
  1474. MCI_SET_POSITION_ADVISE_ON = $00000100;
  1475. MCI_SET_POSITION_ADVISE_OFF = $00000200;
  1476. type
  1477. mci_Position_Parms = record
  1478. hwndCallback : hwnd; // PM window handle for MCI notify message
  1479. ulUnits : Longint; // Specifies position change notifiication
  1480. // granularity
  1481. usUserParm : Integer; // User parameter returned on position change
  1482. // notification message.
  1483. Reserved0 : Integer; // Reserved field
  1484. Reserved1 : LongInt; // Reserved field
  1485. end;
  1486. pmci_Position_Parms = ^mci_Position_Parms;
  1487. //********************************************************************/
  1488. // parameter structure for the MCI_SET_SYNC_OFFSET message */
  1489. //********************************************************************/
  1490. mci_Sync_Offset_Parms = record
  1491. hwndCallback : hwnd; // PM window handle for MCI notify message
  1492. ulOffset : LongInt; // Specifies the device media position offset
  1493. // in the currently specified device units.
  1494. end;
  1495. pmci_Sync_Offset_Parms = ^mci_Sync_Offset_Parms;
  1496. //********************************************************************/
  1497. // flags for the MCI_SPIN message */
  1498. // 0x00000X00 are reserved for MCI_SPIN flags */
  1499. //********************************************************************/
  1500. CONST
  1501. MCI_SPIN_UP = $00000100;
  1502. MCI_SPIN_DOWN = $00000200;
  1503. //********************************************************************/
  1504. // MCI_STATUS message flags */
  1505. // 0x000XXX00 are reserved for MCI_STATUS flags */
  1506. // MCI_VOLUME and MCI_VOLUME_DELAY are 0x00000100 and 0x00000200 */
  1507. //********************************************************************/
  1508. MCI_STATUS_ITEM = $00000100;
  1509. MCI_STATUS_START = $00000200;
  1510. MCI_STATUS_CONNECTOR = $00000400;
  1511. //************************************************/
  1512. // General MCI_STATUS item values */
  1513. //************************************************/
  1514. MCI_STATUS_CURRENT_TRACK = $00000001;
  1515. MCI_STATUS_LENGTH = $00000002;
  1516. MCI_STATUS_MODE = $00000003;
  1517. MCI_STATUS_NUMBER_OF_TRACKS = $00000004;
  1518. MCI_STATUS_POSITION = $00000005;
  1519. MCI_STATUS_POSITION_IN_TRACK = $00000006;
  1520. MCI_STATUS_MEDIA_PRESENT = $00000007;
  1521. MCI_STATUS_VOLUME = $00000008;
  1522. MCI_STATUS_READY = $00000009;
  1523. MCI_STATUS_TIME_FORMAT = $0000000A;
  1524. MCI_STATUS_SPEED_FORMAT = $0000000B;
  1525. MCI_STATUS_MONITOR = $0000000C;
  1526. MCI_STATUS_AUDIO = $0000000D;
  1527. MCI_STATUS_VIDEO = $0000000E;
  1528. MCI_STATUS_CLIPBOARD = $0000000F;
  1529. MCI_STATUS_CAN_PASTE = $00000010;
  1530. MCI_STATUS_CAN_REDO = $00000020;
  1531. MCI_STATUS_CAN_UNDO = $00000030;
  1532. //************************************************/
  1533. // ulValue field values for MCI_STATUS_AUDIO */
  1534. //************************************************/
  1535. MCI_STATUS_AUDIO_ALL = $00000000;
  1536. MCI_STATUS_AUDIO_LEFT = $00000001;
  1537. MCI_STATUS_AUDIO_RIGHT = $00000002;
  1538. //************************************************/
  1539. // MCI_STATUS item values for amp/mixer */
  1540. //************************************************/
  1541. MCI_AMP_STATUS_PITCH = MCI_AMP_ITEM_BASE;
  1542. MCI_AMP_STATUS_TREBLE = MCI_AMP_ITEM_BASE+1;
  1543. MCI_AMP_STATUS_BASS = MCI_AMP_ITEM_BASE+2;
  1544. MCI_AMP_STATUS_BALANCE = MCI_AMP_ITEM_BASE+3;
  1545. MCI_AMP_STATUS_GAIN = MCI_AMP_ITEM_BASE+4;
  1546. MCI_AMP_STATUS_MONITOR = MCI_AMP_ITEM_BASE+5;
  1547. MCI_AMP_STATUS_MID = MCI_AMP_ITEM_BASE+6;
  1548. MCI_AMP_STATUS_VOLUME = MCI_STATUS_VOLUME;
  1549. MCI_AMP_STATUS_LOUDNESS = MCI_AMP_ITEM_BASE+7;
  1550. MCI_AMP_STATUS_CROSSOVER = MCI_AMP_ITEM_BASE+8;
  1551. MCI_AMP_STATUS_REVERB = MCI_AMP_ITEM_BASE+9;
  1552. MCI_AMP_STATUS_ALC = MCI_AMP_ITEM_BASE+10;
  1553. MCI_AMP_STATUS_CHORUS = MCI_AMP_ITEM_BASE+11;
  1554. MCI_AMP_STATUS_CUSTOM1 = MCI_AMP_ITEM_BASE+12;
  1555. MCI_AMP_STATUS_CUSTOM2 = MCI_AMP_ITEM_BASE+13;
  1556. MCI_AMP_STATUS_CUSTOM3 = MCI_AMP_ITEM_BASE+14;
  1557. MCI_AMP_STATUS_MUTE = MCI_AMP_ITEM_BASE+15;
  1558. MCI_AMP_STATUS_STEREOENHANCE = MCI_AMP_ITEM_BASE+16;
  1559. //************************************************/
  1560. // MCI_STATUS item values for cd audio */
  1561. //************************************************/
  1562. MCI_CD_STATUS_TRACK_TYPE = MCI_CD_ITEM_BASE;
  1563. MCI_CD_STATUS_TRACK_COPYPERMITTED = MCI_CD_ITEM_BASE+1;
  1564. MCI_CD_STATUS_TRACK_CHANNELS = MCI_CD_ITEM_BASE+2;
  1565. MCI_CD_STATUS_TRACK_PREEMPHASIS = MCI_CD_ITEM_BASE+3;
  1566. //***********************************************/
  1567. // return values for CD MCI_STATUS message with */
  1568. // MCI_CD_STATUS_TRACK_TYPE set */
  1569. //***********************************************/
  1570. MCI_CD_TRACK_AUDIO = $00000001;
  1571. MCI_CD_TRACK_DATA = $00000002;
  1572. MCI_CD_TRACK_OTHER = $00000003;
  1573. //************************************************/
  1574. // MCI_STATUS item values for CDXA */
  1575. //************************************************/
  1576. MCI_CDXA_STATUS_CHANNEL = MCI_CDXA_ITEM_BASE;
  1577. //***********************************************/
  1578. //returned from call for MCI_CDXA_STATUS_CHANNEL*/
  1579. //***********************************************/
  1580. MCI_CDXA_NONE = $00000000;
  1581. //************************************************/
  1582. // MCI_STATUS item values for sequencer */
  1583. //************************************************/
  1584. MCI_SEQ_STATUS_TEMPO = MCI_SEQ_ITEM_BASE;
  1585. MCI_SEQ_STATUS_OFFSET = MCI_SEQ_ITEM_BASE+1;
  1586. MCI_SEQ_STATUS_DIVTYPE = MCI_SEQ_ITEM_BASE+2;
  1587. MCI_SEQ_STATUS_MASTER = MCI_SEQ_ITEM_BASE+3;
  1588. MCI_SEQ_STATUS_PORT = MCI_SEQ_ITEM_BASE+4;
  1589. MCI_SEQ_STATUS_SLAVE = MCI_SEQ_ITEM_BASE+5;
  1590. //*********************************************/
  1591. // Return value for current division type */
  1592. //*********************************************/
  1593. MCI_SEQ_DIV_PPQN = $00000001;
  1594. MCI_SEQ_DIV_SMPTE_24 = $00000002;
  1595. MCI_SEQ_DIV_SMPTE_25 = $00000003;
  1596. MCI_SEQ_DIV_SMPTE_30DROP = $00000004;
  1597. MCI_SEQ_DIV_SMPTE_30 = $00000005;
  1598. //************************************************/
  1599. // MCI_STATUS items for videodisc */
  1600. //************************************************/
  1601. MCI_VD_STATUS_SPEED = MCI_VD_ITEM_BASE;
  1602. MCI_VD_STATUS_FORWARD = MCI_VD_ITEM_BASE+1;
  1603. MCI_VD_MEDIA_TYPE = MCI_VD_ITEM_BASE+2;
  1604. MCI_VD_STATUS_SIDE = MCI_VD_ITEM_BASE+3;
  1605. MCI_VD_STATUS_DISC_SIZE = MCI_VD_ITEM_BASE+4;
  1606. //**********************************************/
  1607. // return values for videodisc status command */
  1608. //**********************************************/
  1609. MCI_VD_SPEED_NORMAL = $00000000;
  1610. MCI_VD_SPEED_FAST = $00000001;
  1611. MCI_VD_SPEED_SLOW = $00000002;
  1612. //************************************************/
  1613. // MCI_STATUS items for wave audio */
  1614. //************************************************/
  1615. MCI_WAVE_STATUS_LEVEL = MCI_WAVE_ITEM_BASE;
  1616. MCI_WAVE_STATUS_SAMPLESPERSEC = MCI_WAVE_ITEM_BASE+1;
  1617. MCI_WAVE_STATUS_AVGBYTESPERSEC = MCI_WAVE_ITEM_BASE+2;
  1618. MCI_WAVE_STATUS_BLOCKALIGN = MCI_WAVE_ITEM_BASE+3;
  1619. MCI_WAVE_STATUS_FORMATTAG = MCI_WAVE_ITEM_BASE+4;
  1620. MCI_WAVE_STATUS_CHANNELS = MCI_WAVE_ITEM_BASE+5;
  1621. MCI_WAVE_STATUS_BITSPERSAMPLE = MCI_WAVE_ITEM_BASE+6;
  1622. //************************************************/
  1623. // Common video MCI_STATUS items */
  1624. //************************************************/
  1625. MCI_VID_STATUS_hwnd = MCI_VID_ITEM_BASE;
  1626. MCI_VID_STATUS_AUDIO_COMPRESSION = MCI_VID_ITEM_BASE+1;
  1627. MCI_VID_STATUS_VIDEO_COMPRESSION = MCI_VID_ITEM_BASE+2;
  1628. MCI_VID_STATUS_IMAGE_COMPRESSION = MCI_VID_ITEM_BASE+3;
  1629. MCI_VID_STATUS_AUDIO_QUALITY = MCI_VID_ITEM_BASE+4;
  1630. MCI_VID_STATUS_VIDEO_QUALITY = MCI_VID_ITEM_BASE+5;
  1631. MCI_VID_STATUS_IMAGE_QUALITY = MCI_VID_ITEM_BASE+6;
  1632. MCI_VID_STATUS_IMAGE_BITSPERPEL = MCI_VID_ITEM_BASE+7;
  1633. MCI_VID_STATUS_IMAGE_PELFORMAT = MCI_VID_ITEM_BASE+8;
  1634. MCI_VID_STATUS_FORWARD = MCI_VID_ITEM_BASE+9;
  1635. MCI_VID_STATUS_NORMAL_RATE = MCI_VID_ITEM_BASE+10;
  1636. MCI_VID_STATUS_VIDEO_X_EXTENT = MCI_VID_ITEM_BASE+11;
  1637. MCI_VID_STATUS_VIDEO_Y_EXTENT = MCI_VID_ITEM_BASE+12;
  1638. MCI_VID_STATUS_IMAGE_X_EXTENT = MCI_VID_ITEM_BASE+13;
  1639. MCI_VID_STATUS_IMAGE_Y_EXTENT = MCI_VID_ITEM_BASE+14;
  1640. MCI_VID_STATUS_BRIGHTNESS = MCI_VID_ITEM_BASE+15;
  1641. MCI_VID_STATUS_CONTRAST = MCI_VID_ITEM_BASE+16;
  1642. MCI_VID_STATUS_HUE = MCI_VID_ITEM_BASE+17;
  1643. MCI_VID_STATUS_SATURATION = MCI_VID_ITEM_BASE+18;
  1644. MCI_VID_STATUS_GREYSCALE = MCI_VID_ITEM_BASE+19;
  1645. MCI_VID_STATUS_SHARPNESS = MCI_VID_ITEM_BASE+20;
  1646. MCI_VID_STATUS_SPEED = MCI_VID_ITEM_BASE+21;
  1647. MCI_VID_STATUS_IMAGE_FILE_FORMAT = MCI_VID_ITEM_BASE+22;
  1648. MCI_VID_STATUS_TRANSPARENT_TYPE = MCI_VID_ITEM_BASE+23;
  1649. MCI_VID_STATUS_REF_INTERVAL = MCI_VID_ITEM_BASE+24;
  1650. MCI_VID_STATUS_MAXDATARATE = MCI_VID_ITEM_BASE+25;
  1651. MCI_VID_STATUS_VIDEO_FILE_FORMAT = MCI_VID_ITEM_BASE+26;
  1652. //************************************************/
  1653. // Status Transparent Type returns */
  1654. // MCI_VID_PALETTE */
  1655. // MCI_VID_RGB */
  1656. // MCI_VID_YUV */
  1657. //************************************************/
  1658. MCI_VID_STATUS_TRANSPARENT_COLOR = MCI_VID_ITEM_BASE+24;
  1659. //************************************************/
  1660. // MCI_STATUS items for digital video */
  1661. //************************************************/
  1662. MCI_DGV_STATUS_hwnd = MCI_VID_STATUS_hwnd;
  1663. MCI_DGV_STATUS_AUDIO_COMPRESSION = MCI_VID_STATUS_AUDIO_COMPRESSION;
  1664. MCI_DGV_STATUS_VIDEO_COMPRESSION = MCI_VID_STATUS_VIDEO_COMPRESSION;
  1665. MCI_DGV_STATUS_IMAGE_COMPRESSION = MCI_VID_STATUS_IMAGE_COMPRESSION;
  1666. MCI_DGV_STATUS_AUDIO_QUALITY = MCI_VID_STATUS_AUDIO_QUALITY;
  1667. MCI_DGV_STATUS_VIDEO_QUALITY = MCI_VID_STATUS_VIDEO_QUALITY;
  1668. MCI_DGV_STATUS_IMAGE_QUALITY = MCI_VID_STATUS_IMAGE_QUALITY;
  1669. MCI_DGV_STATUS_IMAGE_BITSPERPEL = MCI_VID_STATUS_IMAGE_BITSPERPEL;
  1670. MCI_DGV_STATUS_IMAGE_PELFORMAT = MCI_VID_STATUS_IMAGE_PELFORMAT;
  1671. MCI_DGV_STATUS_FORWARD = MCI_VID_STATUS_FORWARD;
  1672. MCI_DGV_STATUS_NORMAL_RATE = MCI_VID_STATUS_NORMAL_RATE;
  1673. MCI_DGV_STATUS_VIDEO_X_EXTENT = MCI_VID_STATUS_VIDEO_X_EXTENT;
  1674. MCI_DGV_STATUS_VIDEO_Y_EXTENT = MCI_VID_STATUS_VIDEO_Y_EXTENT;
  1675. MCI_DGV_STATUS_IMAGE_X_EXTENT = MCI_VID_STATUS_IMAGE_X_EXTENT;
  1676. MCI_DGV_STATUS_IMAGE_Y_EXTENT = MCI_VID_STATUS_IMAGE_Y_EXTENT;
  1677. MCI_DGV_STATUS_BRIGHTNESS = MCI_VID_STATUS_BRIGHTNESS;
  1678. MCI_DGV_STATUS_CONTRAST = MCI_VID_STATUS_CONTRAST;
  1679. MCI_DGV_STATUS_HUE = MCI_VID_STATUS_HUE;
  1680. MCI_DGV_STATUS_SATURATION = MCI_VID_STATUS_SATURATION;
  1681. MCI_DGV_STATUS_SPEED = MCI_VID_STATUS_SPEED;
  1682. MCI_DGV_STATUS_SHARPNESS = MCI_VID_STATUS_SHARPNESS;
  1683. MCI_DGV_STATUS_REF_INTERVAL = MCI_VID_STATUS_REF_INTERVAL;
  1684. MCI_DGV_STATUS_MAXDATARATE = MCI_VID_STATUS_MAXDATARATE;
  1685. MCI_DGV_STATUS_VIDEO_FILE_FORMAT = MCI_VID_STATUS_VIDEO_FILE_FORMAT;
  1686. MCI_DGV_STATUS_CHANNELS = MCI_DGV_ITEM_BASE+13;
  1687. MCI_DGV_STATUS_BITSPERSAMPLE = MCI_DGV_ITEM_BASE+14;
  1688. MCI_DGV_STATUS_SAMPLESPERSEC = MCI_DGV_ITEM_BASE+15;
  1689. MCI_DGV_STATUS_FORMATTAG = MCI_DGV_ITEM_BASE+16;
  1690. MCI_DGV_STATUS_BLOCKALIGN = MCI_DGV_ITEM_BASE+17;
  1691. MCI_DGV_STATUS_AVGBYTESPERSEC = MCI_DGV_ITEM_BASE+18;
  1692. MCI_DGV_STATUS_VIDEO_COMPRESSION_SUBTYPE = MCI_DGV_ITEM_BASE+19;
  1693. MCI_DGV_STATUS_VIDEO_RECORD_RATE = MCI_DGV_ITEM_BASE+20;
  1694. MCI_DGV_STATUS_VIDEO_RECORD_FRAME_DURATION = MCI_DGV_ITEM_BASE+21;
  1695. MCI_DGV_STATUS_RECORD_AUDIO = MCI_DGV_ITEM_BASE+22;
  1696. MCI_DGV_STATUS_TRANSPARENT_COLOR = MCI_DGV_ITEM_BASE+23;
  1697. MCI_DGV_STATUS_GRAPHIC_TRANSPARENT_COLOR = MCI_DGV_ITEM_BASE+23; // MUST BE SAME AS TRANSPARENT COLOR
  1698. MCI_DGV_STATUS_hwnd_MONITOR = MCI_DGV_ITEM_BASE+24;
  1699. MCI_DGV_STATUS_DROPPED_FRAME_PCT = MCI_DGV_ITEM_BASE+25;
  1700. MCI_DGV_STATUS_AUDIOSYNC = MCI_DGV_ITEM_BASE+26;
  1701. MCI_DGV_STATUS_AUDIOSYNC_DIRECTION = MCI_DGV_ITEM_BASE+27;
  1702. MCI_DGV_STATUS_VIDEO_TRANSPARENT_COLOR = MCI_DGV_ITEM_BASE+28; // MUST BE SAME AS TRANSPARENT COLOR
  1703. MCI_DGV_STATUS_TUNER_TV_CHANNEL = MCI_DGV_ITEM_BASE+29;
  1704. MCI_DGV_STATUS_TUNER_LOW_TV_CHANNEL = MCI_DGV_ITEM_BASE+29;
  1705. MCI_DGV_STATUS_TUNER_HIGH_TV_CHANNEL = MCI_DGV_ITEM_BASE+29;
  1706. MCI_DGV_STATUS_TUNER_REGION = MCI_DGV_ITEM_BASE+30;
  1707. MCI_DGV_STATUS_TUNER_FINETUNE = MCI_DGV_ITEM_BASE+31;
  1708. MCI_DGV_STATUS_TUNER_FREQUENCY = MCI_DGV_ITEM_BASE+32;
  1709. MCI_DGV_STATUS_TUNER_AUDIO_CHANNEL = MCI_DGV_ITEM_BASE+33;
  1710. MCI_DGV_STATUS_TUNER_AFC = MCI_DGV_ITEM_BASE+34;
  1711. MCI_DGV_STATUS_VALID_SIGNAL = MCI_DGV_ITEM_BASE+35;
  1712. //************************************************/
  1713. // MCI_STATUS item values for video overlay */
  1714. //************************************************/
  1715. MCI_OVLY_STATUS_hwnd = MCI_VID_STATUS_hwnd;
  1716. MCI_OVLY_STATUS_IMAGE_COMPRESSION = MCI_VID_STATUS_IMAGE_COMPRESSION;
  1717. MCI_OVLY_STATUS_IMAGE_BITSPERPEL = MCI_VID_STATUS_IMAGE_BITSPERPEL;
  1718. MCI_OVLY_STATUS_IMAGE_PELFORMAT = MCI_VID_STATUS_IMAGE_PELFORMAT;
  1719. MCI_OVLY_STATUS_IMAGE_X_EXTENT = MCI_VID_STATUS_IMAGE_X_EXTENT;
  1720. MCI_OVLY_STATUS_IMAGE_Y_EXTENT = MCI_VID_STATUS_IMAGE_Y_EXTENT;
  1721. MCI_OVLY_STATUS_BRIGHTNESS = MCI_VID_STATUS_BRIGHTNESS;
  1722. MCI_OVLY_STATUS_CONTRAST = MCI_VID_STATUS_CONTRAST;
  1723. MCI_OVLY_STATUS_HUE = MCI_VID_STATUS_HUE;
  1724. MCI_OVLY_STATUS_SATURATION = MCI_VID_STATUS_SATURATION;
  1725. MCI_OVLY_STATUS_GREYSCALE = MCI_VID_STATUS_GREYSCALE;
  1726. MCI_OVLY_STATUS_IMAGE_QUALITY = MCI_VID_STATUS_IMAGE_QUALITY;
  1727. MCI_OVLY_STATUS_SHARPNESS = MCI_VID_STATUS_SHARPNESS;
  1728. MCI_OVLY_STATUS_IMAGE_FILE_FORMAT = MCI_VID_STATUS_IMAGE_FILE_FORMAT;
  1729. MCI_OVLY_STATUS_TRANSPARENT_TYPE = MCI_VID_STATUS_TRANSPARENT_TYPE;
  1730. MCI_OVLY_STATUS_TRANSPARENT_COLOR = MCI_VID_STATUS_TRANSPARENT_COLOR;
  1731. //************************************************/
  1732. // Status Mode return values */
  1733. //************************************************/
  1734. MCI_MODE_NOT_READY = $00000001;
  1735. MCI_MODE_PAUSE = $00000002;
  1736. MCI_MODE_PLAY = $00000003;
  1737. MCI_MODE_STOP = $00000004;
  1738. MCI_MODE_RECORD = $00000005;
  1739. MCI_MODE_SEEK = $00000006;
  1740. //************************************************/
  1741. // Status Direction return values */
  1742. //************************************************/
  1743. MCI_FORWARD = $00000000;
  1744. MCI_REVERSE = $00000001;
  1745. type
  1746. mci_Status_Parms = record
  1747. hwndCallback : hwnd; // PM window handle for MCI notify message
  1748. ulReturn : LongInt; // Return field
  1749. ulItem : LongInt; // Item field for STATUS item to query
  1750. ulValue : LongInt; // Status value field (this used to be)
  1751. // ulTrack but was changed in Rel 1.1
  1752. // to extend the status structure.
  1753. // See the programming reference on when
  1754. // ulValue is used and how...
  1755. end;
  1756. pmci_Status_Parms = ^mci_Status_Parms;
  1757. mci_CDXA_Status_Parms = record
  1758. hwndCallback : hwnd; // PM window handle for MCI notify message
  1759. ulReturn : LongInt; // Return field
  1760. ulItem : LongInt; // Item field for STATUS item to query
  1761. ulValue : LongInt; // Status value field (this used to be)
  1762. // ulTrack but was changed in Rel 1.1
  1763. // to extend the status structure.
  1764. // See the programming reference on when
  1765. // ulValue is used and how...
  1766. ulChannel : LongInt; // Channel
  1767. end;
  1768. pmci_CDXA_Status_Parms = ^mci_CDXA_Status_Parms;
  1769. //********************************************************************/
  1770. // flags and parameter structure for the MCI_STEP message */
  1771. // 0x00000X00 are reserved for MCI_STEP flags */
  1772. //********************************************************************/
  1773. CONST
  1774. MCI_STEP_FRAMES = $00000100;
  1775. MCI_STEP_REVERSE = $00000200;
  1776. type
  1777. mci_Step_Parms = record
  1778. hwndCallback : hwnd; // PM window handle for MCI notify message
  1779. ulStep : LongInt; // amount to step in current time format
  1780. end;
  1781. pmci_Step_Parms = ^mci_Step_Parms;
  1782. //********************************************************************/
  1783. // flags for the MCI_SYSINFO message */
  1784. // 0xXXXXXX00 are reserved for MCI_SYSINFO flags */
  1785. //********************************************************************/
  1786. CONST
  1787. MCI_SYSINFO_QUANTITY = $00000100;
  1788. MCI_SYSINFO_OPEN = $00000200;
  1789. MCI_SYSINFO_NAME = $00000400;
  1790. MCI_SYSINFO_INSTALLNAME = $00000800;
  1791. MCI_SYSINFO_ITEM = $00001000;
  1792. MCI_SYSINFO_INI_LOCK = $00002000;
  1793. //*******************************************************/
  1794. // Extended SYSINFO functions */
  1795. //*******************************************************/
  1796. MCI_SYSINFO_INSTALL_DRIVER = $00000001;
  1797. MCI_SYSINFO_QUERY_DRIVER = $00000002;
  1798. MCI_SYSINFO_DELETE_DRIVER = $00000004;
  1799. MCI_SYSINFO_SET_PARAMS = $00000008;
  1800. MCI_SYSINFO_QUERY_PARAMS = $00000010;
  1801. MCI_SYSINFO_SET_CONNECTORS = $00000020;
  1802. MCI_SYSINFO_QUERY_CONNECTORS = $00000040;
  1803. MCI_SYSINFO_SET_EXTENSIONS = $00000080;
  1804. MCI_SYSINFO_QUERY_EXTENSIONS = $00000100;
  1805. MCI_SYSINFO_SET_ALIAS = $00000200;
  1806. MCI_SYSINFO_QUERY_NAMES = $00000400;
  1807. MCI_SYSINFO_SET_DEFAULT = $00000800;
  1808. MCI_SYSINFO_QUERY_DEFAULT = $00001000;
  1809. MCI_SYSINFO_SET_TYPES = $00002000;
  1810. MCI_SYSINFO_QUERY_TYPES = $00004000;
  1811. //*******************************************************/
  1812. // Device Flags */
  1813. //*******************************************************/
  1814. MCI_SYSINFO_DEV_CONTROLLABLE = $00000001;
  1815. MCI_SYSINFO_DEV_NONCONTROLLABLE = $00000002;
  1816. MCI_SYSINFO_DEVICESETTINGS = $00000004;
  1817. //********************************************************************/
  1818. // parameter structures for the MCI_SYSINFO message */
  1819. //********************************************************************/
  1820. TYPE
  1821. MaxDevNameChar = array [0..Max_Device_Name-1] of CHAR;
  1822. MaxVerNumChar = array [0..Max_Version_Number-1] of CHAR;
  1823. MaxProdInfChar = array [0..Max_ProdInfo-1] of CHAR;
  1824. MaxPddNameChar = array [0..Max_Pdd_Name-1] of CHAR;
  1825. MaxClsShort = array [0..Max_Classes-1] of integer;
  1826. MaxClsShort2 = array [0..Max_Classes-1,0..Max_Classes-1] of integer;
  1827. MaxDevParmChar = array [0..Max_Dev_Params-1] of CHAR;
  1828. mci_SysInfo_Parms = record
  1829. hwndDummyCallback : hwnd; // NOTIFY not allowed for SYSINFO
  1830. pszReturn : pChar; // Pointer to return buffer
  1831. ulRetSize : LongInt; // Return buffer size
  1832. ulNumber : LongInt; // Ordinal Number
  1833. usDeviceType : Integer; // MCI device type number
  1834. usReserved0 : Integer; // Reserved field
  1835. ulItem : LongInt; // Used to indicate the MCI_SYSINFO
  1836. pSysInfoParm : Pointer; // extended function to perform
  1837. end;
  1838. pmci_SysInfo_Parms = ^mci_SysInfo_Parms;
  1839. mci_SysInfo_LogDevice = packed record
  1840. szInstallName : MaxDevNameChar; // Device install name
  1841. usDeviceType : Integer; // Device type number
  1842. ulDeviceFlag : Longint; // Flag indicating whether device
  1843. // device is controllable or not
  1844. szVersionNumber : MaxVerNumChar; // INI file version number
  1845. szProductInfo : MaxProdInfChar; // Textual product description
  1846. szMCDDriver : MaxDevNameChar; // MCI Driver dll name
  1847. szVSDDriver : MaxDevNameChar; // VSD dll name
  1848. szPDDName : MaxPddNameChar; // Device PDD name
  1849. szMCDTable : MaxDevNameChar; // Device type command table
  1850. szVSDTable : MaxDevNameChar; // Device specific command table
  1851. usShareType : Integer; // Device sharing mode
  1852. szResourceName : MaxDevNameChar; // Resource name
  1853. usResourceUnits : Integer; // Total resource units available
  1854. // for this device
  1855. usResourceClasses : Integer; // Number of resource classes for
  1856. // this device
  1857. ausClassArray : MaxClsShort; // Maximum number of resource
  1858. // units for each class
  1859. ausValidClassArray : MaxClsShort2; // Valid class combinations
  1860. end;
  1861. pmci_SysInfo_LogDevice = ^mci_SysInfo_LogDevice;
  1862. mci_SysInfo_DevParams = record
  1863. szInstallName : MaxDevNameChar; // Device install name
  1864. szDevParams : MaxDevParmChar; // Device specific parameters
  1865. end;
  1866. pmci_SysInfo_DevParams = ^mci_SysInfo_DevParams;
  1867. type
  1868. Connect = record
  1869. usConnectType : Integer; // Connector type
  1870. szToInstallName : MaxDevNameChar; // Install name this connector
  1871. // is connected to
  1872. usToConnectIndex : Integer; // Connector index this connector
  1873. // is connected to
  1874. end;
  1875. pConnect = ^Connect;
  1876. MaxCnctCnct = array[0..MAX_CONNECTORS-1] of Connect;
  1877. MaxExtChar2 = array[0..MAX_EXTENSIONS-1,0..MAX_EXTENSION_NAME-1] of CHAR;
  1878. MaxAliasNameChar = array[0..Max_Alias_Name-1] of Char;
  1879. MaxTypeBufChar = array[0..Max_TypeBuffer] of Char;
  1880. mci_SysInfo_ConParams = record
  1881. szInstallName : MaxDevNameChar; // Device install name
  1882. usNumConnectors : Integer; // Number of device connectors
  1883. ConnectorList : MaxCnctCnct; // Connector list array
  1884. end;
  1885. pmci_SysInfo_ConParams = ^mci_SysInfo_ConParams;
  1886. mci_SysInfo_Extension = record
  1887. szInstallName : MaxDevNameChar; // Device install name
  1888. usNumExtensions : Integer; // Number of extensions
  1889. szExtension : MaxExtChar2; // Extension name array
  1890. end;
  1891. pmci_SysInfo_Extension = ^mci_SysInfo_Extension;
  1892. mci_SysInfo_Alias = record
  1893. szInstallName : MaxDevNameChar; // Device install name
  1894. szAliasName : MaxAliasNameChar; // Alias name
  1895. end;
  1896. pmci_SysInfo_Alias = ^mci_SysInfo_Alias;
  1897. mci_SysInfo_DefaultDevice = record
  1898. szInstallName : MaxDevNameChar; // Device install name
  1899. usDeviceType : Integer; // Device type number
  1900. end;
  1901. pmci_SysInfo_DefaultDevice = ^mci_SysInfo_DefaultDevice;
  1902. mci_SysInfo_Query_Name = record
  1903. szInstallName : MaxDevNameChar; // Device install name
  1904. szLogicalName : MaxDevNameChar; // Logical device name
  1905. szAliasName : MaxAliasNameChar; // Alias name
  1906. usDeviceType : Integer; // Device type number
  1907. usDeviceOrd : Integer; // Device type ordinal
  1908. end;
  1909. pmci_SysInfo_Query_Name = ^mci_SysInfo_Query_Name;
  1910. mci_SysInfo_Types = record
  1911. szInstallName : MaxDevNameChar; // Device install name
  1912. szTypes : MaxTypeBufChar; // EA types
  1913. end;
  1914. pmci_SysInfo_Types = ^mci_SysInfo_Types;
  1915. //********************************************************************/
  1916. // flags for the MCI_UNFREEZE message */
  1917. // 0x00000X00 are reserved for MCI_UNFREEZE flags */
  1918. //********************************************************************/
  1919. CONST
  1920. MCI_OVLY_UNFREEZE_RECT = $00000100;
  1921. MCI_OVLY_UNFREEZE_RECT_OUTSIDE = $00000200;
  1922. //********************************************************************/
  1923. // flags for the MCI_WHERE message */
  1924. // 0x0000XX00 are reserved for MCI_WHERE flags */
  1925. //********************************************************************/
  1926. MCI_VID_WHERE_DESTINATION = $00000100;
  1927. MCI_VID_WHERE_SOURCE = $00000200;
  1928. MCI_VID_WHERE_WINDOW = $00000400;
  1929. MCI_DGV_WHERE_DESTINATION = MCI_VID_WHERE_DESTINATION;
  1930. MCI_DGV_WHERE_SOURCE = MCI_VID_WHERE_SOURCE;
  1931. MCI_DGV_WHERE_WINDOW = MCI_VID_WHERE_WINDOW;
  1932. MCI_DGV_WHERE_ADJUSTED = $00000800;
  1933. MCI_OVLY_WHERE_DESTINATION = MCI_VID_WHERE_DESTINATION;
  1934. MCI_OVLY_WHERE_SOURCE = MCI_VID_WHERE_SOURCE;
  1935. MCI_OVLY_WHERE_WINDOW = MCI_VID_WHERE_WINDOW;
  1936. //********************************************************************/
  1937. // flags and parameter structure for the MCI_WINDOW message */
  1938. // 0x0000XX00 are reserved for MCI_WINDOW flags */
  1939. //********************************************************************/
  1940. MCI_VID_WINDOW_hwnd = $00000100;
  1941. MCI_VID_WINDOW_STATE = $00000200;
  1942. MCI_VID_WINDOW_TEXT = $00000400;
  1943. MCI_VID_WINDOW_DEFAULT = $00000800;
  1944. MCI_DGV_WINDOW_hwnd = MCI_VID_WINDOW_hwnd;
  1945. MCI_DGV_WINDOW_STATE = MCI_VID_WINDOW_STATE;
  1946. MCI_DGV_WINDOW_TEXT = MCI_VID_WINDOW_TEXT;
  1947. MCI_DGV_WINDOW_DEFAULT = MCI_VID_WINDOW_DEFAULT;
  1948. MCI_OVLY_WINDOW_hwnd = MCI_VID_WINDOW_hwnd;
  1949. MCI_OVLY_WINDOW_STATE = MCI_VID_WINDOW_STATE;
  1950. MCI_OVLY_WINDOW_TEXT = MCI_VID_WINDOW_TEXT;
  1951. MCI_OVLY_WINDOW_DEFAULT = MCI_VID_WINDOW_DEFAULT;
  1952. type
  1953. mci_Vid_Window_Parms = record
  1954. hwndCallback : hwnd; // PM window handle for MCI notify message
  1955. hwndDest : hwnd; // Handle to the client window used for
  1956. // the destination of the video image
  1957. usCmdShow : Integer; // Specifies how the window is displayed
  1958. usReserved1 : Integer; // Reserved
  1959. pszText : pChar; // The text to use as the window caption
  1960. pszAlias : pChar; // The window alias for the display window
  1961. end;
  1962. pmci_Vid_Window_Parms = ^mci_Vid_Window_Parms;
  1963. mci_dgv_Window_Parms = mci_Vid_Window_Parms;
  1964. pmci_dgv_Window_Parms = ^mci_dgv_Window_Parms;
  1965. mci_Ovly_Window_Parms = mci_Vid_Window_Parms;
  1966. pmci_Ovly_Window_Parms = ^mci_Ovly_Window_Parms;
  1967. //********************************************************************/
  1968. // flags and parameter structure for the MCI_TUNER message */
  1969. //********************************************************************/
  1970. CONST
  1971. MCI_DGV_AUDIO_CHANNEL = $00010000;
  1972. MCI_DGV_TV_CHANNEL = $00020000;
  1973. MCI_DGV_FREQUENCY = $00040000;
  1974. MCI_DGV_FINETUNE_PLUS = $00080000;
  1975. MCI_DGV_FINETUNE_MINUS = $00100000;
  1976. MCI_DGV_REGION = $00200000;
  1977. MCI_DGV_AFC_ON = $00400000;
  1978. MCI_DGV_AFC_OFF = $00800000;
  1979. MCI_DGV_POLARIZATION = $00800000;
  1980. MCI_DGV_QUERY = $01000000;
  1981. type
  1982. mci_Dgv_Tuner_Parms = record
  1983. hwndCallback : hwnd; // PM window handle for MCI notify message
  1984. ulFrequency : LongInt; // Tuner Frequency
  1985. ulReserved0 : LongInt; // Reserved 0
  1986. ulTVChannel : LongInt; // TV Channel
  1987. lFineTune : LongInt; // Fine tuning adjustments.
  1988. pszRegion : pChar; // TV Channel Region
  1989. ulReserved1 : LongInt; // Reserved 1
  1990. ulReserved2 : LongInt; // Reserved 2
  1991. end;
  1992. pmci_Dgv_Tuner_Parms = ^mci_Dgv_Tuner_Parms;
  1993. //********************************************************************/
  1994. // */
  1995. // MCI system value defines */
  1996. // */
  1997. //********************************************************************/
  1998. CONST
  1999. MSV_CLOSEDCAPTION = $0;
  2000. MSV_MASTERVOLUME = $1;
  2001. MSV_HEADPHONES = $2;
  2002. MSV_SPEAKERS = $3;
  2003. MSV_WORKPATH = $4;
  2004. MSV_SYSQOSVALUE = $5;
  2005. MSV_SYSQOSERRORFLAG = $6;
  2006. MSV_MAX = $7;
  2007. //********************************************************************/
  2008. // Playlist defines */
  2009. //********************************************************************/
  2010. DATA_OPERATION = 0;
  2011. BRANCH_OPERATION = 1;
  2012. LOOP_OPERATION = 2;
  2013. CALL_OPERATION = 3;
  2014. RETURN_OPERATION = 4;
  2015. EXIT_OPERATION = 5;
  2016. NOP_OPERATION = 6;
  2017. MESSAGE_OPERATION = 7;
  2018. CUEPOINT_OPERATION = 8;
  2019. SEMWAIT_OPERATION = 9;
  2020. SEMPOST_OPERATION = 10;
  2021. //********************************************************************/
  2022. // */
  2023. // MCI Function prototypes */
  2024. // */
  2025. //********************************************************************/
  2026. function mciSendCommand(usDeviceID: Integer; usMessage: Integer; ulParam1: LongInt;
  2027. var Param2; usUserParm: Integer): longint; cdecl;
  2028. function mciSendString(pszCommandBuf: pChar; pszReturnString: pChar;
  2029. wReturnLength: Integer; hwndCallBack: hwnd; usUserParm: Integer): longInt; cdecl;
  2030. function mciGetErrorString(ulError: LongInt; pszBuffer: pChar; usLength: Integer): longint; cdecl;
  2031. function mciMakeGroup(var usDeviceGroupID:Integer; usDeviceCount: Integer;
  2032. var ausDeviceList: Integer; ulFlags: LongInt; ulMMTime: LongInt): longint; cdecl;
  2033. function mciDeleteGroup(usGroupID:Integer): longint; cdecl;
  2034. function mciSetSysValue(iSysValue: Integer; var Value): Boolean; cdecl;
  2035. function mciQuerySysValue(iSysValue: Integer;var Value): Boolean; cdecl;
  2036. function mciGetDeviceID(pszName: pChar): Longint; cdecl;
  2037. Implementation
  2038. function mSecToMM(Value: Cardinal): mmTime;
  2039. begin
  2040. If Value > $FFFFFFFF div 3 then
  2041. mSecToMM := 0
  2042. else
  2043. mSecToMM := Value div 3;
  2044. end;
  2045. function mSecFromMM(Value: mmTime): LongInt;
  2046. begin
  2047. mSecFromMM := (Value+1) div 3;
  2048. end;
  2049. function RedBookToMM(Value: Cardinal): mmTime;
  2050. begin
  2051. RedBookToMM := ( Value and $0000FF ) * 60 * 3000 +
  2052. ( Value and $00FF00 ) * $100 * 3000 +
  2053. ( Value and $FF0000 ) * $10000 * 3000 div 75;
  2054. end;
  2055. function fps24ToMM(Value: Cardinal): mmTime;
  2056. begin
  2057. fps24toMM := ( Value and $000000FF ) * 60 * 60 * 3000 +
  2058. ( Value and $0000FF00 ) * $100 * 60 * 3000 +
  2059. ( Value and $00FF0000 ) * $10000 * 3000 +
  2060. ( Value and $FF000000 ) * $10000 * 3000 div 24;
  2061. end;
  2062. function fps25ToMM(Value: Cardinal): mmTime;
  2063. begin
  2064. fps25ToMM := ( Value and $000000FF ) * 60 * 60 * 3000 +
  2065. ( Value and $0000FF00 ) * $100 * 60 * 3000 +
  2066. ( Value and $00FF0000 ) * $10000 * 3000 +
  2067. ( Value and $FF000000 ) * $10000 * 3000 div 25;
  2068. end;
  2069. function fps30ToMM(Value: Cardinal): mmTime;
  2070. begin
  2071. fps30ToMM := ( Value and $000000FF ) * 60 * 60 * 3000 +
  2072. ( Value and $0000FF00 ) * $100 * 60 * 3000 +
  2073. ( Value and $00FF0000 ) * $10000 * 3000 +
  2074. ( Value and $FF000000 ) * $10000 * 3000 div 30;
  2075. end;
  2076. function HMSToMM(Value: Cardinal): mmTime;
  2077. begin
  2078. HMSToMM := ( Value and $0000FF ) * 60 * 60 * 3000 +
  2079. ( Value and $00FF00 ) * $100 * 60 * 3000 +
  2080. ( Value and $FF0000 ) * $10000 * 3000;
  2081. end;
  2082. function RedBookFromMM(Value: mmTime): Cardinal;
  2083. begin
  2084. if Value+20 >= $100*60*3000 then
  2085. RedBookFromMM := 0
  2086. else
  2087. RedBookFromMM := (Value+20) div (60*3000) +
  2088. ((Value+20) mod ((60*3000) div 3000)) shl 8 +
  2089. ((Value+20) div ((3000 div 75) mod 75)) shl 16;
  2090. end;
  2091. function FPS24FromMM(Value: mmTime): Cardinal;
  2092. begin
  2093. if Value+63 >= $A4CB8000 then // $100*60*60*3000 then
  2094. FPS24FromMM := 0
  2095. else
  2096. FPS24FromMM := ((((Value+63) mod 3000) div (3000 div 24)) shl 24) and $FF000000 +
  2097. ((((Value+63) div 3000) mod 60) shl 16) and $00FF0000 +
  2098. (((((Value+63) div 3000) div 60) mod 60) shl 8) and $0000FF00 +
  2099. ((((Value+63) div 3000) div 60) div 60) and $000000FF;
  2100. end;
  2101. function FPS25FromMM(value: mmTime): Cardinal;
  2102. begin
  2103. if Value+60 >= $A4CB8000 then // $100*60*60*3000
  2104. FPS25FromMM := 0
  2105. else
  2106. FPS25FromMM := ((((Value+60) mod 3000) div (3000 div 25)) shl 24) and $FF000000 +
  2107. ((((Value+60) div 3000) mod 60) shl 16) and $00FF0000 +
  2108. (((((Value+60) div 3000) div 60) mod 60) shl 8) and $0000FF00 +
  2109. ((((Value+60) div 3000) div 60) div 60) and $000000FF;
  2110. end;
  2111. function FPS30FromMM(value: mmTime): Cardinal;
  2112. begin
  2113. if Value+50 >= $A4CB8000 then // $100*60*60*3000
  2114. FPS30FromMM := 0
  2115. else
  2116. FPS30FromMM := ((((Value+50) mod 3000) div (3000 div 30)) shl 24) and $FF000000 +
  2117. ((((Value+50) div 3000) mod 60) shl 16) and $00FF0000 +
  2118. (((((Value+50) div 3000) div 60) mod 60) shl 8) and $0000FF00 +
  2119. ((((Value+50) div 3000) div 60) div 60) and $000000FF;
  2120. end;
  2121. function HMSFromMM(value: mmTime): Cardinal;
  2122. begin
  2123. if Value+50 >= $A4CB8000 then // $100*60*60*3000
  2124. HMSFromMM := 0
  2125. else
  2126. HMSFromMM := (((( Value+50) div 3000) mod 60) shl 16) and $00FF0000 +
  2127. (((((Value+50) div 3000) div 60) mod 60) shl 8) and $0000FF00 +
  2128. (((( Value+50) div 3000) div 60) div 60) and $000000FF;
  2129. end;
  2130. function tmsf_track(time: mmTime): Byte;
  2131. begin
  2132. tmsf_track := byte(time);
  2133. end;
  2134. function tmsf_minute(time: mmTime): Byte;
  2135. begin
  2136. tmsf_minute := pbyte(pchar(@time)+1)^;
  2137. end;
  2138. function tmsf_second(time: mmTime): Byte;
  2139. begin
  2140. tmsf_second := pbyte(pchar(@time)+2)^;
  2141. end;
  2142. function tmsf_frame(time: mmTime): Byte;
  2143. begin
  2144. tmsf_frame := pbyte(pchar(@time)+3)^;
  2145. end;
  2146. function msf_minute(time: mmTime): Byte;
  2147. begin
  2148. msf_minute := byte(time);
  2149. end;
  2150. function msf_second(time: mmTime): Byte;
  2151. begin
  2152. msf_second := pbyte(pchar(@time)+1)^;
  2153. end;
  2154. function msf_frame(time: mmTime): Byte;
  2155. begin
  2156. msf_frame := pbyte(pchar(@time)+2)^;
  2157. end;
  2158. function uLong_lwlb(var ul): Byte; // Low word low byte
  2159. begin
  2160. uLong_lwlb := LongInt(ul);
  2161. end;
  2162. function uLong_lwhb(var ul): Byte; // Low word high byte
  2163. begin
  2164. uLong_lwhb := pbyte(pchar(@ul)+1)^;
  2165. end;
  2166. function uLong_hwlb(var ul): Byte; // High word low byte
  2167. begin
  2168. uLong_hwlb := pbyte(pchar(@ul)+2)^;
  2169. end;
  2170. function uLong_hwhb(var ul): Byte; // High word high byte
  2171. begin
  2172. uLong_hwhb := pbyte(pchar(@ul)+3)^;
  2173. end;
  2174. function uLong_lowd(var ul): Word; // Low word
  2175. begin
  2176. uLong_lowd:=pWord(pchar(@ul))^;
  2177. end;
  2178. function uLong_hiwd(var ul): Word; // High word
  2179. begin
  2180. uLong_hiwd := pWord(pchar(@ul)+Sizeof(Word))^;
  2181. end;
  2182. function mciSendCommand(usDeviceID: Integer; usMessage: Integer; ulParam1: LongInt;
  2183. var Param2; usUserParm: Integer): longint; cdecl; external 'MDM' index 1;
  2184. function mciSendString(pszCommandBuf: pChar; pszReturnString: pChar;
  2185. wReturnLength: Integer; hwndCallBack: hwnd; usUserParm: Integer): longInt; cdecl; external 'MDM' index 2;
  2186. function mciGetErrorString(ulError: LongInt; pszBuffer: pChar; usLength: Integer): longint; cdecl; external 'MDM' index 3;
  2187. function mciMakeGroup(var usDeviceGroupID:Integer; usDeviceCount: Integer;
  2188. var ausDeviceList: Integer; ulFlags: LongInt; ulMMTime: LongInt): longint; cdecl; external 'MDM' index 12;
  2189. function mciDeleteGroup(usGroupID:Integer): longint; cdecl; external 'MDM' index 13;
  2190. function mciSetSysValue(iSysValue: Integer; var Value): Boolean; cdecl; external 'MDM' index 10;
  2191. function mciQuerySysValue(iSysValue: Integer;var Value): Boolean; cdecl; external 'MDM' index 11;
  2192. function mciGetDeviceID(pszName: pChar): Longint; cdecl; external 'MDM' index 16;
  2193. End.
  2194. {
  2195. $Log$
  2196. Revision 1.3 2003-02-15 18:44:55 hajny
  2197. * mmtk directory corrected to lowercase
  2198. Revision 1.1 2003/02/15 16:59:09 hajny
  2199. * mmtk directory corrected to lowercase
  2200. Revision 1.1 2003/02/09 13:49:06 hajny
  2201. + mmtk added
  2202. }