| The Java 3D API Specification |
|
A P P E N D I X F |
|
The Utility Packages |
THIS appendix summarizes the Java 3D utilities packages.
F.1
TheThe Utility Packages com.sun.j3d.*packages provide aids to assist the application programmer in setting up a user environment and getting a Java 3D application up and running as quickly as possible. The utilities packages contain classes that are not part of the formal Java 3D API specification. Since these packages are not part of the API specification, they are subject to change and will evolve over time.The most useful of these packages are
utils.universe- contains the SimpleUniverse class, which defines a minimal user environment that includes all of the necessary objects on the "view" side of the scene graph. See Section F.17, "utils.universe Package," for a description of this package.
utils.geometry- contains geometry utilities, such as stripification, normal generation, tessellation, and primitive construction. See Section F.13, "utils.geometry Package," for a description of this package.
utils.picking- contains the PickIntersection, PickTool, PickCanvas, and PickResult classes, which simplify the construction of picking routines. See Section F.15, "utils.picking Package," for a description of this package.
loaders- contains the Loader and Scene interfaces, which can be used to implement a variety of Java 3D loaders in a standard manner. See Section F.5, "loaders Package," for a description of this package.F.2
The Java 3D utilities packages are all in thePackage Overview com.sun.j3dhierarchy. Table F-1 lists the utilities packages.
F.3
Theaudioengines Package com.sun.j3d.audioenginespackage is useful only to people writing audio device drivers. Java 3D application developers are not expected to use the classes in this package.Table F-2 lists the classes in the
com.sun.j3d.audioenginespackage.
F.4
Theaudioengines.javasound Package com.sun.j3d.audioengines.javasoundpackage contains a single public class that implements a JavaSound-based audio device. Most programs should let the SimpleUniverse (or Viewer) class in theuniversepackage construct the audio device.Table F-3 lists the class in the
com.sun.j3d.audioengines.javasoundpackage.
Table F-3 audioengines.javasound Package
Class Description JavaSoundMixer Extends: AudioEngine3D Defines an audio output device that accesses JavaSound's sound mixer functionality.
F.5
Theloaders Package com.sun.j3d.loaderspackage contains two interfaces, Loader and Scene, that can be used to implement a variety of Java 3D loaders in a standard manner. Base classes that implement these interfaces are also included as a convenience.
F.5.1
Table F-4 lists the interfaces in theInterfaces com.sun.j3d.loaderspackage.
F.5.2
Table F-5 lists the classes in theClasses com.sun.j3d.loaderspackage.
F.5.3
Table F-6 lists the exceptions in theExceptions com.sun.j3d.loaderspackage.
F.6
Theloaders.lw3d Package com.sun.j3d.loaders.lw3dpackage provides a file loader that allows applications to load Lightwave 3D scene files.Table F-7 lists the class in the
com.sun.j3d.loaders.lw3dpackage.
Table F-7 loaders.lw3d Package
Class Description Lw3dLoader Extends: loaders.lw3d.TextfileParser Implements: Loader Allows users to load Lightwave 3D scene files.
F.7
Theloaders.objectfile Package com.sun.j3d.loaders.objectfilepackage provides a file loader that allows applications to load Wavefront object files.Table F-8 lists the class in the
com.sun.j3d.loaders.objectfilepackage.
F.8
Theutils.applet Package com.sun.j3d.utils.appletpackage includes a single class, MainFrame, that enables the creation of Java applets that can also run as standalone applications. The MainFrame class was developed by Jef Poskanzer of Acme Labs <jef@acme.com>.Table F-9 lists the class in the
com.sun.j3d.appletpackage.
F.9
Theutils.behaviors.interpolators Package com.sun.j3d.utils.behaviors.interpolatorspackage provides spline-based interpolators using KCB (Kochanek-Bartels) splines (also known as the TCB or Tension-Continuity-Bias spline). Applications can use these interpolators to implement key-frame animation sequences.Table F-10 lists the classes in the
com.sun.j3d.utils.behaviors.interpolatorspackage.
F.10
Theutils.behaviors.keyboard Package com.sun.j3d.utils.behaviors.keyboardpackage contains classes that take keyboard events and turns them into transform changes that are suitable for use in modifying the ViewPlatform's transformation matrix for navigation.Table F-11 lists the classes in the
com.sun.j3d.utils.behaviors.keyboardpackage.
F.11
Theutils.behaviors.mouse Package com.sun.j3d.utils.behaviors.mousepackage contains classes that use mouse events to modify object or viewing transformations. Subclasses exist to perform rotation, translation, and zoom operations.
F.11.1
Table F-12 lists the interface in theInterfaces com.sun.j3d.utils.behaviors.mousepackage.
F.11.2
Table F-13 lists the classes in theClasses com.sun.j3d.utils.behaviors.mousepackage.
F.12
Theutils.compression Package com.sun.j3d.utils.compressionpackage includes classes for compressing geometry and for reading and writing compressed geometry resource files.Table F-14 lists the classes in the
com.sun.j3d.utils.compressionpackage.
F.13
Theutils.geometry Package com.sun.j3d.utils.geometrypackage contains geometry utilities, such as stripification, normal generation, tessellation (polygon triangulation), and primitive construction. The GeometryInfo class provides a common data storage format for the stripification, normal generation, and tessellation classes.Table F-15 lists the classes in the
com.sun.utils.geometrypackage.
F.14
Theutils.image Package com.sun.j3d.utils.imagepackage contains a single class, TextureLoader, that is used to load a Java 3D texture object from a file. It will automatically scale the image to a power of two and, optionally, compute mipmaps.Table F-16 lists the class in the
com.sun.j3d.utils.imagepackage.
F.15
Theutils.picking Package com.sun.j3d.utils.pickingpackage includes classes that construct a pick shape from a 2D mouse location, initiate a picking operation, and retrieve information about the picked object(s).Table F-17 lists the classes in the
com.sun.j3d.utils.pickingpackage.
F.16
Theutils.picking.behaviors Package com.sun.j3d.utils.picking.behaviorspackage combines picking with mouse-based rotation, translation, and zoom behaviors. Once an object is picked, that object can be manipulated with the mouse.
F.16.1
Table F-18 lists the interface in theInterfaces com.sun.j3d.utils.picking.behaviorspackage.
F.16.2
Table F-19 lists the classes in theClasses com.sun.j3d.utils.picking.behaviorspackage.
F.17
Theutils.universe Package com.sun.j3d.universepackage is useful for setting up a user environment to quickly and easily get a Java 3D program up and running. Specifically, this class creates a Locale, a single ViewingPlatform (with its associated ViewPlatform), and a Viewer object (with its associated View, PhysicalBody, PhysicalEnvironment, and AudioDevice). For many applications, the SimpleUniverse class will provide all of the necessary functionality.Table F-20 lists the classes in the
com.sun.j3d.utils.universepackage.
| The Java 3D API Specification |
|