QuickTimeVRFormat.pas 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671
  1. {
  2. File: QuickTime/QuickTimeVRFormat.h
  3. Contains: QuickTime VR interfaces
  4. Version: QuickTime 7.7.1
  5. Copyright: © 1997-2012 by Apple Inc., all rights reserved.
  6. Bugs?: For bug reports, consult the following page on
  7. the World Wide Web:
  8. http://bugs.freepascal.org
  9. }
  10. { Pascal Translation Updated: Jonas Maebe, <[email protected]>, October 2009 }
  11. { Pascal Translation Updated: Jonas Maebe, <[email protected]>, October 2012 }
  12. {
  13. Modified for use with Free Pascal
  14. Version 308
  15. Please report any bugs to <[email protected]>
  16. }
  17. {$ifc not defined MACOSALLINCLUDE or not MACOSALLINCLUDE}
  18. {$mode macpas}
  19. {$modeswitch cblocks}
  20. {$packenum 1}
  21. {$macro on}
  22. {$inline on}
  23. {$calling mwpascal}
  24. {$IFNDEF FPC_DOTTEDUNITS}
  25. unit QuickTimeVRFormat;
  26. {$ENDIF FPC_DOTTEDUNITS}
  27. interface
  28. {$setc UNIVERSAL_INTERFACES_VERSION := $0400}
  29. {$setc GAP_INTERFACES_VERSION := $0308}
  30. {$ifc not defined USE_CFSTR_CONSTANT_MACROS}
  31. {$setc USE_CFSTR_CONSTANT_MACROS := TRUE}
  32. {$endc}
  33. {$ifc defined CPUPOWERPC and defined CPUI386}
  34. {$error Conflicting initial definitions for CPUPOWERPC and CPUI386}
  35. {$endc}
  36. {$ifc defined FPC_BIG_ENDIAN and defined FPC_LITTLE_ENDIAN}
  37. {$error Conflicting initial definitions for FPC_BIG_ENDIAN and FPC_LITTLE_ENDIAN}
  38. {$endc}
  39. {$ifc not defined __ppc__ and defined CPUPOWERPC32}
  40. {$setc __ppc__ := 1}
  41. {$elsec}
  42. {$setc __ppc__ := 0}
  43. {$endc}
  44. {$ifc not defined __ppc64__ and defined CPUPOWERPC64}
  45. {$setc __ppc64__ := 1}
  46. {$elsec}
  47. {$setc __ppc64__ := 0}
  48. {$endc}
  49. {$ifc not defined __i386__ and defined CPUI386}
  50. {$setc __i386__ := 1}
  51. {$elsec}
  52. {$setc __i386__ := 0}
  53. {$endc}
  54. {$ifc not defined __x86_64__ and defined CPUX86_64}
  55. {$setc __x86_64__ := 1}
  56. {$elsec}
  57. {$setc __x86_64__ := 0}
  58. {$endc}
  59. {$ifc not defined __arm__ and defined CPUARM}
  60. {$setc __arm__ := 1}
  61. {$elsec}
  62. {$setc __arm__ := 0}
  63. {$endc}
  64. {$ifc not defined __arm64__ and defined CPUAARCH64}
  65. {$setc __arm64__ := 1}
  66. {$elsec}
  67. {$setc __arm64__ := 0}
  68. {$endc}
  69. {$ifc defined cpu64}
  70. {$setc __LP64__ := 1}
  71. {$elsec}
  72. {$setc __LP64__ := 0}
  73. {$endc}
  74. {$ifc defined __ppc__ and __ppc__ and defined __i386__ and __i386__}
  75. {$error Conflicting definitions for __ppc__ and __i386__}
  76. {$endc}
  77. {$ifc defined __ppc__ and __ppc__}
  78. {$setc TARGET_CPU_PPC := TRUE}
  79. {$setc TARGET_CPU_PPC64 := FALSE}
  80. {$setc TARGET_CPU_X86 := FALSE}
  81. {$setc TARGET_CPU_X86_64 := FALSE}
  82. {$setc TARGET_CPU_ARM := FALSE}
  83. {$setc TARGET_CPU_ARM64 := FALSE}
  84. {$setc TARGET_OS_MAC := TRUE}
  85. {$setc TARGET_OS_IPHONE := FALSE}
  86. {$setc TARGET_IPHONE_SIMULATOR := FALSE}
  87. {$setc TARGET_OS_EMBEDDED := FALSE}
  88. {$elifc defined __ppc64__ and __ppc64__}
  89. {$setc TARGET_CPU_PPC := FALSE}
  90. {$setc TARGET_CPU_PPC64 := TRUE}
  91. {$setc TARGET_CPU_X86 := FALSE}
  92. {$setc TARGET_CPU_X86_64 := FALSE}
  93. {$setc TARGET_CPU_ARM := FALSE}
  94. {$setc TARGET_CPU_ARM64 := FALSE}
  95. {$setc TARGET_OS_MAC := TRUE}
  96. {$setc TARGET_OS_IPHONE := FALSE}
  97. {$setc TARGET_IPHONE_SIMULATOR := FALSE}
  98. {$setc TARGET_OS_EMBEDDED := FALSE}
  99. {$elifc defined __i386__ and __i386__}
  100. {$setc TARGET_CPU_PPC := FALSE}
  101. {$setc TARGET_CPU_PPC64 := FALSE}
  102. {$setc TARGET_CPU_X86 := TRUE}
  103. {$setc TARGET_CPU_X86_64 := FALSE}
  104. {$setc TARGET_CPU_ARM := FALSE}
  105. {$setc TARGET_CPU_ARM64 := FALSE}
  106. {$ifc defined iphonesim}
  107. {$setc TARGET_OS_MAC := FALSE}
  108. {$setc TARGET_OS_IPHONE := TRUE}
  109. {$setc TARGET_IPHONE_SIMULATOR := TRUE}
  110. {$elsec}
  111. {$setc TARGET_OS_MAC := TRUE}
  112. {$setc TARGET_OS_IPHONE := FALSE}
  113. {$setc TARGET_IPHONE_SIMULATOR := FALSE}
  114. {$endc}
  115. {$setc TARGET_OS_EMBEDDED := FALSE}
  116. {$elifc defined __x86_64__ and __x86_64__}
  117. {$setc TARGET_CPU_PPC := FALSE}
  118. {$setc TARGET_CPU_PPC64 := FALSE}
  119. {$setc TARGET_CPU_X86 := FALSE}
  120. {$setc TARGET_CPU_X86_64 := TRUE}
  121. {$setc TARGET_CPU_ARM := FALSE}
  122. {$setc TARGET_CPU_ARM64 := FALSE}
  123. {$ifc defined iphonesim}
  124. {$setc TARGET_OS_MAC := FALSE}
  125. {$setc TARGET_OS_IPHONE := TRUE}
  126. {$setc TARGET_IPHONE_SIMULATOR := TRUE}
  127. {$elsec}
  128. {$setc TARGET_OS_MAC := TRUE}
  129. {$setc TARGET_OS_IPHONE := FALSE}
  130. {$setc TARGET_IPHONE_SIMULATOR := FALSE}
  131. {$endc}
  132. {$setc TARGET_OS_EMBEDDED := FALSE}
  133. {$elifc defined __arm__ and __arm__}
  134. {$setc TARGET_CPU_PPC := FALSE}
  135. {$setc TARGET_CPU_PPC64 := FALSE}
  136. {$setc TARGET_CPU_X86 := FALSE}
  137. {$setc TARGET_CPU_X86_64 := FALSE}
  138. {$setc TARGET_CPU_ARM := TRUE}
  139. {$setc TARGET_CPU_ARM64 := FALSE}
  140. {$setc TARGET_OS_MAC := FALSE}
  141. {$setc TARGET_OS_IPHONE := TRUE}
  142. {$setc TARGET_IPHONE_SIMULATOR := FALSE}
  143. {$setc TARGET_OS_EMBEDDED := TRUE}
  144. {$elifc defined __arm64__ and __arm64__}
  145. {$setc TARGET_CPU_PPC := FALSE}
  146. {$setc TARGET_CPU_PPC64 := FALSE}
  147. {$setc TARGET_CPU_X86 := FALSE}
  148. {$setc TARGET_CPU_X86_64 := FALSE}
  149. {$setc TARGET_CPU_ARM := FALSE}
  150. {$setc TARGET_CPU_ARM64 := TRUE}
  151. {$ifc defined ios}
  152. {$setc TARGET_OS_MAC := FALSE}
  153. {$setc TARGET_OS_IPHONE := TRUE}
  154. {$setc TARGET_OS_EMBEDDED := TRUE}
  155. {$elsec}
  156. {$setc TARGET_OS_MAC := TRUE}
  157. {$setc TARGET_OS_IPHONE := FALSE}
  158. {$setc TARGET_OS_EMBEDDED := FALSE}
  159. {$endc}
  160. {$setc TARGET_IPHONE_SIMULATOR := FALSE}
  161. {$elsec}
  162. {$error __ppc__ nor __ppc64__ nor __i386__ nor __x86_64__ nor __arm__ nor __arm64__ is defined.}
  163. {$endc}
  164. {$ifc defined __LP64__ and __LP64__ }
  165. {$setc TARGET_CPU_64 := TRUE}
  166. {$elsec}
  167. {$setc TARGET_CPU_64 := FALSE}
  168. {$endc}
  169. {$ifc defined FPC_BIG_ENDIAN}
  170. {$setc TARGET_RT_BIG_ENDIAN := TRUE}
  171. {$setc TARGET_RT_LITTLE_ENDIAN := FALSE}
  172. {$elifc defined FPC_LITTLE_ENDIAN}
  173. {$setc TARGET_RT_BIG_ENDIAN := FALSE}
  174. {$setc TARGET_RT_LITTLE_ENDIAN := TRUE}
  175. {$elsec}
  176. {$error Neither FPC_BIG_ENDIAN nor FPC_LITTLE_ENDIAN are defined.}
  177. {$endc}
  178. {$setc ACCESSOR_CALLS_ARE_FUNCTIONS := TRUE}
  179. {$setc CALL_NOT_IN_CARBON := FALSE}
  180. {$setc OLDROUTINENAMES := FALSE}
  181. {$setc OPAQUE_TOOLBOX_STRUCTS := TRUE}
  182. {$setc OPAQUE_UPP_TYPES := TRUE}
  183. {$setc OTCARBONAPPLICATION := TRUE}
  184. {$setc OTKERNEL := FALSE}
  185. {$setc PM_USE_SESSION_APIS := TRUE}
  186. {$setc TARGET_API_MAC_CARBON := TRUE}
  187. {$setc TARGET_API_MAC_OS8 := FALSE}
  188. {$setc TARGET_API_MAC_OSX := TRUE}
  189. {$setc TARGET_CARBON := TRUE}
  190. {$setc TARGET_CPU_68K := FALSE}
  191. {$setc TARGET_CPU_MIPS := FALSE}
  192. {$setc TARGET_CPU_SPARC := FALSE}
  193. {$setc TARGET_OS_UNIX := FALSE}
  194. {$setc TARGET_OS_WIN32 := FALSE}
  195. {$setc TARGET_RT_MAC_68881 := FALSE}
  196. {$setc TARGET_RT_MAC_CFM := FALSE}
  197. {$setc TARGET_RT_MAC_MACHO := TRUE}
  198. {$setc TYPED_FUNCTION_POINTERS := TRUE}
  199. {$setc TYPE_BOOL := FALSE}
  200. {$setc TYPE_EXTENDED := FALSE}
  201. {$setc TYPE_LONGLONG := TRUE}
  202. {$IFDEF FPC_DOTTEDUNITS}
  203. uses MacOsApi.MacTypes,MacOsApi.Movies,MacOsApi.QuickTimeVR;
  204. {$ELSE FPC_DOTTEDUNITS}
  205. uses MacTypes,Movies,QuickTimeVR;
  206. {$ENDIF FPC_DOTTEDUNITS}
  207. {$endc} {not MACOSALLINCLUDE}
  208. {$ifc TARGET_OS_MAC}
  209. {$ALIGN MAC68K}
  210. { QuickTime is not available to 64-bit clients }
  211. {$ifc not TARGET_CPU_64}
  212. { File Format Version numbers }
  213. const
  214. kQTVRMajorVersion = 2;
  215. const
  216. kQTVRMinorVersion = 0;
  217. { User data type for the Movie Controller type specifier}
  218. const
  219. kQTControllerType = kQTVRControllerSubType; { Atom & ID of where our}
  220. kQTControllerID = 1; { ...controller name is stored}
  221. { VRWorld atom types}
  222. const
  223. kQTVRWorldHeaderAtomType = FourCharCode('vrsc');
  224. kQTVRImagingParentAtomType = FourCharCode('imgp');
  225. kQTVRPanoImagingAtomType = FourCharCode('impn');
  226. kQTVRObjectImagingAtomType = FourCharCode('imob');
  227. kQTVRNodeParentAtomType = FourCharCode('vrnp');
  228. kQTVRNodeIDAtomType = FourCharCode('vrni');
  229. kQTVRNodeLocationAtomType = FourCharCode('nloc');
  230. kQTVRCursorParentAtomType = FourCharCode('vrcp'); { New with 2.1}
  231. kQTVRCursorAtomType = FourCharCode('CURS'); { New with 2.1}
  232. kQTVRColorCursorAtomType = FourCharCode('crsr'); { New with 2.1}
  233. { NodeInfo atom types}
  234. const
  235. kQTVRNodeHeaderAtomType = FourCharCode('ndhd');
  236. kQTVRHotSpotParentAtomType = FourCharCode('hspa');
  237. kQTVRHotSpotAtomType = FourCharCode('hots');
  238. kQTVRHotSpotInfoAtomType = FourCharCode('hsin');
  239. kQTVRLinkInfoAtomType = FourCharCode('link');
  240. { Miscellaneous atom types}
  241. const
  242. kQTVRStringAtomType = FourCharCode('vrsg');
  243. kQTVRStringEncodingAtomType = FourCharCode('vrse'); { New with 2.1}
  244. kQTVRPanoSampleDataAtomType = FourCharCode('pdat');
  245. kQTVRObjectInfoAtomType = FourCharCode('obji');
  246. kQTVRImageTrackRefAtomType = FourCharCode('imtr'); { Parent is kQTVRObjectInfoAtomType. Required if track ref is not 1 as required by 2.0 format.}
  247. kQTVRHotSpotTrackRefAtomType = FourCharCode('hstr'); { Parent is kQTVRObjectInfoAtomType. Required if track ref is not 1 as required by 2.0 format.}
  248. kQTVRAngleRangeAtomType = FourCharCode('arng');
  249. kQTVRTrackRefArrayAtomType = FourCharCode('tref');
  250. kQTVRPanConstraintAtomType = FourCharCode('pcon');
  251. kQTVRTiltConstraintAtomType = FourCharCode('tcon');
  252. kQTVRFOVConstraintAtomType = FourCharCode('fcon');
  253. kQTVRCubicViewAtomType = FourCharCode('cuvw'); { New with 5.0}
  254. kQTVRCubicFaceDataAtomType = FourCharCode('cufa'); { New with 5.0}
  255. const
  256. kQTVRObjectInfoAtomID = 1;
  257. kQTVRObjectImageTrackRefAtomID = 1; { New with 2.1, it adds a track reference to select between multiple image tracks}
  258. kQTVRObjectHotSpotTrackRefAtomID = 1; { New with 2.1, it adds a track reference to select between multiple hotspot tracks}
  259. { Track reference types}
  260. const
  261. kQTVRImageTrackRefType = FourCharCode('imgt');
  262. kQTVRHotSpotTrackRefType = FourCharCode('hott');
  263. { Old hot spot types}
  264. const
  265. kQTVRHotSpotNavigableType = FourCharCode('navg');
  266. { Valid bits used in QTVRLinkHotSpotAtom}
  267. const
  268. kQTVRValidPan = 1 shl 0;
  269. kQTVRValidTilt = 1 shl 1;
  270. kQTVRValidFOV = 1 shl 2;
  271. kQTVRValidViewCenter = 1 shl 3;
  272. { Values for flags field in QTVRPanoSampleAtom}
  273. const
  274. kQTVRPanoFlagHorizontal = 1 shl 0;
  275. kQTVRPanoFlagLast = 1 shl 31;
  276. { Values for locationFlags field in QTVRNodeLocationAtom}
  277. const
  278. kQTVRSameFile = 0;
  279. {$endc} {not TARGET_CPU_64}
  280. { Header for QTVR track's Sample Description record (vrWorld atom container is appended)}
  281. type
  282. QTVRSampleDescription = record
  283. descSize: UInt32; { total size of the QTVRSampleDescription}
  284. descType: UInt32; { must be 'qtvr'}
  285. reserved1: UInt32; { must be zero}
  286. reserved2: UInt16; { must be zero}
  287. dataRefIndex: UInt16; { must be zero}
  288. data: UInt32; { Will be extended to hold vrWorld QTAtomContainer}
  289. end;
  290. QTVRSampleDescriptionPtr = ^QTVRSampleDescription;
  291. type
  292. QTVRSampleDescriptionHandle = ^QTVRSampleDescriptionPtr;
  293. {$ifc not TARGET_CPU_64}
  294. {
  295. =================================================================================================
  296. Definitions and structures used in the VRWorld QTAtomContainer
  297. -------------------------------------------------------------------------------------------------
  298. }
  299. type
  300. QTVRStringAtom = record
  301. stringUsage: UInt16;
  302. stringLength: UInt16;
  303. theString: packed array [0..3] of UInt8; { field previously named "string" }
  304. end;
  305. QTVRStringAtomPtr = ^QTVRStringAtom;
  306. type
  307. QTVRWorldHeaderAtom = record
  308. majorVersion: UInt16;
  309. minorVersion: UInt16;
  310. nameAtomID: QTAtomID;
  311. defaultNodeID: UInt32;
  312. vrWorldFlags: UInt32;
  313. reserved1: UInt32;
  314. reserved2: UInt32;
  315. end;
  316. QTVRWorldHeaderAtomPtr = ^QTVRWorldHeaderAtom;
  317. { Valid bits used in QTVRPanoImagingAtom}
  318. const
  319. kQTVRValidCorrection = 1 shl 0;
  320. kQTVRValidQuality = 1 shl 1;
  321. kQTVRValidDirectDraw = 1 shl 2;
  322. kQTVRValidFirstExtraProperty = 1 shl 3;
  323. type
  324. QTVRPanoImagingAtom = record
  325. majorVersion: UInt16;
  326. minorVersion: UInt16;
  327. imagingMode: UInt32;
  328. imagingValidFlags: UInt32;
  329. correction: UInt32;
  330. quality: UInt32;
  331. directDraw: UInt32;
  332. imagingProperties: array [0..5] of UInt32; { for future properties}
  333. reserved1: UInt32;
  334. reserved2: UInt32;
  335. end;
  336. QTVRPanoImagingAtomPtr = ^QTVRPanoImagingAtom;
  337. type
  338. QTVRNodeLocationAtom = record
  339. majorVersion: UInt16;
  340. minorVersion: UInt16;
  341. nodeType: OSType;
  342. locationFlags: UInt32;
  343. locationData: UInt32;
  344. reserved1: UInt32;
  345. reserved2: UInt32;
  346. end;
  347. QTVRNodeLocationAtomPtr = ^QTVRNodeLocationAtom;
  348. {
  349. =================================================================================================
  350. Definitions and structures used in the Nodeinfo QTAtomContainer
  351. -------------------------------------------------------------------------------------------------
  352. }
  353. type
  354. QTVRNodeHeaderAtom = record
  355. majorVersion: UInt16;
  356. minorVersion: UInt16;
  357. nodeType: OSType;
  358. nodeID: QTAtomID;
  359. nameAtomID: QTAtomID;
  360. commentAtomID: QTAtomID;
  361. reserved1: UInt32;
  362. reserved2: UInt32;
  363. end;
  364. QTVRNodeHeaderAtomPtr = ^QTVRNodeHeaderAtom;
  365. type
  366. QTVRAngleRangeAtom = record
  367. minimumAngle: Float32;
  368. maximumAngle: Float32;
  369. end;
  370. QTVRAngleRangeAtomPtr = ^QTVRAngleRangeAtom;
  371. type
  372. QTVRHotSpotInfoAtom = record
  373. majorVersion: UInt16;
  374. minorVersion: UInt16;
  375. hotSpotType: OSType;
  376. nameAtomID: QTAtomID;
  377. commentAtomID: QTAtomID;
  378. cursorID: array [0..2] of SInt32;
  379. { canonical view for this hot spot}
  380. bestPan: Float32;
  381. bestTilt: Float32;
  382. bestFOV: Float32;
  383. bestViewCenter: QTVRFloatPoint;
  384. { Bounding box for this hot spot}
  385. hotSpotRect: Rect;
  386. flags: UInt32;
  387. reserved1: UInt32;
  388. reserved2: UInt32;
  389. end;
  390. QTVRHotSpotInfoAtomPtr = ^QTVRHotSpotInfoAtom;
  391. type
  392. QTVRLinkHotSpotAtom = record
  393. majorVersion: UInt16;
  394. minorVersion: UInt16;
  395. toNodeID: UInt32;
  396. fromValidFlags: UInt32;
  397. fromPan: Float32;
  398. fromTilt: Float32;
  399. fromFOV: Float32;
  400. fromViewCenter: QTVRFloatPoint;
  401. toValidFlags: UInt32;
  402. toPan: Float32;
  403. toTilt: Float32;
  404. toFOV: Float32;
  405. toViewCenter: QTVRFloatPoint;
  406. distance: Float32;
  407. flags: UInt32;
  408. reserved1: UInt32;
  409. reserved2: UInt32;
  410. end;
  411. QTVRLinkHotSpotAtomPtr = ^QTVRLinkHotSpotAtom;
  412. {
  413. =================================================================================================
  414. Definitions and structures used in Panorama and Object tracks
  415. -------------------------------------------------------------------------------------------------
  416. }
  417. type
  418. QTVRPanoSampleAtom = record
  419. majorVersion: UInt16;
  420. minorVersion: UInt16;
  421. imageRefTrackIndex: UInt32; { track reference index of the full res image track}
  422. hotSpotRefTrackIndex: UInt32; { track reference index of the full res hot spot track}
  423. minPan: Float32;
  424. maxPan: Float32;
  425. minTilt: Float32;
  426. maxTilt: Float32;
  427. minFieldOfView: Float32;
  428. maxFieldOfView: Float32;
  429. defaultPan: Float32;
  430. defaultTilt: Float32;
  431. defaultFieldOfView: Float32;
  432. { Info for highest res version of image track}
  433. imageSizeX: UInt32; { pixel width of the panorama (e.g. 768)}
  434. imageSizeY: UInt32; { pixel height of the panorama (e.g. 2496)}
  435. imageNumFramesX: UInt16; { diced frames wide (e.g. 1)}
  436. imageNumFramesY: UInt16; { diced frames high (e.g. 24)}
  437. { Info for highest res version of hotSpot track}
  438. hotSpotSizeX: UInt32; { pixel width of the hot spot panorama (e.g. 768)}
  439. hotSpotSizeY: UInt32; { pixel height of the hot spot panorama (e.g. 2496)}
  440. hotSpotNumFramesX: UInt16; { diced frames wide (e.g. 1)}
  441. hotSpotNumFramesY: UInt16; { diced frames high (e.g. 24)}
  442. flags: UInt32;
  443. panoType: OSType;
  444. reserved2: UInt32;
  445. end;
  446. QTVRPanoSampleAtomPtr = ^QTVRPanoSampleAtom;
  447. {
  448. View atom for cubes (since same fields in QTVRPanoSampleAtom are set to special
  449. values for backwards compatibility and hence are ignored by the cubic engine)
  450. }
  451. type
  452. QTVRCubicViewAtom = record
  453. minPan: Float32;
  454. maxPan: Float32;
  455. minTilt: Float32;
  456. maxTilt: Float32;
  457. minFieldOfView: Float32;
  458. maxFieldOfView: Float32;
  459. defaultPan: Float32;
  460. defaultTilt: Float32;
  461. defaultFieldOfView: Float32;
  462. end;
  463. QTVRCubicViewAtomPtr = ^QTVRCubicViewAtom;
  464. type
  465. QTVRCubicFaceData = record
  466. orientation: array [0..4-1] of Float32; { WXYZ quaternion of absolute orientation}
  467. center: array [0..2-1] of Float32; { Center of image relative to center of projection (default = (0,0)) in normalized units}
  468. aspect: Float32; { aspect>1 => tall pixels; aspect <1 => squat pixels (default = 1)}
  469. skew: Float32; { skew x by y (default = 0)}
  470. end;
  471. QTVRCubicFaceDataPtr = ^QTVRCubicFaceData;
  472. { Special resolution values for the Image Track Reference Atoms. Use only one value per track reference.}
  473. const
  474. kQTVRFullTrackRes = kQTVRFullRes;
  475. kQTVRHalfTrackRes = kQTVRHalfRes;
  476. kQTVRQuarterTrackRes = kQTVRQuarterRes;
  477. kQTVRPreviewTrackRes = $8000;
  478. type
  479. QTVRTrackRefEntryPtr = ^QTVRTrackRefEntry;
  480. QTVRTrackRefEntry = record
  481. trackRefType: UInt32;
  482. trackResolution: UInt16;
  483. trackRefIndex: UInt32;
  484. end;
  485. {
  486. =================================================================================================
  487. Object File format 2.0
  488. -------------------------------------------------------------------------------------------------
  489. }
  490. const
  491. kQTVRObjectAnimateViewFramesOn = 1 shl 0;
  492. kQTVRObjectPalindromeViewFramesOn = 1 shl 1;
  493. kQTVRObjectStartFirstViewFrameOn = 1 shl 2;
  494. kQTVRObjectAnimateViewsOn = 1 shl 3;
  495. kQTVRObjectPalindromeViewsOn = 1 shl 4;
  496. kQTVRObjectSyncViewToFrameRate = 1 shl 5;
  497. kQTVRObjectDontLoopViewFramesOn = 1 shl 6;
  498. kQTVRObjectPlayEveryViewFrameOn = 1 shl 7;
  499. kQTVRObjectStreamingViewsOn = 1 shl 8;
  500. const
  501. kQTVRObjectWrapPanOn = 1 shl 0;
  502. kQTVRObjectWrapTiltOn = 1 shl 1;
  503. kQTVRObjectCanZoomOn = 1 shl 2;
  504. kQTVRObjectReverseHControlOn = 1 shl 3;
  505. kQTVRObjectReverseVControlOn = 1 shl 4;
  506. kQTVRObjectSwapHVControlOn = 1 shl 5;
  507. kQTVRObjectTranslationOn = 1 shl 6;
  508. const
  509. kGrabberScrollerUI = 1; { "Object" }
  510. kOldJoyStickUI = 2; { "1.0 Object as Scene" }
  511. kJoystickUI = 3; { "Object In Scene"}
  512. kGrabberUI = 4; { "Grabber only"}
  513. kAbsoluteUI = 5; { "Absolute pointer"}
  514. type
  515. QTVRObjectSampleAtom = record
  516. majorVersion: UInt16; { kQTVRMajorVersion}
  517. minorVersion: UInt16; { kQTVRMinorVersion}
  518. movieType: UInt16; { ObjectUITypes}
  519. viewStateCount: UInt16; { The number of view states 1 based}
  520. defaultViewState: UInt16; { The default view state number. The number must be 1 to viewStateCount}
  521. mouseDownViewState: UInt16; { The mouse down view state. The number must be 1 to viewStateCount}
  522. viewDuration: UInt32; { The duration of each view including all animation frames in a view}
  523. columns: UInt32; { Number of columns in movie}
  524. rows: UInt32; { Number rows in movie}
  525. mouseMotionScale: Float32; { 180.0 for kStandardObject or kQTVRObjectInScene, actual degrees for kOldNavigableMovieScene.}
  526. minPan: Float32; { Start horizontal pan angle in degrees}
  527. maxPan: Float32; { End horizontal pan angle in degrees}
  528. defaultPan: Float32; { Initial horizontal pan angle in degrees (poster view)}
  529. minTilt: Float32; { Start vertical pan angle in degrees}
  530. maxTilt: Float32; { End vertical pan angle in degrees}
  531. defaultTilt: Float32; { Initial vertical pan angle in degrees (poster view) }
  532. minFieldOfView: Float32; { minimum field of view setting (appears as the maximum zoom effect) must be >= 1}
  533. fieldOfView: Float32; { the field of view range must be >= 1}
  534. defaultFieldOfView: Float32; { must be in minFieldOfView and maxFieldOfView range inclusive}
  535. defaultViewCenterH: Float32;
  536. defaultViewCenterV: Float32;
  537. viewRate: Float32;
  538. frameRate: Float32;
  539. animationSettings: UInt32; { 32 reserved bit fields}
  540. controlSettings: UInt32; { 32 reserved bit fields}
  541. end;
  542. QTVRObjectSampleAtomPtr = ^QTVRObjectSampleAtom;
  543. {
  544. =================================================================================================
  545. QuickTime VR Authoring Components
  546. -------------------------------------------------------------------------------------------------
  547. }
  548. {
  549. ComponentDescription constants for QTVR Export components
  550. (componentType = MovieExportType; componentSubType = MovieFileType)
  551. }
  552. const
  553. kQTVRFlattenerManufacturer = FourCharCode('vrwe'); { aka QTVRFlattenerType}
  554. kQTVRSplitterManufacturer = FourCharCode('vrsp');
  555. kQTVRObjExporterManufacturer = FourCharCode('vrob');
  556. { QuickTime VR Flattener atom types}
  557. const
  558. kQTVRFlattenerSettingsParentAtomType = FourCharCode('VRWe'); { parent of settings atoms (other than compression)}
  559. kQTVRFlattenerPreviewResAtomType = FourCharCode('PRes'); { preview resolution Int16}
  560. kQTVRFlattenerImportSpecAtomType = FourCharCode('ISpe'); { import file spec FSSpec}
  561. kQTVRFlattenerCreatePreviewAtomType = FourCharCode('Prev'); { Boolean}
  562. kQTVRFlattenerImportPreviewAtomType = FourCharCode('IPre'); { Boolean}
  563. kQTVRFlattenerBlurPreviewAtomType = FourCharCode('Blur'); { Boolean}
  564. { QuickTime VR Splitter atom types}
  565. const
  566. kQTVRSplitterSettingsParentAtomType = FourCharCode('VRSp'); { parent of settings atoms (other than compression)}
  567. kQTVRSplitterGenerateHTMLAtomType = FourCharCode('Ghtm'); { Boolean}
  568. kQTVRSplitterOverwriteFilesAtomType = FourCharCode('Owfi'); { Boolean}
  569. kQTVRSplitterUseFlattenerAtomType = FourCharCode('Usef'); { Boolean}
  570. kQTVRSplitterShowControllerAtomType = FourCharCode('Shco'); { Boolean}
  571. kQTVRSplitterTargetMyselfAtomType = FourCharCode('Tgtm'); { Boolean}
  572. { QuickTime VR Object Exporter atom types}
  573. const
  574. kQTVRObjExporterSettingsBlockSize = FourCharCode('bsiz'); { block size for compression}
  575. kQTVRObjExporterSettingsTargetSize = FourCharCode('tsiz'); { target file size}
  576. {$endc} {not TARGET_CPU_64}
  577. {$endc} {TARGET_OS_MAC}
  578. {$ifc not defined MACOSALLINCLUDE or not MACOSALLINCLUDE}
  579. end.
  580. {$endc} {not MACOSALLINCLUDE}