Chapter 10. QuickTime for Java

When Java first came out, multimedia APIs were relatively weak; scratchy 8-bit sound just doesn't cut it in today's world. Users had rich media on their desktops and laptops, and the Java world quickly scrambled to find a better media API. Unsurprisingly, Java turned to QuickTime, one of the oldest and most sophisticated media APIs available.

Apple has ported QuickTime to Windows and released a set of Java APIs that provide users who would have to write their own native wrappers an easier interface to QuickTime. The APIs are still relatively "C-like," but using them is much easier than writing your own bridge. Applications built using the QuickTime for Java technology are also cross-platform, as long as the only platforms you consider are Windows and Mac OS; Unix users are still out of luck when it comes to QuickTime. The examples in this chapter will run on Windows as well as on Mac OS X.

One of QuickTime's most interesting features is its sheer scope of available functionality. The rich range of supported media types can be overwhelming. This chapter explores the available range of media and demonstrates how to play that media back from within Java applications.