The Definitive Guide to Advanced 3D in Java
Clear and comprehensive, providing a full-spectrum view of a well-designed, emerging technology.
Over the last decade, a large number of software development libraries dealing with 3D animation, and real-time to photo realistic rendering have been introduced, ranging from the cross-platform OpenGL to the Windows-specific Direct3D API. The folks at Sun recognized a need for high-performance 3D on the Java platform and brought together a stellar team of experts, architects and programmers to work through their open specification process and define the next generation 3D engine API. The results are already impressive, accounting not only for typical flat-screen rendering but for multiple-pane devices, such as VR glasses, along with a flexible model that gives the programmer access to three levels of rendering control.
The Java 3D API Specification was released by Addison-Wesley as part of the Sun Java series. Its authors are Henry Sowizral, chief architected of the 3D API; Kevin Rushforth, co-architect with more than 15 years of graphic hardware and software experience with 3D technology and Virtual Reality (VR); and Michael Deering, co-architect with a background in 3D accelerator development and VR technology. This book is the definitive guide, required reading for any developer who intends to work in 3 dimensions on the Java platform.
What never ceases to amaze me is how the specifications originating from Sun are typically lucid, to the point, clear and eminently readable. Its easy for this kind of material to be very stiff. After all we’re taking about a specification, which has to be sufficiently exact and complete to implement correctly. At the time of this writing, the Java 3D API is in the later stages of Beta testing, but it hasn’t deviated significantly from the specification (although there are some minor changes, they are not pronounced enough to make any of this material irrelevant).
The specification is divided into 13 chapters and 6 appendices. The Introduction in Chapter 1 provides a clear overview of the objectives, paradigm and organization of the API, pointing out the need for a flexible, high-performance solution that runs on virtually any Java-enabled device. Chapters 2 to 7 jump right into the actual API classes. The collection is comprehensive but uncluttered and the explanation is logically divided among the scene graph (which collects all the objects and behaviors in a scene), the group and leaf objects, the nodes and the mathematical part of the API.
The exploration continues through chapters 8 to 13. Chapter 8 explores the view model and the way developers control the view location, orientation, projection policies, and so on. This is where the Canvas3D and Screen3D classes are explored, views you can basically drop into any Java application as easily as a Panel or Canvas window. Chapter 9 explores behaviors and interpolators which provide a wide array of capabilities for changing rotation, color, scale and position over time, and let you plot complex paths for any group of object in the scene graph.
Chapter 10 covers input devices and object picking and Chapter 11 audio devices. Audio is an important part of this API, enabling a more submergent experience for VR users when objects can have sounds associated with them, influenced by the proximity and movement of the viewer. Chapter 12 covers the muti-tiered rendering model and how programmers can control the level of immediacy and interaction they engage in, trading control for performance in specific areas. Chapter 13 explores the immediate mode rendering option in greater detail.
Finally, the appendices take a close look at the mathematics behind the 3D API, explore available geometry compression techniques, take a closer look at the view model, list exceptions, and equations for fog, lighting, sound and texture effects. Appendix F explores the mapping of VRML (Virtual Reality Modeling Language) onto the Java 3D API, pointing out that it is an easy matter for developers to work with this standard language when defining 3D models. If you’re uncertain about some of the terminology, the writers has enough foresight to provide a Glossary to keep us out of trouble.
While a specification is meant to be detailed and complete, this is a surprisingly readable book. The explanations are clear enough to build a good vision of how this technology can be applied, what the options are, how comprehensive the range of classes and methods to chose from are, and the whole thing leaves the reader with a lasting sense that this API was not only well though out, but was clearly designed for an emerging future with a growing number of rendering devices and flexible options for the programmer. If you plan to do any 3D work in Java, the time to read about it here.