home *** CD-ROM | disk | FTP | other *** search
/ Collection of Hack-Phreak Scene Programs / cleanhpvac.zip / cleanhpvac / FAQSYS18.ZIP / FAQS.DAT / QT_FAQ.18 < prev    next >
Internet Message Format  |  1995-12-12  |  19KB

  1. From alex@hal.rhein-main.de Wed Sep 21 23:46:29 1994
  2. Newsgroups: alt.binaries.multimedia,alt.binaries.pictures.d
  3. From: alex@hal.rhein-main.de (Alexander Lehmann)
  4. Subject: QuickTime FAQ (first draft)
  5. Content-Type: text/plain; charset=US-ASCII
  6. Followup-To: poster
  7. Content-Transfer-Encoding: 7bit
  8. X-Newsreader: TIN [version 1.2-(ISO/NeXT) PL2]
  9. Mime-Version: 1.0
  10. Date: Mon, 19 Sep 1994 19:52:17 GMT
  11.  
  12. This is the first draft of my QuickTime FAQ. If you have additional info,
  13. please contribute, there are still some major gaps.
  14.  
  15. (Note that I have set the Followup-To field to poster, which means that all
  16.  followups are mailed to me. If your news software doesn't support that, make
  17.  sure that you post to the appropriate group and maybe send me a copy of your
  18.  post. I might sometimes miss posts in alt.binaries, since I don't receive
  19.  these groups on my home machine)
  20.  
  21.  
  22.                 QuickTime FAQ
  23.  
  24.         ($Id: qt.faq,v 1.8 1994/09/18 23:18:45 alex Exp $)
  25.  
  26. This file attempts to answer some of the questions that appear frequently on
  27. alt.binaries.multimedia and other groups about QuickTime movie files. The FAQ
  28. is more centered on technical problems and not the QuickTime file format.
  29.  
  30.  
  31. 0. Meta
  32. 0.1 Copyright
  33. 0.2 How to get this document?
  34. 0.3 Notation, Abbreviation, etc.
  35. 0.4 Mirror sites
  36. 0.5 Additions
  37. 0.6 Contributors
  38.  
  39. 1. General
  40. 1.1 What is QuickTime?
  41. 1.2 Where to get documentation about the QuickTime file format?
  42.  
  43. 2. QuickTime software
  44. 2.1 Macintosh
  45. 2.2 PC/MS Windows
  46. 2.2.1 Sample ftp session
  47. 2.3 unix/X11
  48.  
  49. 3. Macintosh file formats
  50. 3.1 QuickTime
  51. 3.2 BinHex
  52. 3.3 MacBinary
  53. 3.4 Segmented files
  54. 3.5 Stuffit
  55. 3.6 Compact Pro
  56.  
  57. 4. Decoder/Convertor software
  58. 4.1 Macintosh
  59. 4.2 PC/DOS
  60. 4.3 unix
  61.  
  62. 5. Exchanging QuickTime files between Mac and other platforms
  63.  
  64. 6. Where to get QuickTime movies.
  65.  
  66.  
  67. 0. Meta
  68.  
  69. 0.1 Copyright
  70.  
  71. This file is copyright 1994 by Alexander Lehmann. This file may be copied and
  72. redistributed in whole or excerpts for any purpose. The author disclaims any
  73. responsibility about information contained in this file. You're on your own.
  74.  
  75. 0.2 How to get this document?
  76.  
  77. As long as this posting is not approved by news.answers, the file will not be
  78. available from any archive. The file will be posted regularly and is available
  79. >from the author by email.
  80.  
  81. 0.3 Notation, Abbreviation, etc.
  82.  
  83. Archive locations in this file use the URL notation, which is used in
  84. WorldWideWeb.
  85.  
  86. ftp://site.edu/pub/foo/bar would be the anonymous ftp archive at site.edu in
  87. the directory /pub/foo/bar.
  88.  
  89. Note that if a filename contains a space or other `unsual' character, it is
  90. encoded as 2digit hex number escaped with %, e.g. "File Name" -> File%20Name.
  91. If you access such a file with a terminal based ftp client, the name has to be
  92. enclosed in quotes. (see: sample ftp session)
  93.  
  94. Unless otherwise mentioned, all values are stored in big endian form.
  95.  
  96. 0.4 Mirror sites
  97.  
  98. Some of the FTP archives listed in this file have mirror sites, which might
  99. be nearer to you. If you use a mirror site instead of the root sites, this
  100. has a couple of advantages. The connection is probably faster, you take some
  101. load of the probably much more used server, and some archives have access
  102. restriction, which might be more relaxed with mirror sites.
  103. The easiest way for finding mirror sites is using archie to seach for the
  104. directory in which the file is contained or you can search for the filename.
  105.  
  106. The following sites have many mirror sites:
  107.  
  108. ftp://oak.oakland.edu/pub/msdos (also known as SimTel), e.g.
  109. ftp://ftp.informatik.rwth-aachen.de/simtel
  110.  
  111. ftp://sumex-aim.stanford.edu/info-mac (not all dirs are mirrored)
  112.  
  113. 0.5 Additions
  114.  
  115. If you have any additions or corrections for this file, please mail it to
  116. alex@hal.rhein-main.de. Please do not mail large files without prior
  117. notification, since this address receives mail over a telephone link, which
  118. costs money.
  119.  
  120. 0.6 Contributors
  121.  
  122. This file draws from a number of sources:
  123.  
  124. - articles in alt.binaries.multimedia and alt.binaries.pictures.d
  125. - the macutil source code
  126. - especially the following people:
  127.  
  128. Wayne Brissette <wayneb@apple.com>
  129.  
  130.  
  131. 1. General
  132. 1.1 What is QuickTime?
  133.  
  134. QuickTime offers several tools for adding video, animation, sound, and
  135. other time-based data to applications.  QuickTime also ensures that
  136. developers can create code and data for it now, and not have to scrap the
  137. work when QuickTime takes advantage of new technology later.
  138.  
  139. Apple engineers designed QuickTime to meet the Macintosh computer future
  140. needs.  In particular, the Component Manager enables your program to choose
  141. needed services in an implementation-independent way.  For example, you can
  142. write a QuickTime program to use the best image compression to which it has
  143. access.  Today it can get the job done with one of Apple's software-only
  144. compression components.  Later, you can to put in a third-party hardware-
  145. compression card, and the program will be able to make use of it, even
  146. though the program was written before the compression card was designed.
  147.  
  148. QuickTime is more than just a file format for video, it is more of a
  149. technology. QuickTime 2.0 for the Macintosh (and soon for Windows), allows
  150. you to have Video, Sound, Timebase code, Text Tracks, Midi music Tracks all
  151. in one file. QuickTime 2.0 also supports multiple Codecs, including MPEG.
  152. However, QuickTime 2.0's implementation of MPEG does require an actual MPEG
  153. board. It is not done through software decompression.
  154.  
  155. QuickTime is available for the Macintosh, MS-Windows, SGI, FM-TOWNS (Japan).
  156.  
  157. 1.2 Where to get documentation about the QuickTime file format?
  158.  
  159. Apple made the specification of the QuickTime movie file format public. The
  160. format is published in the Inside Macintosh series, and Apple is also
  161. working closely with developers in the hope that the QuickTime movie format
  162. will become an industrywide standard for time-based data for the Macintosh
  163. and other computer platforms. The Inside Macintosh books are available at
  164. most book stores. The format is also available as part of the QuickTime
  165. Developer's Kit from APDA. There are two kits, one for the Macintosh, and
  166. one for Microsoft Windows.
  167.  
  168.  
  169. 2. QuickTime software
  170. 2.1 Macintosh
  171.  
  172. QuickTime is available as a system extension for Mac and is shipped with the
  173. current OS version (System7) [correct?]. The file is available as
  174. ftp://ftp.support.apple.com/pub/Apple%20SW%20Updates/Macintosh/Supplemental%20System%20Software/QuickTime%20(1.6.2).hqx
  175.  
  176. 2.2 PC/MS-Windows
  177.  
  178. QuickTime for Windows is available as commercial product from Apple. The
  179. program is also included in a couple of CD-ROM games that use QuickTime to
  180. play their animations (e.g. Critical Path, Myst etc.). The QuickTime player
  181. is not redistributable due to copyright restrictions. The program is
  182. available as
  183. ftp://ftp.support.apple.com/pub/Apple%20SW%20Updates/Macintosh/Supplemental%20System%20Software/QuickTime for Windows (1.1.1).hqx
  184. This file is a hqx'ed file that contains a self-extracting DiskDoubler archive
  185. containing two disk images. This file is not extractable on non-Mac computers,
  186. since the version of DiskDoubler is not supported by non-Mac software [info,
  187. anyone?]. You will either need a Mac or a Mac emulator to execute the sfx
  188. archive.
  189.  
  190. After decoding the archive, you get two disk images that either can be
  191. written to disk (3 1/2 HD)
  192.  
  193. - Mac using DiskCopy
  194.  
  195. To install and use Apple DiskCopy 4.2, follow these steps:
  196.  
  197. 1) Copy the DiskCopy 4.2 folder to your hard drive.
  198.  
  199. 2) Open the DiskCopy 4.2 folder and double-click the DiskCopy application
  200.    icon.
  201.  
  202. 3) The title screen appears; click the mouse to continue.
  203.  
  204. 4) The main screen appears; click the Load Image File... button.  (As
  205.    an alternative, from the File menu, you can select Load Disk Image or
  206.    press Command-L.)  A file selection dialog box appears.
  207.  
  208. 5) Choose the image file you want to copy to floppy disk.
  209.  
  210. 6) Click the Open button. A message appears: "Reading the master disk
  211.    image into memory..." After the image is loaded into memory, the Make A
  212.    Copy button is highlighted.
  213.  
  214. 7) Click the Make A Copy button and a prompt appears: "Please insert a
  215.    disk to COPY ONTO..."
  216.  
  217. 8) Insert a floppy disk (formatted or unformatted) into the main floppy
  218.    drive. This message appears: "Now copying and verifying a disk..."
  219.  
  220.    If there is already data on the disk, a beep sounds and a dialog box
  221.    appears.  If it's okay to write over the disk, click the Duplicate
  222.    button. Otherwise, click the Eject button.  If you eject the disk, the
  223.    main screen reappears.  Click the Make A Copy button again and insert a
  224.    different disk.
  225.  
  226.    When the image file has been transferred to the floppy disk, the disk
  227.    automatically ejects.
  228.  
  229. 9) For each image file you want to put on floppy disk, repeat steps
  230.    4-8. When you are finished, click the Quit button.  (You also can
  231.    select Quit from the File menu or press Command-Q.)
  232.  
  233.  
  234. Hints and Help
  235. --------------
  236. - To launch Apple DiskCopy 4.2 and load the image file into memory at
  237.   the same time, double-click the image file icon.
  238.  
  239. - PC using the following C program (BorlandC):
  240.  
  241. /* NOTE: this program doesn't have any safety precautions for */
  242. /*       overwriting disks */
  243.  
  244. #include <stdio.h>
  245. #include <stdlib.h>
  246. #include <dos.h>
  247.  
  248. /* #define DRIVE 0 /* A */
  249. #define DRIVE 1 /* B */
  250.  
  251. char buffer[36*512];
  252.  
  253. int main(int argc, char *argv[])
  254. {
  255.   FILE *file;
  256.   int i;
  257.  
  258.   if(argc!=2) {
  259.     fprintf(stderr, "usage: hd3write imagefile\n");
  260.     exit(1);
  261.   }
  262.  
  263.   if((file=fopen(argv[1],"rb"))==NULL) {
  264.     perror(argv[1]);
  265.     exit(1);
  266.   }
  267.   if(fread(buffer, 1, 84, file)!=84) {    /* skip header */
  268.     perror("fread");
  269.     exit(1);
  270.   }
  271.  
  272.   for(i=0;i<80;i++) {
  273.     if(fread(buffer, 1, 512*36, file)!=512*36) {
  274.       perror("fread");
  275.       exit(1);
  276.     }
  277.     if(abswrite(DRIVE, 36, 36*i, buffer)) {
  278.       perror("abswrite");
  279.       exit(1);
  280.     }
  281.   }
  282.   fclose(file);
  283.   printf("Disk written successfully...\n");
  284.   return 0;
  285. }
  286.  
  287. - unix using dd. skip the first 84 bytes and write the file directly to the
  288. disks.
  289.  
  290. Due to the copyright restriction of Apple, it is not allowed to redistribute
  291. the program, neither as hqx nor as decoded file.
  292.  
  293. Maybe the program is archived on some sites, but I will not mention sites,
  294. since this might cause legal trouble (for the site operators). Try archie.
  295.  
  296. 2.2.1 Sample ftp session: (using a unix ftp client)
  297.  
  298. ~/tmp/ % ftp ftp.support.apple.com
  299. Connected to ftp.support.apple.com.
  300. (welcome message)
  301. 220 ftp.support.apple.com FTP server (Version wu-2.1c(1) Tue Mar 29 16:39:51 PST 1994) ready.
  302. Name (ftp.support.apple.com:alexlehm): ftp
  303. 331 Guest login ok, send your complete e-mail address as password.
  304. Password: user@system.firm.com (use your address here)
  305. (another welcome message)
  306. 230 Guest login ok, access restrictions apply.
  307. ftp> cd "pub/Apple SW Updates/Macintosh/Supplemental System Software"
  308. 250 CWD command successful.
  309. ftp> get "QuickTime for Windows (1.1.1).hqx" qtw111.hqx
  310. 200 PORT command successful.
  311. 150 Opening BINARY mode data connection for QuickTime for Windows (1.1.1).hqx (2238138 bytes).
  312. 226 Transfer complete.
  313. 2238138 bytes received in ss.ss seconds (k.kk Kbytes/s)
  314. ftp> bye
  315. 221 Goodbye.
  316.  
  317. Be sure to also read the License Agreement in /pub/Apple SW Updates.
  318.  
  319.  
  320.  
  321. 2.3 unix/X11
  322.  
  323. A program for playing QuickTime movies, including sound on some platforms
  324. under unix/X11 is called xanim, available at
  325. ftp://ftp.shell.portal.com/pub/podlipec/xanim*.tar.gz.
  326. This program is updated very frequently at this site. A maybe more stable
  327. older version is available from the X11R5 contrib mirrors.
  328.  
  329.  
  330. 3. Macintosh file formats
  331.  
  332. First of all, Macintosch files usually consist of two files, a resource fork
  333. and a data fork.
  334.  
  335. 3.1 QuickTime
  336.  
  337. A QuickTime movie can be in two forms, unflattened or flattened. An
  338. unflattened file has part of the data necessary for displaying the movie
  339. stored in the data fork, which means that the file is not playable when the
  340. resource fork is removed (e.g. on QuickTime for Windows or when transfering
  341. via ftp). A flattened movie has no necessary data in the resource fork,
  342. which means that the file can be played when only the data fork is available.
  343.  
  344. The two variations can be distinguished by the first 4 bytes in the file:
  345.  
  346. Unflattened file:
  347. 00000000: 00 00 00 00 6d 64 61 74    ....mdat
  348.  
  349. Flattened file:
  350. 00000000: hh hh hh hh 6d 64 61 74    !"$%mdat
  351.  
  352. (hhhhhhhh big-endian hex number slighly less that the filesize)
  353.  
  354.  
  355. QuickTime movies can also contain references to other files (in addition
  356. to the data in the resource fork), which are not supported by e.g. Windows.
  357. This means that even if the file header indicates the movie as flat, it
  358. might still be unusable on non-Mac systems (or even on Macs, if the files
  359. pointed to are missing or the movie references itself and is renamed).
  360. Most QT software has options to save files for non-Mac playback, which will
  361. put all data into one file. This is also referred to flattening.
  362.  
  363. 3.2 BinHex (hqx)
  364.  
  365. The BinHex format encodes data and resource fork of a file in a 7bit ASCII
  366. format (like uuencode). The file includes a CRC, allowing transmission
  367. errorchecking.
  368.  
  369. A hqx'ed file starts with something like
  370.  
  371. (This file must be converted with BinHex 4.0)
  372.  
  373. The data lines are usually 65 chars long and the first line starts with a
  374. colon.
  375.  
  376. 3.3 MacBinary
  377.  
  378. MacBinary files combine data and resource fork in a single file for binary
  379. trasmission. Several MacBinary file can be concatenated to form a MacBinary
  380. stream.
  381.  
  382. A MacBinary file starts with a 128 bytes header, which includes the filename,
  383. the creator and type of the file, file date, etc. The data fork starts at
  384. offset 128 and the resource fork after the data fork. Both data and resource
  385. fork are padded to a multiple of 128 bytes.
  386.  
  387. The header starts with a zero byte, then the length of the filename (1 byte)
  388. and the filename. The file type and creator appear at offset 65 (0x41). The
  389. length of data and resource fork are at offset 83 (0x53) and 87 (0x57).
  390.  
  391. Example:
  392.  
  393. 00000000: 00 0a 48 61 6b 75 6e 61:2e 73 69 74 00 00 00 00 |@JHakuna.sit@@@@|
  394. 00000010: 00 00 00 00 00 00 00 00:00 00 00 00 00 00 00 00 |@@@@@@@@@@@@@@@@|
  395. 00000020: 00 00 00 00 00 00 00 00:00 00 00 00 00 00 00 00 |@@@@@@@@@@@@@@@@|
  396. 00000030: 00 00 00 00 00 00 00 00:00 00 00 00 00 00 00 00 |@@@@@@@@@@@@@@@@|
  397. 00000040: 00 53 49 54 44 53 49 54:21 00 00 00 00 00 00 00 |@SITDSIT!@@@@@@@|
  398. 00000050: 00 00 00 00 1f 14 b4 00:00 00 00 aa 2f df fa aa |@@@@_T.@@@@./...|
  399. 00000060: 2f e0 25 00 00 00 00 00:00 00 00 00 00 00 00 00 |/.%@@@@@@@@@@@@@|
  400. 00000070: 00 00 00 00 00 00 00 00:00 00 81 81 78 4b 00 00 |@@@@@@@@@@..xK@@|
  401. 00000080: 53 49 54 21 00 01 00 1f:14 b4 72 4c 61 75 02 fc |SIT!@A@_T.rLauB.|
  402.  
  403. Filename Hakuna.sit (10 chars), file type StuffIT Deluxe, creator StuffIT!.
  404. Data fork is 2036916 bytes, resource fork is empty. The data fork starts at
  405. offset 0x80 with the archive data.
  406.  
  407. 3.4 Segmented files
  408.  
  409. Each part of a segmented file starts with a 100 byte header.
  410. The part number is at offset 3 (byte), the length of the name and the name
  411. at offset 4, the file type and create at offset 68, the length of resource
  412. and data fork at offset 86 and 90. The resource fork and data fork are stored
  413. after each other without padding and each part contains the 100 byte header.
  414.  
  415. 3.5 Stuffit
  416.  
  417. A StuffIt file can either be a regular archive or be self-extracting. The
  418. data fork starts with magic "SIT!".
  419.  
  420. A regular archive has type SIT! (StuffIT!) or SITD (StuffIT Deluxe) and
  421. creator SIT!. A self-extracting archive has type APPL and creator aust.
  422. The data forks starts with SIT!.
  423.  
  424. 3.6 Compact Pro
  425.  
  426. A Compact Pro archive can be regular and self-extracting. A regular archive
  427. has type PACT and creator CPCT. A self-extracting achive has type APPL and
  428. creator EXTR. The data fork starts with 0x0101.
  429.  
  430. A segemented Compact Pro archive, the parts start with 0x0101, 0x0102,
  431. etc.
  432.  
  433.  
  434. 4. Decoder/Converter software
  435. 4.1 Macintosh
  436.  
  437. Macintosh decoders are available from
  438. ftp://sumex-aim.stanford.edu/info-mac/cmp
  439. ftp://mac.archive.umich.edu/mac/util/compression
  440.  
  441. UnStuff, Compact Pro, FileTyper, UULite, etc.
  442.  
  443. 4.2 PC/DOS
  444.  
  445. DOS programs for Mac files are available from
  446. ftp://oak.oakland.edu/pub/msdos/mac.
  447.  
  448. binhex13.zip: en/decodes BinHex 4.0 (HQX) files. Extracts only data fork,
  449.               not useful for unflattened files.
  450. macb10.zip: add/remove MacBinary headers, doesn't separate data/resouce fork,
  451.             not useful for unflattened files.
  452. unpakit.zip: extracts packed (.pit) files. (Probably no longer used)
  453. unsit30.zip: extracts .sit archives. Can extract data and resource fork
  454.              separately. Doesn't support all compression types.
  455. unstufit.zip: extracts .sit archives. [Maybe I'm doing something wrong, but
  456.               this one didn't work with the sample sits I had]
  457. xbin23.zip: extracts HQX files. extracts data and resource fork.
  458.  
  459. There is also a free unstuff program from Aladdin (the company that sells
  460. StuffIt), but I don't have an archive site for this.
  461.  
  462. 4.3 unix
  463.  
  464. A collection of Mac conversion programs is called macutil, which is available
  465. >from ftp://sol.cs.ruu.nl/pub/UNIX/macutil2.0b3.tar.gz [fixme] or
  466. ftp://sumex-aim.stanford.edu/info-mac/unix/macutil-20b1.shar
  467.  
  468. A precompiled binary of this program is also available in the Linux
  469. distribution.
  470.  
  471.  
  472. 5. Exchanging QuickTime files between Mac and other platforms
  473.  
  474. When creating a QuickTime movie, you can select a format suitable for
  475. playing on non-Mac systems, which will create a flat movie.
  476. If a movie is unflat, it can be fixed with qtflat (on DOS), if both data
  477. and resource fork are available.
  478.  
  479. ftp://ftp.rahul.net/pub/hkok/msdos/viewer/qtflat11.zip
  480.  
  481. A C program for this is also available
  482. ftp://ftp.shell.portal.com/pub/podlipec/flatten.c.Z
  483.  
  484.  
  485. If you want to distribute a QuickTime movie (e.g. via news), you should
  486. try to observe the following:
  487.  
  488. - distribute the file in flattened form only or use MacBinary or StuffIt to
  489.   include the resource fork.
  490. - don't use StuffIt with compression methods not supported by macutil.
  491.   (e.g. type 0d, probably a StuffItDeluxe method)
  492. - if you ship the file in a non-Mac format (e.g. zip), be sure to include the
  493.   necessary filetype and creator so that Mac users can fix these entries.
  494.  
  495.  
  496. 6. Where to get QuickTime movies
  497.  
  498. First of all, news:alt.binaries.multimedia, if your site carries this group.
  499.  
  500. ftp://sumex-aim.stanford.edu/info-mac/grf/qt (usually not mirrored)
  501.  
  502. ftp://mac.archive.umich.edu:/mac/graphics/quicktime (also contains some
  503. QuickTime utilities)
  504.  
  505. http://www.portal.com/~podlipec/home.html  contains a list of pointers to
  506. various movie sites, including some with QuickTimes.
  507.  
  508. gopher://csc.ucs.uwplatt.edu/1d-1%3a1163%3aQuicktime
  509.  
  510. This site contains a couple of movies, including one called 1984, which is
  511. rather large (>12MB), as a segmented StuffIt archive.
  512.  
  513. [I have tried to get this file using a unix gopher client, but haven't been
  514. able to decode the file yet. If I figure out how to do this, the procedure
  515. will be here.]
  516.  
  517.  
  518. -- 
  519. Alexander Lehmann,                               |  "On the Internet,
  520. alex@hal.rhein-main.de  (plain, MIME, NeXT)      |   nobody knows
  521. alexlehm@iti.informatik.th-darmstadt.de (plain)  |   you're a dog."
  522.  
  523.