9.4. Working with QuickTime

The QuickTime framework is built into Mac OS X as the standard way of playing audio and video media. QuickTime has been around a long time and is packed with a lot of different multimedia features. Because QuickTime was originally designed to run on Systems 6 and 7, most of its API uses Carbon data types and calling conventions. For example, on Mac OS X 10.3 Panther, QuickTime commonly uses FSSpec types for referring to files, and it uses Handle types for passing information into and out of movies and other pieces of media.

QuickTime also heavily depends on QuickDraw, the original Mac OS graphics environment. Although Mac OS X's native 2D graphics library is CoreGraphics, QuickDraw is available on Mac OS X as a transition tool for older Macintosh software, including QuickTime and other applications. QuickDraw was designed to perform very well, even on systems without a lot of memory or systems without a lot of CPU power. On the other hand, QuickDraw does not allow for floating point geometric coordinates or native support for transparency in the same way as CoreGraphics.

The newest release of Mac OS X, 10.4 "Tiger," includes a number of architectural changes to QuickTime. First, a new library called QTKit provides a Cocoa interface for working with QuickTime. This allows Cocoa programmers to work with QuickTime without having to know about Carbon or its programming conventions. Second, Apple is transitioning QuickTime onto CoreGraphics as its 2D imaging ...

Get Beginning Mac OS® X Programming now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.