[ This chapter does not appear in the book. ]
In part 1 (chapter 28.3), I described how to play a movie clip inside a Java 3D scene with the help of the Java Media Framework (JMF). The implementation uses the Model-View-Controller design pattern:
In this part, I'll revisit the movie component, re-implementing it using QuickTime for Java (QTJ). QTJ provides an object-based Java layer over the QuickTime API, making it possible to play QuickTime movies, edit and create them, capture audio and video, and perform 2D and 3D animations. QuickTime is available for the Mac and Windows. Details about QTJ's installation, documentation, and examples can be found at http://developer.apple.com/quicktime/qtjava/.
As a consequence of the design pattern, the replacement of JMF by QTJ affects the application very little -- only the movie class, JMFSnapper, departs, replaced by a QuickTime for Java version called QTSnapper.
The picture at the top of the page shows two screenshots of the QTJ version of the Movie3D application: the image on the right is a view of the screen from the back.
A quick glance back at the image on the Web page for the previous chapter (chapter 28.3) shows no obvious differences between the QTJ-based application and the JMF one.
However, a closer comparison of the executing programs reveals two changes: the QTJ movie is slightly more pixelated, and plays more slowly. The pixelation was introduced when the original movie was translated from MPEG to QuickTime's MOV format, and could be remedied with the help of a better conversion tool. The speed issue is more fundamental: it relates to the underlying implementation of QTSnapper.
The important elements of this article are: