/packages/univint/src/Movies.pas

https://github.com/slibre/freepascal · Pascal · 16706 lines · 3361 code · 1949 blank · 11396 comment · 0 complexity · 895f73aa2f965503d84525a9f913758c MD5 · raw file

Large files are truncated click here to view the full file

  1. {
  2. File: QuickTime/Movies.h
  3. Contains: QuickTime Interfaces.
  4. Version: QuickTime 7.7.1
  5. Copyright: © 1990-2012 by Apple Inc., all rights reserved
  6. Bugs?: For bug reports, consult the following page on
  7. the World Wide Web:
  8. http://www.freepascal.org/bugs.html
  9. }
  10. { Pascal Translation Updated: Jonas Maebe, <jonas@freepascal.org>, October 2009 }
  11. { Pascal Translation Updated: Jonas Maebe, <jonas@freepascal.org>, October 2012 }
  12. {
  13. Modified for use with Free Pascal
  14. Version 308
  15. Please report any bugs to <gpc@microbizz.nl>
  16. }
  17. {$ifc not defined MACOSALLINCLUDE or not MACOSALLINCLUDE}
  18. {$mode macpas}
  19. {$packenum 1}
  20. {$macro on}
  21. {$inline on}
  22. {$calling mwpascal}
  23. unit Movies;
  24. interface
  25. {$setc UNIVERSAL_INTERFACES_VERSION := $0400}
  26. {$setc GAP_INTERFACES_VERSION := $0308}
  27. {$ifc not defined USE_CFSTR_CONSTANT_MACROS}
  28. {$setc USE_CFSTR_CONSTANT_MACROS := TRUE}
  29. {$endc}
  30. {$ifc defined CPUPOWERPC and defined CPUI386}
  31. {$error Conflicting initial definitions for CPUPOWERPC and CPUI386}
  32. {$endc}
  33. {$ifc defined FPC_BIG_ENDIAN and defined FPC_LITTLE_ENDIAN}
  34. {$error Conflicting initial definitions for FPC_BIG_ENDIAN and FPC_LITTLE_ENDIAN}
  35. {$endc}
  36. {$ifc not defined __ppc__ and defined CPUPOWERPC32}
  37. {$setc __ppc__ := 1}
  38. {$elsec}
  39. {$setc __ppc__ := 0}
  40. {$endc}
  41. {$ifc not defined __ppc64__ and defined CPUPOWERPC64}
  42. {$setc __ppc64__ := 1}
  43. {$elsec}
  44. {$setc __ppc64__ := 0}
  45. {$endc}
  46. {$ifc not defined __i386__ and defined CPUI386}
  47. {$setc __i386__ := 1}
  48. {$elsec}
  49. {$setc __i386__ := 0}
  50. {$endc}
  51. {$ifc not defined __x86_64__ and defined CPUX86_64}
  52. {$setc __x86_64__ := 1}
  53. {$elsec}
  54. {$setc __x86_64__ := 0}
  55. {$endc}
  56. {$ifc not defined __arm__ and defined CPUARM}
  57. {$setc __arm__ := 1}
  58. {$elsec}
  59. {$setc __arm__ := 0}
  60. {$endc}
  61. {$ifc defined cpu64}
  62. {$setc __LP64__ := 1}
  63. {$elsec}
  64. {$setc __LP64__ := 0}
  65. {$endc}
  66. {$ifc defined __ppc__ and __ppc__ and defined __i386__ and __i386__}
  67. {$error Conflicting definitions for __ppc__ and __i386__}
  68. {$endc}
  69. {$ifc defined __ppc__ and __ppc__}
  70. {$setc TARGET_CPU_PPC := TRUE}
  71. {$setc TARGET_CPU_PPC64 := FALSE}
  72. {$setc TARGET_CPU_X86 := FALSE}
  73. {$setc TARGET_CPU_X86_64 := FALSE}
  74. {$setc TARGET_CPU_ARM := FALSE}
  75. {$setc TARGET_OS_MAC := TRUE}
  76. {$setc TARGET_OS_IPHONE := FALSE}
  77. {$setc TARGET_IPHONE_SIMULATOR := FALSE}
  78. {$setc TARGET_OS_EMBEDDED := FALSE}
  79. {$elifc defined __ppc64__ and __ppc64__}
  80. {$setc TARGET_CPU_PPC := FALSE}
  81. {$setc TARGET_CPU_PPC64 := TRUE}
  82. {$setc TARGET_CPU_X86 := FALSE}
  83. {$setc TARGET_CPU_X86_64 := FALSE}
  84. {$setc TARGET_CPU_ARM := FALSE}
  85. {$setc TARGET_OS_MAC := TRUE}
  86. {$setc TARGET_OS_IPHONE := FALSE}
  87. {$setc TARGET_IPHONE_SIMULATOR := FALSE}
  88. {$setc TARGET_OS_EMBEDDED := FALSE}
  89. {$elifc defined __i386__ and __i386__}
  90. {$setc TARGET_CPU_PPC := FALSE}
  91. {$setc TARGET_CPU_PPC64 := FALSE}
  92. {$setc TARGET_CPU_X86 := TRUE}
  93. {$setc TARGET_CPU_X86_64 := FALSE}
  94. {$setc TARGET_CPU_ARM := FALSE}
  95. {$ifc defined(iphonesim)}
  96. {$setc TARGET_OS_MAC := FALSE}
  97. {$setc TARGET_OS_IPHONE := TRUE}
  98. {$setc TARGET_IPHONE_SIMULATOR := TRUE}
  99. {$elsec}
  100. {$setc TARGET_OS_MAC := TRUE}
  101. {$setc TARGET_OS_IPHONE := FALSE}
  102. {$setc TARGET_IPHONE_SIMULATOR := FALSE}
  103. {$endc}
  104. {$setc TARGET_OS_EMBEDDED := FALSE}
  105. {$elifc defined __x86_64__ and __x86_64__}
  106. {$setc TARGET_CPU_PPC := FALSE}
  107. {$setc TARGET_CPU_PPC64 := FALSE}
  108. {$setc TARGET_CPU_X86 := FALSE}
  109. {$setc TARGET_CPU_X86_64 := TRUE}
  110. {$setc TARGET_CPU_ARM := FALSE}
  111. {$setc TARGET_OS_MAC := TRUE}
  112. {$setc TARGET_OS_IPHONE := FALSE}
  113. {$setc TARGET_IPHONE_SIMULATOR := FALSE}
  114. {$setc TARGET_OS_EMBEDDED := FALSE}
  115. {$elifc defined __arm__ and __arm__}
  116. {$setc TARGET_CPU_PPC := FALSE}
  117. {$setc TARGET_CPU_PPC64 := FALSE}
  118. {$setc TARGET_CPU_X86 := FALSE}
  119. {$setc TARGET_CPU_X86_64 := FALSE}
  120. {$setc TARGET_CPU_ARM := TRUE}
  121. { will require compiler define when/if other Apple devices with ARM cpus ship }
  122. {$setc TARGET_OS_MAC := FALSE}
  123. {$setc TARGET_OS_IPHONE := TRUE}
  124. {$setc TARGET_IPHONE_SIMULATOR := FALSE}
  125. {$setc TARGET_OS_EMBEDDED := TRUE}
  126. {$elsec}
  127. {$error __ppc__ nor __ppc64__ nor __i386__ nor __x86_64__ nor __arm__ is defined.}
  128. {$endc}
  129. {$ifc defined __LP64__ and __LP64__ }
  130. {$setc TARGET_CPU_64 := TRUE}
  131. {$elsec}
  132. {$setc TARGET_CPU_64 := FALSE}
  133. {$endc}
  134. {$ifc defined FPC_BIG_ENDIAN}
  135. {$setc TARGET_RT_BIG_ENDIAN := TRUE}
  136. {$setc TARGET_RT_LITTLE_ENDIAN := FALSE}
  137. {$elifc defined FPC_LITTLE_ENDIAN}
  138. {$setc TARGET_RT_BIG_ENDIAN := FALSE}
  139. {$setc TARGET_RT_LITTLE_ENDIAN := TRUE}
  140. {$elsec}
  141. {$error Neither FPC_BIG_ENDIAN nor FPC_LITTLE_ENDIAN are defined.}
  142. {$endc}
  143. {$setc ACCESSOR_CALLS_ARE_FUNCTIONS := TRUE}
  144. {$setc CALL_NOT_IN_CARBON := FALSE}
  145. {$setc OLDROUTINENAMES := FALSE}
  146. {$setc OPAQUE_TOOLBOX_STRUCTS := TRUE}
  147. {$setc OPAQUE_UPP_TYPES := TRUE}
  148. {$setc OTCARBONAPPLICATION := TRUE}
  149. {$setc OTKERNEL := FALSE}
  150. {$setc PM_USE_SESSION_APIS := TRUE}
  151. {$setc TARGET_API_MAC_CARBON := TRUE}
  152. {$setc TARGET_API_MAC_OS8 := FALSE}
  153. {$setc TARGET_API_MAC_OSX := TRUE}
  154. {$setc TARGET_CARBON := TRUE}
  155. {$setc TARGET_CPU_68K := FALSE}
  156. {$setc TARGET_CPU_MIPS := FALSE}
  157. {$setc TARGET_CPU_SPARC := FALSE}
  158. {$setc TARGET_OS_UNIX := FALSE}
  159. {$setc TARGET_OS_WIN32 := FALSE}
  160. {$setc TARGET_RT_MAC_68881 := FALSE}
  161. {$setc TARGET_RT_MAC_CFM := FALSE}
  162. {$setc TARGET_RT_MAC_MACHO := TRUE}
  163. {$setc TYPED_FUNCTION_POINTERS := TRUE}
  164. {$setc TYPE_BOOL := FALSE}
  165. {$setc TYPE_EXTENDED := FALSE}
  166. {$setc TYPE_LONGLONG := TRUE}
  167. uses MacTypes,Aliases,Components,Dialogs,Events,Files,Menus,ImageCompression,QDOffscreen,QuickdrawTypes,TextEdit,HIObject,CFBase,CFDictionary,CFString,CoreAudioTypes,AUComponent;
  168. {$endc} {not MACOSALLINCLUDE}
  169. {$ifc TARGET_OS_MAC}
  170. {
  171. Important note regarding availability macros
  172. ============================================
  173. QuickTime APIs that were introduced in QuickTime 6.0 and later are tagged with
  174. availability macros indicating the first Mac OS X version in which they were
  175. *always* available. Such APIs may also be present on systems running earlier
  176. Mac OS X releases when QuickTime updates have been installed.
  177. For example, QTNewDataReferenceFromCFURL was introduced in QuickTime 6.4.
  178. It is always available on Mac OS X 10.3, which shipped with QuickTime 6.4.
  179. However, QuickTime 6.4 can also be installed as an update to Mac OS X 10.2.x,
  180. so QTNewDataReferenceFromCFURL is also available on some systems running
  181. Mac OS X 10.2.x.
  182. QuickTime 6.0 / Mac OS X 10.2 : AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER
  183. QuickTime 6.4 / Mac OS X 10.3 : AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER
  184. QuickTime 7.0 / Mac OS X 10.4 : AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER
  185. QuickTime 7.2 / Mac OS X 10.5 : AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER
  186. As described in /usr/include/AvailabilityMacros.h, you can use the
  187. MAC_OS_X_VERSION_MIN_REQUIRED macro to weak-link to the APIs that may not be
  188. available on the Mac OS X versions your software targets.
  189. }
  190. {$ALIGN MAC68K}
  191. { This sets the user defined exportset name i.e. fw_QuickTime_XManchego, available on 10.5 or later, and comment [4486184] }
  192. { NOTE: Requires Interfacer-35 or later }
  193. { <exportset=fw_QuickTime_XManchego> }
  194. { <exportset=fw_QuickTime_XMaguro> }
  195. { "kFix1" is defined in FixMath as "fixed1" }
  196. { error codes are in Errors.[haa] }
  197. { gestalt codes are in Gestalt.[hpa] }
  198. const
  199. MovieFileType = FourCharCode('MooV');
  200. MovieScrapType = FourCharCode('moov');
  201. const
  202. MovieResourceType = FourCharCode('moov');
  203. MovieForwardPointerResourceType = FourCharCode('fore');
  204. MovieBackwardPointerResourceType = FourCharCode('back');
  205. const
  206. MovieResourceAtomType = FourCharCode('moov');
  207. MovieDataAtomType = FourCharCode('mdat');
  208. FreeAtomType = FourCharCode('free');
  209. SkipAtomType = FourCharCode('skip');
  210. WideAtomPlaceholderType = FourCharCode('wide');
  211. const
  212. MediaHandlerType = FourCharCode('mhlr');
  213. DataHandlerType = FourCharCode('dhlr');
  214. const
  215. VideoMediaType = FourCharCode('vide');
  216. SoundMediaType = FourCharCode('soun');
  217. TextMediaType = FourCharCode('text');
  218. BaseMediaType = FourCharCode('gnrc');
  219. MPEGMediaType = FourCharCode('MPEG');
  220. MusicMediaType = FourCharCode('musi');
  221. TimeCodeMediaType = FourCharCode('tmcd');
  222. SpriteMediaType = FourCharCode('sprt');
  223. FlashMediaType = FourCharCode('flsh');
  224. MovieMediaType = FourCharCode('moov');
  225. TweenMediaType = FourCharCode('twen');
  226. ThreeDeeMediaType = FourCharCode('qd3d');
  227. SkinMediaType = FourCharCode('skin');
  228. HandleDataHandlerSubType = FourCharCode('hndl');
  229. PointerDataHandlerSubType = FourCharCode('ptr ');
  230. NullDataHandlerSubType = FourCharCode('null');
  231. ResourceDataHandlerSubType = FourCharCode('rsrc');
  232. URLDataHandlerSubType = FourCharCode('url ');
  233. AliasDataHandlerSubType = FourCharCode('alis');
  234. WiredActionHandlerType = FourCharCode('wire');
  235. kQTQuartzComposerMediaType = FourCharCode('qtz ');
  236. TimeCode64MediaType = FourCharCode('tc64');
  237. const
  238. VisualMediaCharacteristic = FourCharCode('eyes');
  239. AudioMediaCharacteristic = FourCharCode('ears');
  240. kCharacteristicCanSendVideo = FourCharCode('vsnd');
  241. kCharacteristicProvidesActions = FourCharCode('actn');
  242. kCharacteristicNonLinear = FourCharCode('nonl');
  243. kCharacteristicCanStep = FourCharCode('step');
  244. kCharacteristicHasNoDuration = FourCharCode('noti');
  245. kCharacteristicHasSkinData = FourCharCode('skin');
  246. kCharacteristicProvidesKeyFocus = FourCharCode('keyf');
  247. kCharacteristicSupportsDisplayOffsets = FourCharCode('dtdd');
  248. const
  249. kUserDataMovieControllerType = FourCharCode('ctyp');
  250. kUserDataName = FourCharCode('name');
  251. kUserDataTextAlbum = FourCharCode('©alb');
  252. kUserDataTextArtist = FourCharCode('©ART');
  253. kUserDataTextAuthor = FourCharCode('©aut');
  254. kUserDataTextChapter = FourCharCode('©chp');
  255. kUserDataTextComment = FourCharCode('©cmt');
  256. kUserDataTextComposer = FourCharCode('©com');
  257. kUserDataTextCopyright = FourCharCode('©cpy');
  258. kUserDataTextCreationDate = FourCharCode('©day');
  259. kUserDataTextDescription = FourCharCode('©des');
  260. kUserDataTextDirector = FourCharCode('©dir');
  261. kUserDataTextDisclaimer = FourCharCode('©dis');
  262. kUserDataTextEncodedBy = FourCharCode('©enc');
  263. kUserDataTextFullName = FourCharCode('©nam');
  264. kUserDataTextGenre = FourCharCode('©gen');
  265. kUserDataTextHostComputer = FourCharCode('©hst');
  266. kUserDataTextInformation = FourCharCode('©inf');
  267. kUserDataTextKeywords = FourCharCode('©key');
  268. kUserDataTextMake = FourCharCode('©mak');
  269. kUserDataTextModel = FourCharCode('©mod');
  270. kUserDataTextOriginalArtist = FourCharCode('©ope');
  271. kUserDataTextOriginalFormat = FourCharCode('©fmt');
  272. kUserDataTextOriginalSource = FourCharCode('©src');
  273. kUserDataTextPerformers = FourCharCode('©prf');
  274. kUserDataTextProducer = FourCharCode('©prd');
  275. kUserDataTextPublisher = FourCharCode('©pub');
  276. kUserDataTextProduct = FourCharCode('©PRD');
  277. kUserDataTextSoftware = FourCharCode('©swr');
  278. kUserDataTextSpecialPlaybackRequirements = FourCharCode('©req');
  279. kUserDataTextTrack = FourCharCode('©trk');
  280. kUserDataTextWarning = FourCharCode('©wrn');
  281. kUserDataTextWriter = FourCharCode('©wrt');
  282. kUserDataTextURLLink = FourCharCode('©url');
  283. kUserDataTextEditDate1 = FourCharCode('©ed1');
  284. kUserDataAnimatedGIFLoopCount = FourCharCode('gifc'); { data is big-endian UInt16 }
  285. kQTAnimatedGIFLoopCountInfinite = 0;
  286. kUserDataAnimatedGIFBufferingSize = FourCharCode('gifb'); { data is big-endian UInt32 }
  287. const
  288. kUserDataUnicodeBit = 1 shl 7;
  289. const
  290. DoTheRightThing = 0;
  291. {$ifc not TARGET_CPU_64}
  292. { property types}
  293. type
  294. QTPropertyClass = OSType;
  295. QTPropertyID = OSType;
  296. QTPropertyValueType = OSType;
  297. QTPropertyValueTypePtr = ^QTPropertyValueType;
  298. QTPropertyValuePtr = UnivPtr;
  299. ConstQTPropertyValuePtr = {const} UnivPtr;
  300. MovieTypePtr = ^SInt32; { an opaque type }
  301. Movie = ^MovieTypePtr;
  302. Movie_fix = Movie; { used as field type when a record declaration contains a Movie field identifier }
  303. MoviePtr = ^Movie;
  304. PtrToMovie = MoviePtr;
  305. TrackTypePtr = ^SInt32; { an opaque type }
  306. Track = ^TrackTypePtr;
  307. Track_fix = Track; { used as field type when a record declaration contains a Track field identifier }
  308. MediaTypePtr = ^SInt32; { an opaque type }
  309. Media = ^MediaTypePtr;
  310. UserDataRecordPtr = ^SInt32; { an opaque type }
  311. UserData = ^UserDataRecordPtr;
  312. MovieEditStateRecordPtr = ^SInt32; { an opaque type }
  313. MovieEditState = ^MovieEditStateRecordPtr;
  314. TrackEditStateRecordPtr = ^SInt32; { an opaque type }
  315. TrackEditState = ^TrackEditStateRecordPtr;
  316. QTRestrictionSetRecordPtr = ^SInt32; { an opaque type }
  317. QTRestrictionSet = ^QTRestrictionSetRecordPtr;
  318. SpriteWorld = ^SInt32; { an opaque type }
  319. Sprite = ^SInt32; { an opaque type }
  320. QTTweener = ^SInt32; { an opaque type }
  321. {$endc} {not TARGET_CPU_64}
  322. type
  323. SampleDescription = record
  324. descSize: SInt32;
  325. dataFormat: SInt32;
  326. resvd1: SInt32;
  327. resvd2: SInt16;
  328. dataRefIndex: SInt16;
  329. end;
  330. SampleDescriptionPtr = ^SampleDescription;
  331. type
  332. SampleDescriptionHandle = ^SampleDescriptionPtr;
  333. {$ifc not TARGET_CPU_64}
  334. const
  335. kQTNetworkStatusNoNetwork = -2;
  336. kQTNetworkStatusUncertain = -1;
  337. kQTNetworkStatusNotConnected = 0;
  338. kQTNetworkStatusConnected = 1;
  339. type
  340. QTAtomContainer = Handle;
  341. QTAtom = SIGNEDLONG;
  342. QTAtomType = SIGNEDLONG;
  343. QTAtomID = SIGNEDLONG;
  344. { QTFloatDouble is the 64-bit IEEE-754 standard}
  345. type
  346. QTFloatDouble = Float64;
  347. { QTFloatSingle is the 32-bit IEEE-754 standard}
  348. type
  349. QTFloatSingle = Float32;
  350. {$endc} {not TARGET_CPU_64}
  351. {************************
  352. * SoundDescription
  353. ************************}
  354. type
  355. SoundDescription = record
  356. descSize: SInt32; { total size of SoundDescription including extra data }
  357. dataFormat: SInt32; { sound format }
  358. resvd1: SInt32; { reserved for apple use. set to zero }
  359. resvd2: SInt16; { reserved for apple use. set to zero }
  360. dataRefIndex: SInt16;
  361. version: SInt16; { which version is this data }
  362. revlevel: SInt16; { what version of that codec did this }
  363. vendor: SInt32; { whose codec compressed this data }
  364. numChannels: SInt16; { number of channels of sound }
  365. sampleSize: SInt16; { number of bits per sample }
  366. compressionID: SInt16; { unused. set to zero. }
  367. packetSize: SInt16; { unused. set to zero. }
  368. sampleRate: UnsignedFixed; { sample rate sound is captured at }
  369. end;
  370. SoundDescriptionPtr = ^SoundDescription;
  371. type
  372. SoundDescriptionHandle = ^SoundDescriptionPtr;
  373. { version 1 of the SoundDescription record}
  374. type
  375. SoundDescriptionV1 = record
  376. { original fields}
  377. desc: SoundDescription;
  378. { fixed compression ratio information}
  379. samplesPerPacket: UInt32;
  380. bytesPerPacket: UInt32;
  381. bytesPerFrame: UInt32;
  382. bytesPerSample: UInt32;
  383. { additional atom based fields ([long size, long type, some data], repeat)}
  384. end;
  385. SoundDescriptionV1Ptr = ^SoundDescriptionV1;
  386. type
  387. SoundDescriptionV1Handle = ^SoundDescriptionV1Ptr;
  388. {
  389. Definitions for SoundDescriptionV2:
  390. LPCMFrame = one uncompressed sample in each of the channels (ie. 44100Hz audio has
  391. 44100 LPCMFrames per second, whether it is mono, stereo, 5.1, or whatever).
  392. In other words, LPCMFrames/audioSampleRate is duration in seconds.
  393. AudioPacket = For compressed audio, an AudioPacket is the natural compressed access
  394. unit of that format. For uncompressed audio, an AudioPacket is simply one
  395. LPCMFrame.
  396. }
  397. { version 2 of the SoundDescription record}
  398. type
  399. SoundDescriptionV2 = record
  400. descSize: SInt32; { total size of SoundDescription including extra data }
  401. dataFormat: OSType; { 'lpcm' for uncompressed, compression type otherwise (eg. 'ima4') }
  402. resvd1: SInt32; { reserved for apple use. Must be set to zero }
  403. resvd2: SInt16; { reserved for apple use. Must be set to zero }
  404. dataRefIndex: SInt16;
  405. version: SInt16; { which version is this data (2 in this case) }
  406. revlevel: SInt16; { what version of that codec did this }
  407. vendor: SInt32; { whose codec compressed this data }
  408. always3: SInt16; { Reserved, must be set to 3 }
  409. always16: SInt16; { Reserved, must be set to 16 (0x0010) }
  410. alwaysMinus2: SInt16; { Reserved, must be set to -2 (0xFFFE) }
  411. always0: SInt16; { Reserved, must be set to 0 }
  412. always65536: UInt32; { Reserved, must be set to 65536 (0x00010000) }
  413. sizeOfStructOnly: UInt32; { must be set to sizeof(SoundDescriptionV2), ie. offset to extensions }
  414. audioSampleRate: Float64; { audio frames per second, eg. 44100.0 }
  415. numAudioChannels: UInt32; { any channel assignment info will be in an extension }
  416. always7F000000: SInt32; { Reserved, must be set to 0x7F000000 }
  417. constBitsPerChannel: UInt32; { only set if constant (and only for uncompressed audio) }
  418. formatSpecificFlags: UInt32; { eg. see LPCM flag definitions in CoreAudioTypes.h }
  419. constBytesPerAudioPacket: UInt32; { only set if constant }
  420. constLPCMFramesPerAudioPacket: UInt32; { only set if constant }
  421. { additional atom based extensions ([long size, long type, some data], repeat)}
  422. end;
  423. SoundDescriptionV2Ptr = ^SoundDescriptionV2;
  424. type
  425. SoundDescriptionV2Handle = ^SoundDescriptionV2Ptr;
  426. {$ifc not TARGET_CPU_64}
  427. const
  428. kQTSoundDescriptionKind_Movie_Version1 = FourCharCode('mvv1');
  429. kQTSoundDescriptionKind_Movie_Version2 = FourCharCode('mvv2');
  430. kQTSoundDescriptionKind_Movie_LowestPossibleVersion = FourCharCode('mvlo');
  431. kQTSoundDescriptionKind_Movie_AnyVersion = FourCharCode('mvny');
  432. type
  433. QTSoundDescriptionKind = FourCharCode;
  434. {
  435. * QTSoundDescriptionCreate()
  436. *
  437. * Summary:
  438. * QTSoundDescriptionCreate creates a SoundDescription of the
  439. * requested kind from an AudioStreamBasicDescription, optional
  440. * AudioChannelLayout, and optional magic cookie.
  441. * QTSoundDescriptionCreate allocates the returned
  442. * SoundDescriptionHandle, and the caller is responsible for
  443. * disposing it.
  444. *
  445. * Parameters:
  446. *
  447. * inASBD:
  448. * a description of the format
  449. *
  450. * inLayout:
  451. * the audio channel layout (can be NULL if there isn't one)
  452. *
  453. * inLayoutSize:
  454. * size of the audio channel layout (should be 0 if inLayout is
  455. * NULL)
  456. *
  457. * inMagicCookie:
  458. * the magic cookie for the decompressor (can be NULL if there
  459. * isn't one)
  460. *
  461. * inMagicCookieSize:
  462. * size of the magic cookie (should be 0 if inMagicCookie is NULL)
  463. *
  464. * inRequestedKind:
  465. * the kind of SoundDescription to create
  466. *
  467. * outSoundDesc:
  468. * the resulting SoundDescription. Caller must dispose with
  469. * DisposeHandle.
  470. *
  471. * Availability:
  472. * Mac OS X: in version 10.4 (or QuickTime 7.0) and later in QuickTime.framework
  473. * CarbonLib: not available
  474. * Non-Carbon CFM: not available
  475. }
  476. function QTSoundDescriptionCreate( var inASBD: AudioStreamBasicDescription; inLayout: AudioChannelLayoutPtr { can be NULL }; inLayoutSize: ByteCount; inMagicCookie: UnivPtr; inMagicCookieSize: ByteCount; inRequestedKind: QTSoundDescriptionKind; var outSoundDesc: SoundDescriptionHandle ): OSStatus; external name '_QTSoundDescriptionCreate';
  477. (* AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER *)
  478. {
  479. * QTSoundDescriptionConvert()
  480. *
  481. * Summary:
  482. * Converts from one kind of SoundDescription to another. Note that
  483. * fromKind is reserved for future expansion. You must set it to
  484. * kSoundDescriptionKind_Movie_AnyVersion. You can specify (via
  485. * toKind) that you would like a specific SoundDescription version,
  486. * the lowest possible version (given the constraints of the format
  487. * described by fromDescription), or any version of SoundDescription
  488. * at all. QTSoundDescriptionConvert allocates the returned
  489. * SoundDescriptionHandle and the caller is responsible for
  490. * disposing it.
  491. *
  492. * Parameters:
  493. *
  494. * fromKind:
  495. * reserved, must be set to kSoundDescriptionKind_Movie_AnyVersion
  496. *
  497. * fromDescription:
  498. * input description to be converted
  499. *
  500. * toKind:
  501. * kind of description toDescription will be
  502. *
  503. * toDescription:
  504. * the resulting SoundDescription. Caller must dispose with
  505. * DisposeHandle.
  506. *
  507. * Availability:
  508. * Mac OS X: in version 10.4 (or QuickTime 7.0) and later in QuickTime.framework
  509. * CarbonLib: not available
  510. * Non-Carbon CFM: not available
  511. }
  512. function QTSoundDescriptionConvert( fromKind: QTSoundDescriptionKind; fromDescription: SoundDescriptionHandle; toKind: QTSoundDescriptionKind; var toDescription: SoundDescriptionHandle ): OSStatus; external name '_QTSoundDescriptionConvert';
  513. (* AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER *)
  514. { SoundDescription Properties}
  515. const
  516. {
  517. * Properties of a SoundDescription
  518. }
  519. kQTPropertyClass_SoundDescription = FourCharCode('sdes'); { class for SoundDescription properties}
  520. const
  521. {
  522. * kQTSoundDescriptionPropertyID_AudioChannelLayout: Value is
  523. * AudioChannelLayout (Get/Set) Note that this is a variable sized
  524. * property (since it may contain an array of ChannelDescriptions;
  525. * see CoreAudioTypes.h). You must get the size first (by calling
  526. * QTSoundDescriptionGetPropertyInfo), allocate a struct of that
  527. * size, and then get the property.
  528. }
  529. kQTSoundDescriptionPropertyID_AudioChannelLayout = FourCharCode('clay');
  530. {
  531. * kQTSoundDescriptionPropertyID_MagicCookie: Value is opaque bytes
  532. * (Get/Set) Note that this is a variable sized property (since it is
  533. * completely defined by the codec in question). You must get the
  534. * size first (by calling QTSoundDescriptionGetPropertyInfo),
  535. * allocate a struct of that size, and then get the property.
  536. }
  537. kQTSoundDescriptionPropertyID_MagicCookie = FourCharCode('kuki');
  538. {
  539. * kQTSoundDescriptionPropertyID_AudioStreamBasicDescription: Value
  540. * is AudioStreamBasicDescription (Get only)
  541. }
  542. kQTSoundDescriptionPropertyID_AudioStreamBasicDescription = FourCharCode('asbd');
  543. {
  544. * kQTSoundDescriptionPropertyID_BitRate: Value is UInt32 in bits per
  545. * second (Get only) kQTSoundDescriptionPropertyID_BitRate Note that
  546. * this property may not be available for formats that are inherently
  547. * very variable in bitrate and highly source-data dependent (such as
  548. * Apple Lossless).
  549. }
  550. kQTSoundDescriptionPropertyID_BitRate = FourCharCode('brat');
  551. {
  552. * kQTSoundDescriptionPropertyID_UserReadableText: Value is
  553. * CFStringRef (Get only) QTSoundDescriptionGetProperty does a
  554. * CFRetain of the returned CFString on behalf of the caller, so the
  555. * caller is responsible for calling CFRelease on the returned
  556. * CFString.
  557. }
  558. kQTSoundDescriptionPropertyID_UserReadableText = FourCharCode('text');
  559. {
  560. * QTSoundDescriptionGetPropertyInfo()
  561. *
  562. * Summary:
  563. * Gets info about a particular property of a SoundDescription.
  564. *
  565. * Parameters:
  566. *
  567. * inDesc:
  568. * SoundDescription being interrogated
  569. *
  570. * inPropClass:
  571. * class of property being requested
  572. *
  573. * inPropID:
  574. * ID of property being requested
  575. *
  576. * outPropType:
  577. * type of property is returned here (can be NULL)
  578. *
  579. * outPropValueSize:
  580. * size of property is returned here (can be NULL)
  581. *
  582. * outPropertyFlags:
  583. * property flags are returned here (can be NULL)
  584. *
  585. * Availability:
  586. * Mac OS X: in version 10.4 (or QuickTime 7.0) and later in QuickTime.framework
  587. * CarbonLib: not available
  588. * Non-Carbon CFM: not available
  589. }
  590. function QTSoundDescriptionGetPropertyInfo( inDesc: SoundDescriptionHandle; inPropClass: QTPropertyClass; inPropID: QTPropertyID; outPropType: QTPropertyValueTypePtr { can be NULL }; outPropValueSize: ByteCountPtr { can be NULL }; outPropertyFlags: UInt32Ptr { can be NULL } ): OSStatus; external name '_QTSoundDescriptionGetPropertyInfo';
  591. (* AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER *)
  592. {
  593. * QTSoundDescriptionGetProperty()
  594. *
  595. * Summary:
  596. * Gets a particular property of a SoundDescription.
  597. *
  598. * Parameters:
  599. *
  600. * inDesc:
  601. * SoundDescription being interrogated
  602. *
  603. * inPropClass:
  604. * class of property being requested
  605. *
  606. * inPropID:
  607. * ID of property being requested
  608. *
  609. * inPropValueSize:
  610. * size of property value buffer
  611. *
  612. * outPropValueAddress:
  613. * pointer to property value buffer
  614. *
  615. * outPropValueSizeUsed:
  616. * actual size of returned property value (can be NULL)
  617. *
  618. * Availability:
  619. * Mac OS X: in version 10.4 (or QuickTime 7.0) and later in QuickTime.framework
  620. * CarbonLib: not available
  621. * Non-Carbon CFM: not available
  622. }
  623. function QTSoundDescriptionGetProperty( inDesc: SoundDescriptionHandle; inPropClass: QTPropertyClass; inPropID: QTPropertyID; inPropValueSize: ByteCount; outPropValueAddress: QTPropertyValuePtr; outPropValueSizeUsed: ByteCountPtr { can be NULL } ): OSStatus; external name '_QTSoundDescriptionGetProperty';
  624. (* AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER *)
  625. {
  626. * QTSoundDescriptionSetProperty()
  627. *
  628. * Summary:
  629. * Sets a particular property of a SoundDescription.
  630. *
  631. * Parameters:
  632. *
  633. * inDesc:
  634. * SoundDescription being modified
  635. *
  636. * inPropClass:
  637. * class of property being set
  638. *
  639. * inPropID:
  640. * ID of property being set
  641. *
  642. * inPropValueSize:
  643. * size of property value buffer
  644. *
  645. * inPropValueAddress:
  646. * pointer to property value buffer
  647. *
  648. * Availability:
  649. * Mac OS X: in version 10.4 (or QuickTime 7.0) and later in QuickTime.framework
  650. * CarbonLib: not available
  651. * Non-Carbon CFM: not available
  652. }
  653. function QTSoundDescriptionSetProperty( inDesc: SoundDescriptionHandle; inPropClass: QTPropertyClass; inPropID: QTPropertyID; inPropValueSize: ByteCount; inPropValueAddress: ConstQTPropertyValuePtr ): OSStatus; external name '_QTSoundDescriptionSetProperty';
  654. (* AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER *)
  655. { Sound Description Extensions}
  656. {
  657. * AddSoundDescriptionExtension()
  658. *
  659. * Availability:
  660. * Mac OS X: in version 10.0 and later in QuickTime.framework
  661. * CarbonLib: in CarbonLib 1.0 and later
  662. * Non-Carbon CFM: in QuickTimeLib 3.0 and later
  663. * Windows: in qtmlClient.lib 3.0 and later
  664. }
  665. function AddSoundDescriptionExtension( desc: SoundDescriptionHandle; extension: Handle; idType: OSType ): OSErr; external name '_AddSoundDescriptionExtension';
  666. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  667. {
  668. * GetSoundDescriptionExtension()
  669. *
  670. * Availability:
  671. * Mac OS X: in version 10.0 and later in QuickTime.framework
  672. * CarbonLib: in CarbonLib 1.0 and later
  673. * Non-Carbon CFM: in QuickTimeLib 3.0 and later
  674. * Windows: in qtmlClient.lib 3.0 and later
  675. }
  676. function GetSoundDescriptionExtension( desc: SoundDescriptionHandle; var extension: Handle; idType: OSType ): OSErr; external name '_GetSoundDescriptionExtension';
  677. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  678. {
  679. * RemoveSoundDescriptionExtension()
  680. *
  681. * Availability:
  682. * Mac OS X: in version 10.0 and later in QuickTime.framework
  683. * CarbonLib: in CarbonLib 1.0 and later
  684. * Non-Carbon CFM: in QuickTimeLib 3.0 and later
  685. * Windows: in qtmlClient.lib 3.0 and later
  686. }
  687. function RemoveSoundDescriptionExtension( desc: SoundDescriptionHandle; idType: OSType ): OSErr; external name '_RemoveSoundDescriptionExtension';
  688. (* AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER *)
  689. {$endc} {not TARGET_CPU_64}
  690. const
  691. kTx3gSampleType = FourCharCode('tx3g');
  692. kTx3gFontTableAtomType = FourCharCode('ftab');
  693. kTx3gBlinkAtomType = FourCharCode('blnk');
  694. type
  695. Tx3gRGBAColor = record
  696. red: UInt8;
  697. green: UInt8;
  698. blue: UInt8;
  699. transparency: UInt8;
  700. end;
  701. type
  702. Tx3gStyleRecordPtr = ^Tx3gStyleRecord;
  703. Tx3gStyleRecord = record
  704. startChar: UInt16;
  705. endChar: UInt16;
  706. fontID: UInt16;
  707. fontFace: UInt8;
  708. fontSize: UInt8;
  709. fontColor: Tx3gRGBAColor;
  710. end;
  711. type
  712. Tx3gStylePtr = Tx3gStyleRecordPtr;
  713. Tx3gStyleHandle = ^Tx3gStylePtr;
  714. Tx3gStyleTableRecordPtr = ^Tx3gStyleTableRecord;
  715. Tx3gStyleTableRecord = record
  716. count: UInt16;
  717. table: array [0..0] of Tx3gStyleRecord;
  718. end;
  719. type
  720. Tx3gStyleTablePtr = Tx3gStyleTableRecordPtr;
  721. Tx3gStyleTableHandle = ^Tx3gStyleTablePtr;
  722. Tx3gFontRecord = record
  723. fontID: UInt16;
  724. nameLength: UInt8;
  725. name: array[0..0] of SInt8;
  726. end;
  727. Tx3gFontRecordPtr = ^Tx3gFontRecord;
  728. type
  729. Tx3gFontTableRecordPtr = ^Tx3gFontTableRecord;
  730. Tx3gFontTableRecord = record
  731. entryCount: UInt16;
  732. fontEntries: array[0..0] of Tx3gFontRecord;
  733. end;
  734. type
  735. Tx3gFontTablePtr = Tx3gFontTableRecordPtr;
  736. Tx3gFontTableHandle = ^Tx3gFontTablePtr;
  737. Tx3gDescription = record
  738. descSize: SInt32;
  739. dataFormat: SInt32;
  740. resvd1: SInt32;
  741. resvd2: SInt16;
  742. dataRefIndex: SInt16;
  743. displayFlags: UInt32;
  744. horizontalJustification: char;
  745. verticalJustification: char;
  746. backgroundColor: Tx3gRGBAColor;
  747. defaultTextBox: Rect;
  748. defaultStyle: Tx3gStyleRecord;
  749. end;
  750. Tx3gDescriptionPtr = ^Tx3gDescription;
  751. type
  752. Tx3gDescriptionHandle = ^Tx3gDescriptionPtr;
  753. {$ifc TARGET_CPU_64}
  754. { QuickDraw legacy }
  755. type
  756. QTRGBColor = record
  757. red: UInt16; { magnitude of red component}
  758. green: UInt16; { magnitude of green component}
  759. blue: UInt16; { magnitude of blue component}
  760. end;
  761. {$endc} {TARGET_CPU_64}
  762. type
  763. TextDescription = record
  764. descSize: SInt32; { Total size of TextDescription}
  765. dataFormat: SInt32; { 'text'}
  766. resvd1: SInt32;
  767. resvd2: SInt16;
  768. dataRefIndex: SInt16;
  769. displayFlags: SInt32; { see enum below for flag values}
  770. textJustification: SInt32; { Can be: teCenter,teFlush -Default,-Right,-Left}
  771. {$ifc TARGET_CPU_64}
  772. bgColor: QTRGBColor; { Background color}
  773. {$elsec} {TARGET_CPU_64}
  774. bgColor: RGBColor; { Background color}
  775. {$endc} {TARGET_CPU_64}
  776. defaultTextBox: Rect; { Location to place the text within the track bounds}
  777. defaultStyle: ScrpSTElement; { Default style (struct defined in TextEdit.h)}
  778. defaultFontName: array[0..0] of SInt8; { Font Name (pascal string - struct extended to fit) }
  779. end;
  780. TextDescriptionPtr = ^TextDescription;
  781. type
  782. TextDescriptionHandle = ^TextDescriptionPtr;
  783. {$ifc not TARGET_CPU_64}
  784. type
  785. SpriteDescription = record
  786. descSize: SIGNEDLONG; { total size of SpriteDescription including extra data }
  787. dataFormat: SIGNEDLONG; { }
  788. resvd1: SIGNEDLONG; { reserved for apple use }
  789. resvd2: SInt16;
  790. dataRefIndex: SInt16;
  791. version: SIGNEDLONG; { which version is this data }
  792. decompressorType: OSType; { which decompressor to use, 0 for no decompression }
  793. sampleFlags: SIGNEDLONG; { how to interpret samples }
  794. end;
  795. SpriteDescriptionPtr = ^SpriteDescription;
  796. type
  797. SpriteDescriptionHandle = ^SpriteDescriptionPtr;
  798. FlashDescription = record
  799. descSize: SIGNEDLONG;
  800. dataFormat: SIGNEDLONG;
  801. resvd1: SIGNEDLONG;
  802. resvd2: SInt16;
  803. dataRefIndex: SInt16;
  804. version: SIGNEDLONG; { which version is this data }
  805. decompressorType: OSType; { which decompressor to use, 0 for no decompression }
  806. flags: SIGNEDLONG;
  807. end;
  808. FlashDescriptionPtr = ^FlashDescription;
  809. type
  810. FlashDescriptionHandle = ^FlashDescriptionPtr;
  811. ThreeDeeDescription = record
  812. descSize: SIGNEDLONG; { total size of ThreeDeeDescription including extra data }
  813. dataFormat: SIGNEDLONG; { }
  814. resvd1: SIGNEDLONG; { reserved for apple use }
  815. resvd2: SInt16;
  816. dataRefIndex: SInt16;
  817. version: SIGNEDLONG; { which version is this data }
  818. rendererType: SIGNEDLONG; { which renderer to use, 0 for default }
  819. decompressorType: SIGNEDLONG; { which decompressor to use, 0 for default }
  820. end;
  821. ThreeDeeDescriptionPtr = ^ThreeDeeDescription;
  822. type
  823. ThreeDeeDescriptionHandle = ^ThreeDeeDescriptionPtr;
  824. DataReferenceRecordPtr = ^DataReferenceRecord;
  825. DataReferenceRecord = record
  826. dataRefType: OSType;
  827. dataRef: Handle;
  828. end;
  829. type
  830. DataReferencePtr = DataReferenceRecordPtr;
  831. {--------------------------
  832. Music Sample Description
  833. --------------------------}
  834. type
  835. MusicDescription = record
  836. descSize: SIGNEDLONG;
  837. dataFormat: SIGNEDLONG; { 'musi' }
  838. resvd1: SIGNEDLONG;
  839. resvd2: SInt16;
  840. dataRefIndex: SInt16;
  841. musicFlags: SIGNEDLONG;
  842. headerData: array [0..0] of UNSIGNEDLONG; { variable size! }
  843. end;
  844. MusicDescriptionPtr = ^MusicDescription;
  845. type
  846. MusicDescriptionHandle = ^MusicDescriptionPtr;
  847. const
  848. kMusicFlagDontPlay2Soft = 1 shl 0;
  849. kMusicFlagDontSlaveToMovie = 1 shl 1;
  850. const
  851. dfDontDisplay = 1 shl 0; { Don't display the text}
  852. dfDontAutoScale = 1 shl 1; { Don't scale text as track bounds grows or shrinks}
  853. dfClipToTextBox = 1 shl 2; { Clip update to the textbox}
  854. dfUseMovieBGColor = 1 shl 3; { Set text background to movie's background color}
  855. dfShrinkTextBoxToFit = 1 shl 4; { Compute minimum box to fit the sample}
  856. dfScrollIn = 1 shl 5; { Scroll text in until last of text is in view }
  857. dfScrollOut = 1 shl 6; { Scroll text out until last of text is gone (if both set, scroll in then out)}
  858. dfHorizScroll = 1 shl 7; { Scroll text horizontally (otherwise it's vertical)}
  859. dfReverseScroll = 1 shl 8; { vert: scroll down rather than up; horiz: scroll backwards (justfication dependent)}
  860. dfContinuousScroll = 1 shl 9; { new samples cause previous samples to scroll out }
  861. dfFlowHoriz = 1 shl 10; { horiz scroll text flows in textbox rather than extend to right }
  862. dfContinuousKaraoke = 1 shl 11; { ignore begin offset, hilite everything up to the end offset(karaoke)}
  863. dfDropShadow = 1 shl 12; { display text with a drop shadow }
  864. dfAntiAlias = 1 shl 13; { attempt to display text anti aliased}
  865. dfKeyedText = 1 shl 14; { key the text over background}
  866. dfInverseHilite = 1 shl 15; { Use inverse hiliting rather than using hilite color}
  867. dfTextColorHilite = 1 shl 16; { changes text color in place of hiliting. }
  868. const
  869. searchTextDontGoToFoundTime = 1 shl 16;
  870. searchTextDontHiliteFoundText = 1 shl 17;
  871. searchTextOneTrackOnly = 1 shl 18;
  872. searchTextEnabledTracksOnly = 1 shl 19;
  873. {use these with the text property routines}
  874. const
  875. { set property parameter / get property parameter}
  876. kTextTextHandle = 1; { Handle / preallocated Handle}
  877. kTextTextPtr = 2; { Pointer}
  878. kTextTEStyle = 3; { TextStyle * / TextStyle *}
  879. kTextSelection = 4; { long [2] / long [2]}
  880. kTextBackColor = 5; { RGBColor * / RGBColor *}
  881. kTextForeColor = 6; { RGBColor * / RGBColor *}
  882. kTextFace = 7; { long / long *}
  883. kTextFont = 8; { long / long *}
  884. kTextSize = 9; { long / long *}
  885. kTextAlignment = 10; { short * / short *}
  886. kTextHilite = 11; { hiliteRecord * / hiliteRecord *}
  887. kTextDropShadow = 12; { dropShadowRecord * / dropShadowRecord *}
  888. kTextDisplayFlags = 13; { long / long *}
  889. kTextScroll = 14; { TimeValue * / TimeValue *}
  890. kTextRelativeScroll = 15; { Point *}
  891. kTextHyperTextFace = 16; { hyperTextSetFace * / hyperTextSetFace *}
  892. kTextHyperTextColor = 17; { hyperTextSetColor * / hyperTextSetColor *}
  893. kTextKeyEntry = 18; { short}
  894. kTextMouseDown = 19; { Point *}
  895. kTextTextBox = 20; { Rect * / Rect *}
  896. kTextEditState = 21; { short / short *}
  897. kTextLength = 22; { / long *}
  898. const
  899. k3DMediaRendererEntry = FourCharCode('rend');
  900. k3DMediaRendererName = FourCharCode('name');
  901. k3DMediaRendererCode = FourCharCode('rcod');
  902. { progress messages }
  903. const
  904. movieProgressOpen = 0;
  905. movieProgressUpdatePercent = 1;
  906. movieProgressClose = 2;
  907. { progress operations }
  908. const
  909. progressOpFlatten = 1;
  910. progressOpInsertTrackSegment = 2;
  911. progressOpInsertMovieSegment = 3;
  912. progressOpPaste = 4;
  913. progressOpAddMovieSelection = 5;
  914. progressOpCopy = 6;
  915. progressOpCut = 7;
  916. progressOpLoadMovieIntoRam = 8;
  917. progressOpLoadTrackIntoRam = 9;
  918. progressOpLoadMediaIntoRam = 10;
  919. progressOpImportMovie = 11;
  920. progressOpExportMovie = 12;
  921. const
  922. mediaQualityDraft = $0000;
  923. mediaQualityNormal = $0040;
  924. mediaQualityBetter = $0080;
  925. mediaQualityBest = $00C0;
  926. {****
  927. Interactive Sprites Support
  928. ****}
  929. { QTEventRecord flags}
  930. const
  931. kQTEventPayloadIsQTList = 1 shl 0;
  932. type
  933. QTEventRecord = record
  934. version: SIGNEDLONG;
  935. eventType: OSType;
  936. where: Point;
  937. flags: SIGNEDLONG;
  938. payloadRefcon: SIGNEDLONG; { from here down only present if version >= 2}
  939. param1: SIGNEDLONG;
  940. param2: SIGNEDLONG;
  941. param3: SIGNEDLONG;
  942. end;
  943. QTEventRecordPtr = ^QTEventRecord;
  944. type
  945. QTAtomSpec = record
  946. container: QTAtomContainer;
  947. atom: QTAtom;
  948. end;
  949. QTAtomSpecPtr = ^QTAtomSpec;
  950. type
  951. ResolvedQTEventSpec = record
  952. actionAtom: QTAtomSpec;
  953. targetTrack: Track;
  954. targetRefCon: SIGNEDLONG;
  955. end;
  956. ResolvedQTEventSpecPtr = ^ResolvedQTEventSpec;
  957. { action constants }
  958. const
  959. kActionMovieSetVolume = 1024; { (short movieVolume) }
  960. kActionMovieSetRate = 1025; { (Fixed rate) }
  961. kActionMovieSetLoopingFlags = 1026; { (long loopingFlags) }
  962. kActionMovieGoToTime = 1027; { (TimeValue time) }
  963. kActionMovieGoToTimeByName = 1028; { (Str255 timeName) }
  964. kActionMovieGoToBeginning = 1029; { no params }
  965. kActionMovieGoToEnd = 1030; { no params }
  966. kActionMovieStepForward = 1031; { no params }
  967. kActionMovieStepBackward = 1032; { no params }
  968. kActionMovieSetSelection = 1033; { (TimeValue startTime, TimeValue endTime) }
  969. kActionMovieSetSelectionByName = 1034; { (Str255 startTimeName, Str255 endTimeName) }
  970. kActionMoviePlaySelection = 1035; { (Boolean selectionOnly) }
  971. kActionMovieSetLanguage = 1036; { (long language) }
  972. kActionMovieChanged = 1037; { no params }
  973. kActionMovieRestartAtTime = 1038; { (TimeValue startTime, Fixed rate) }
  974. kActionMovieGotoNextChapter = 1039; { no params }
  975. kActionMovieGotoPreviousChapter = 1040; { no params }
  976. kActionMovieGotoFirstChapter = 1041; { no params }
  977. kActionMovieGotoLastChapter = 1042; { no params }
  978. kActionMovieGotoChapterByIndex = 1043; { ( short index ) }
  979. kActionMovieSetScale = 1044; { (Fixed xScale, Fixed yScale) }
  980. kActionTrackSetVolume = 2048; { (short volume) }
  981. kActionTrackSetBalance = 2049; { (short balance) }
  982. kActionTrackSetEnabled = 2050; { (Boolean enabled) }
  983. kActionTrackSetMatrix = 2051; { (MatrixRecord matrix) }
  984. kActionTrackSetLayer = 2052; { (short layer) }
  985. kActionTrackSetClip = 2053; { (RgnHandle clip) }
  986. kActionTrackSetCursor = 2054; { (QTATomID cursorID) }
  987. kActionTrackSetGraphicsMode = 2055; { (ModifierTrackGraphicsModeRecord graphicsMode) }
  988. kActionTrackSetIdleFrequency = 2056; { (long frequency) }
  989. kActionTrackSetBassTreble = 2057; { (short base, short treble) }
  990. kActionSpriteSetMatrix = 3072; { (MatrixRecord matrix) }
  991. kActionSpriteSetImageIndex = 3073; { (short imageIndex) }
  992. kActionSpriteSetVisible = 3074; { (short visible) }
  993. kActionSpriteSetLayer = 3075; { (short layer) }
  994. kActionSpriteSetGraphicsMode = 3076; { (ModifierTrackGraphicsModeRecord graphicsMode) }
  995. kActionSpritePassMouseToCodec = 3078; { no params }
  996. kActionSpriteClickOnCodec = 3079; { Point localLoc }
  997. kActionSpriteTranslate = 3080; { (Fixed x, Fixed y, Boolean isAbsolute) }
  998. kActionSpriteScale = 3081; { (Fixed xScale, Fixed yScale) }
  999. kActionSpriteRotate = 3082; { (Fixed degrees) }
  1000. kActionSpriteStretch = 3083; { (Fixed p1x, Fixed p1y, Fixed p2x, Fixed p2y, Fixed p3x, Fixed p3y, Fixed p4x, Fixed p4y) }
  1001. kActionSpriteSetCanBeHitTested = 3094; { (short canBeHitTested) }
  1002. kActionQTVRSetPanAngle = 4096; { (float panAngle) }
  1003. kActionQTVRSetTiltAngle = 4097; { (float tiltAngle) }
  1004. kActionQTVRSetFieldOfView = 4098; { (float fieldOfView) }
  1005. kActionQTVRShowDefaultView = 4099; { no params }
  1006. kActionQTVRGoToNodeID = 4100; { (UInt32 nodeID) }
  1007. kActionQTVREnableHotSpot = 4101; { long ID, Boolean enable }
  1008. kActionQTVRShowHotSpots = 4102; { Boolean show }
  1009. kActionQTVRTranslateObject = 4103; { float xMove, float yMove }
  1010. kActionQTVRSetViewState = 4109; { long viewStateType, short state }
  1011. kActionMusicPlayNote = 5120; { (long sampleDescIndex, long partNumber, long delay, long pitch, long velocity, long duration) }
  1012. kActionMusicSetController = 5121; { (long sampleDescIndex, long partNumber, long delay, long controller, long value) }
  1013. kActionCase = 6144; { [(CaseStatementActionAtoms)] }
  1014. kActionWhile = 6145; { [(WhileStatementActionAtoms)] }
  1015. kActionGoToURL = 6146; { (C string urlLink) }
  1016. kActionSendQTEventToSprite = 6147; { ([(SpriteTargetAtoms)], QTEventRecord theEvent) }
  1017. kActionDebugStr = 6148; { (Str255 theString) }
  1018. kActionPushCurrentTime = 6149; { no params }
  1019. kActionPushCurrentTimeWithLabel = 6150; { (Str255 theLabel) }
  1020. kActionPopAndGotoTopTime = 6151; { no params }
  1021. kActionPopAndGotoLabeledTime = 6152; { (Str255 theLabel) }
  1022. kActionStatusString = 6153; { (C string theString, long stringTypeFlags) }
  1023. kActionSendQTEventToTrackObject = 6154; { ([(TrackObjectTargetAtoms)], QTEventRecord theEvent) }
  1024. kActionAddChannelSubscription = 6155; { (Str255 channelName, C string channelsURL, C string channelsPictureURL) }
  1025. kActionRemoveChannelSubscription = 6156; { (C string channelsURL) }
  1026. kActionOpenCustomActionHandler = 6157; { (long handlerID, ComponentDescription handlerDesc) }
  1027. kActionDoScript = 6158; { (long scriptTypeFlags, CString command, CString arguments) }
  1028. kActionDoCompressedActions = 6159; { (compressed QTAtomContainer prefixed with eight bytes: long compressorType, long decompressedSize) }
  1029. kActionSendAppMessage = 6160; { (long appMessageID) }
  1030. kActionLoadComponent = 6161; { (ComponentDescription handlerDesc) }
  1031. kActionSetFocus = 6162; { [(TargetAtoms theObject)] }
  1032. kActionDontPassKeyEvent = 6163; { no params }
  1033. kActionSetRandomSeed = 6164; { long randomSeed }
  1034. kActionSpriteTrackSetVariable = 7168; { (QTAtomID variableID, float value) }
  1035. kActionSpriteTrackNewSprite = 7169; { (QTAtomID spriteID, short imageIndex, MatrixRecord *matrix, short visible, short layer, ModifierTrackGraphicsModeRecord *graphicsMode, QTAtomID actionHandlingSpriteID) }
  1036. kActionSpriteTrackDisposeSprite = 7170; { (QTAtomID spriteID) }
  1037. kActionSpriteTrackSetVariableToString = 7171; { (QTAtomID variableID, C string value) }
  1038. kActionSpriteTrackConcatVariables = 7172; { (QTAtomID firstVariableID, QTAtomID secondVariableID, QTAtomID resultVariableID ) }
  1039. kActionSpriteTrackSetVariableToMovieURL = 7173; { (QTAtomID variableID, < optional: [(MovieTargetAtoms)] > ) }
  1040. kActionSpriteTrackSetVariableToMovieBaseURL = 7174; { (QTAtomID variableID, < optional: [(MovieTargetAtoms)] > ) }
  1041. kActionSpriteTrackSetAllSpritesHitTestingMode = 7181;
  1042. kActionSpriteTrackNewImage = 7182; { (C string imageURL, QTAtomID desiredID) }
  1043. kActionSpriteTrackDisposeImage = 7183; { (short imageIndex) }
  1044. kActionApplicationNumberAndString = 8192; { (long aNumber, Str255 aString ) }
  1045. kActionQD3DNamedObjectTranslateTo = 9216; { (Fixed x, Fixed y, Fixed z ) }
  1046. kActionQD3DNamedObjectScaleTo = 9217; { (Fixed xScale, Fixed yScale, Fixed zScale ) }
  1047. kActionQD3DNamedObjectRotateTo = 9218; { (Fixed xDegrees, Fixed yDegrees, Fixed zDegrees ) }
  1048. kActionFlashTrackSetPan = 10240; { (short xPercent, short yPercent ) }
  1049. kActionFlashTrackSetZoom = 10241; { (short zoomFactor ) }
  1050. kActionFlashTrackSetZoomRect = 10242; { (long left, long top, long right, long bottom ) }
  1051. kActionFlashTrackGotoFrameNumber = 10243; { (long frameNumber ) }
  1052. kActionFlashTrackGotoFrameLabel = 10244; { (C string frameLabel ) }
  1053. kActionFlashTrackSetFlashVariable = 10245; { (C string path, C string name, C string value, Boolean updateFocus) }
  1054. kActionFlashTrackDoButtonActions = 10246; { (C string path, long buttonID, long transition) }
  1055. kActionMovieTrackAddChildMovie = 11264; { (QTAtomID childMovieID, C string childMovieURL) }
  1056. kActionMovieTrackLoadChildMovie = 11265; { (QTAtomID childMovieID) }
  1057. kActionMovieTrackLoadChildMovieWithQTListParams = 11266; { (QTAtomID childMovieID, C string qtlistXML) }
  1058. kActionTextTrackPasteText = 12288; { (C string theText, long startSelection, long endSelection ) }
  1059. kActionTextTrackSetTextBox = 12291; { (short left, short top, short right, short bottom) }
  1060. kActionTextTrackSetTextStyle = 12292; { (Handle textStyle) }
  1061. kActionTextTrackSetSelection = 12293; { (long startSelection, long endSelection ) }
  1062. kActionTextTrackSetBackgroundColor = 12294; { (ModifierTrackGraphicsModeRecord backgroundColor ) }
  1063. kActionTextTrackSetForegroundColor = 12295; { (ModifierTrackGraphicsModeRecord foregroundColor ) }
  1064. kActionTextTrackSetFace = 12296; { (long fontFace ) }
  1065. kActionTextTrackSetFont = 12297; { (long fontID ) }
  1066. kActionTextTrackSetSize = 12298; { (long fontSize ) }
  1067. kActionTextTrackSetAlignment = 12299; { (short alignment ) }
  1068. kActionTextTrackSetHilite = 12300; { (long startHighlight, long endHighlight, ModifierTrackGraphicsModeRecord highlightColor ) }
  1069. kActionTextTrackSetDropShadow = 12301; { (Point dropShadow, short transparency ) }
  1070. kActionTextTrackSetDisplayFlags = 12302; { (long flags ) }
  1071. kActionTextTrackSetScroll = 12303; { (long delay ) }
  1072. kActionTextTrackRelativeScroll = 12304; { (short deltaX, short deltaY ) }
  1073. kActionTextTrackFindText = 12305; { (long flags, Str255 theText, ModifierTrackGraphicsModeRecord highlightColor ) }
  1074. kActionTextTrackSetHyperTextFace = 12306; { (short index, long fontFace ) }
  1075. kActionTextTrackSetHyperTextColor = 12307; { (short index, ModifierTrackGraphicsModeRecord highlightColor ) }
  1076. kActionTextTrackKeyEntry = 12308; { (short character ) }
  1077. kActionTextTrackMouseDown = 12309; { no params }
  1078. kActionTextTrackSetEditable = 12310; { (short editState) }
  1079. kActionListAddElement = 13312; { (C string parentPath, long atIndex, C string newElementName) }
  1080. kActionListRemoveElements = 13313; { (C string parentPath, long startIndex, long endIndex) }
  1081. kActionListSetElementValue = 13314; { (C string elementPath, C string valueString) }
  1082. kActionListPasteFromXML = 13315; { (C string xml, C string targetParentPath, long startIndex) }
  1083. kActionListSetMatchingFromXML = 13316; { (C string xml, C string targetParentPath) }
  1084. kActionListSetFromURL = 13317; { (C string url, C string targetParentPath ) }
  1085. kActionListExchangeLists = 13318; { (C string url, C string parentPath) }
  1086. kActionListServerQuery = 13319; { (C string url, C string keyValuePairs, long flags, C string parentPath) }
  1087. kActionListAddAttribute = 13320; { (C string elementPath, long atIndex, C string newAttributeName) }
  1088. kActionListRemoveAttributes = 13321; { (C string elementPath, long startIndex, long endIndex) }
  1089. kActionListSetAttributeValue = 13322; { (C string elementPath, C string attributeName, C string valueString) }
  1090. const
  1091. kOperandExpression = 1;
  1092. kOperandConstant = 2;
  1093. kOperandSubscribedToChannel = 3; { C string channelsURL }
  1094. kOperandUniqueCustomActionHandlerID = 4;
  1095. kOperandCustomActionHandlerIDIsOpen = 5; { long ID }
  1096. kOperandConnectionSpeed = 6;
  1097. kOperandGMTDay = 7;
  1098. kOperandGMTMonth = 8;
  1099. kOperandGMTYear = 9;
  1100. kOperandGMTHours = 10;
  1101. kOperandGMTMinutes = 11;
  1102. kOperandGMTSeconds = 12;
  1103. kOperandLocalDay = 13;
  1104. kOperandLocalMonth = 14;
  1105. kOperandLocalYear = 15;
  1106. kOperandLocalHours = 16;
  1107. kOperandLocalMinutes = 17;
  1108. kOperandLocalSeconds = 18;
  1109. kOperandRegisteredForQuickTimePro = 19;
  1110. kOperandPlatformRunningOn = 20;
  1111. kOperandQuickTimeVersion = 21;
  1112. kOperandComponentVersion = 22; { C string type, C string subType, C string manufacturer }
  1113. kOperandOriginalHandlerRefcon = 23;
  1114. kOperandTicks = 24;
  1115. kOperandMaxLoadedTimeInMovie = 25;
  1116. kOperandEventParameter = 26; { short index }
  1117. kOperandFreeMemory = 27;
  1118. kOperandNetworkStatus = 28;
  1119. kOperandQuickTimeVersionRegistered = 29; { long version }
  1120. kOperandSystemVersion = 30;
  1121. kOperandMovieVolume = 1024;
  1122. kOperandMovieRate = 1025;
  1123. kOperandMovieIsLooping = 1026;
  1124. kOperandMovieLoopIsPalindrome = 1027;
  1125. kOperandMovieTime = 1028;
  1126. kOperandMovieDuration = 1029;
  1127. kOperandMovieTimeScale = 1030;
  1128. kOperandMovieWidth = 1031;
  1129. kOperandMovieHeight = 1032;
  1130. kOperandMovieLoadState = 1033;
  1131. kOperandMovieTrackCount = 1034;
  1132. kOperandMovieIsActive = 1035;
  1133. kOperandMovieName = 1036;
  1134. kOperandMovieID = 1037;
  1135. kOperandMovieChapterCount = 1038;
  1136. kOperandMovieChapterIndex = 1039;
  1137. kOperandMovieChapterName = 1040;
  1138. kOperandMovieChapterNameByIndex = 1041; { ( short index ) }
  1139. kOperandMovieChapterIndexByName = 1042; { (c string name) }
  1140. kOperandMovieAnnotation = 1043; { (c string requested, long flags) }
  1141. kOperandMovieConnectionFlags = 1044;
  1142. kOperandMovieConnectionString = 1045;
  1143. kOperandTrackVolume = 2048;
  1144. kOperandTrackBalance = 2049;
  1145. kOperandTrackEnabled = 2050;
  1146. kOperandTrackLayer = 2051;
  1147. kOperandTrackWidth = 2052;
  1148. kOperandTrackHeight = 2053;
  1149. kOperandTrackDuration = 2054;
  1150. kOperandTrackName = 2055;
  1151. kOperandTrackID = 2056;
  1152. kOperandTrackIdleFrequency = 2057;
  1153. kOperandTrackBass = 2058;
  1154. kOperandTrackTreble = 2059;
  1155. kOperandSpriteBoundsLeft = 3072;
  1156. kOperandSpriteBoundsTop = 3073;
  1157. kOperandSpriteBoundsRight = 3074;
  1158. kOperandSpriteBoundsBottom = 3075;
  1159. kOperandSpriteImageIndex = 3076;
  1160. kOperandSpriteVisible = 3077;
  1161. kOperandSpriteLayer = 3078;
  1162. kOperandSpriteTrackVariable = 3079; { [QTAtomID variableID] }
  1163. kOperandSpriteTrackNumSprites = 3080;
  1164. kOperandSpriteTrackNumImages = 3081;
  1165. kOperandSpriteID = 3082;
  1166. kOperandSpriteIndex = 3083;
  1167. kOperandSpriteFirstCornerX = 3084;
  1168. kOperandSpriteFirstCornerY = 3085;
  1169. kOperandSpriteSecondCornerX = 3086;
  1170. kOperandSpriteSecondCornerY = 3087;
  1171. kOperandSpriteThirdCornerX = 3088;
  1172. kOperandSpriteThirdCornerY = 3089;
  1173. kOperandSpriteFourthCornerX = 3090;
  1174. kOperandSpriteFourthCornerY = 3091;
  1175. kOperandSpriteImageRegistrationPointX = 3092;
  1176. kOperandSpriteImageRegistrationPointY = 3093;
  1177. kOperandSpriteTrackSpriteIDAtPoint = 3094; { short x, short y }
  1178. kOperandSpriteName = 3095;
  1179. kOperandSpriteCanBeHitTested = 3105; { short }
  1180. kOperandSpriteTrackAllSpritesHitTestingMode = 3106;
  1181. kOperandSpriteTrackImageIDByIndex = 3107; { short imageIndex }
  1182. kOperandSpriteTrackImageIndexByID = 3108; { QTAtomID }
  1183. kOperandQTVRPanAngle = 4096;
  1184. kOperandQTVRTiltAngle = 4097;
  1185. kOperandQTVRFieldOf…