Java 3D has a particularly sophisticated model for creating views into the virtual world. These views include both perspective and parallel projections as previously discussed as well as stereoscopic views that will be discussed in Chapter 13.
Java 3D's view model is controlled primarily through the View object. The View object contains all the information necessary to render a 3D scene from a single viewpoint and is attached to a virtual platform, called the ViewPlatform, which in many ways resembles a moveable camera. You should note, however, that the ViewPlatform object extends this traditional concept of a camera platform in several important ways. These additional capabilities have relevance to some advanced applications such as head tracking and the use of specialized input devices and will be expanded on in Chapter 13.
For the most part, you should think of the ViewPlatform as a camera while keeping in mind that advanced features come with it.
After all is said and done, we are left with a fairly large number of coordinate systems and transformations. To begin with, we have the series of transforms that exist within the virtual world (for example, the position of our ViewPlatform, the scaling of our scene objects, the objects' positions, and so on), and we have a lot of coordinates in the real world (for example, the location of our display relative to our head position, that we have yet to even mention).
A fundamental dichotomy exists between coordinates in our 3D world and coordinates in our physical world. We refer to this dichotomy as the virtual/physical dichotomy. The coordinate systems that pertain to virtual and physical worlds are shown in Table 10.5 and 10.6, respectively.
Let's not forget that we are typically writing an application that we hope will run on a variety of platforms and display options. How does Java 3D coordinate these coordinates? You will remember from our discussion of transformation mathematics that a set of homogeneous matrices can be composed into a single matrix. The use of matrix composition in conjunction with the Java 3D view model makes solving the series of transformations much more tenable and frees us to work on content instead of the details of each and every transformation in this long list.
Our primary goal in creating virtual environments is to create a feeling of immersion in the virtual space. To this end, whatever can be done to link physical actions such as head movement or hand manipulation to appropriate changes in the virtual space is beneficial. In order to accomplish this dual existence, we need to determine the location of real objects in virtual space. To understand how Java 3D accomplishes this feat is to understand a special coordinate system called the coexistence coordinate system. The coexistence coordinate system sits in between the virtual world and the real world.
In Chapter 13, we develop a full 3D model of the Java 3D view model including the calibration and placement of trackers, the view plane projection, and view frustrum.