JMF Explored, With Reusable Class Implementations

Good overview and a practical exploration of the JMF, pragmatic examples, well presented, comprehensive.


The Java Media Framework is one of the major elements in the larger collection of Media APIs defined by Sun. Primarily, it centers on the delivery and rendering of multimedia content, including audio and video streaming and playback. Not many web applications have ventured into this territory yet, but this technology is also well suited to CD-based multimedia solutions and instructional video, likely to be more heavily adopted on the web as more such applications are developed. If your application could benefit from embedded multimedia playback, or if you have an interest in delivering content to users, this book has the goods.

The JMF book is divided into two major sections. Part 1 talks about using the Java Media Framework and Part 2 covers extending the framework, with the implementation of two specialized media solutions. The first implementation delivers newsnet articles in a tickertape-style player. The second example implements a custom protocol and a player that delivers sequenced images in a presentation-style or slide show format. A significant portion of this book centers on building reusable classes that make the price of the book justifiable for anyone interested in implementing custom media solutions.

After the Introduction in Chapter 1, the authors look at why you may want to use this API, the basics of programming with the JMF and what the general architecture looks like. Chapter 5 is the first to explore the internals of JMF solutions, with a look at the Clock-related classes, which keep relative time as a media gets delivered. Chapter 6 covers the Controller API and Chapter 7 looks at the Player API. The Clock, Controller and Player play central roles in the API and become the subject of implementation in the second part of the book, covering extensions and a set of abstractions that make these solutions reusable.

Chapters 8, 9 and 10 wrap up Part 1 with coverage of the player controls, and what it means to synchronize and locate appropriate players for a given medium. Part 2, starts with the chapters that implement the previously mentioned Clock, Controller and Player interfaces. By Chapter 18, we are ready to use these classes to implement a custom Player. Chapters 19 and 20 show how you can create custom controls, including a custom control panel. The final chapter looks at what you need to do to create a custom DataSource, which effectively implements a protocol to deliver your media.

If you plan to do multimedia programming in Java, this book is indispensable. There is a competing book from another publisher which is comparable but this one seemed more accessible to me and provides good, practical examples that demonstrate how you can develop your own custom solutions. While it may seem that this API would only be good for traditional multimedia applications, it may well be applicable to a number of as yet unimagined delivery and rendering mechanisms for data. If you’re interested in the JMF, or in basic data delivery techniques, this book is a good investment.