|PREV PACKAGE NEXT PACKAGE||FRAMES NO FRAMES|
|Graphic||The base interface for all graphic entities and capabilities that Gumbo uses in a graphic system neutral way.|
|GraphicFactory||A factory interface that creates graphic objects of a common and vital nature.|
|GraphicPresence||A graphic resource with a presence, which the user can sense (sight, sound, touch).|
|GraphicResource||An "abstract" base interface for graphic entities backed by system resources (such as shapes, sounds, pickers, colliders), and which may require disposal of those resources.|
|DefaultGraphicFactory||The default graphic factory, which makes no use of the native graphic system.|
|GlobalGraphicFactory||Provides a common point of access for the graphic factory used by the client and system.|
|GraphicSystem||Constants and utilities that provide system specific information, including that of the operating operating system and the native graphic system.|
|GraphicUtils||Constants and utilities that are commonly used by Graphic implementations.|
Provides interfaces, services, and utilities that support application development independent of the implementing graphics technology, dimensionality, and precision.
Technology independence is achieved through the
use of common data classes, primarily interfaces, defined in and
under this package, which are broad in scope and general purpose in nature.
By relying on interfaces to define Gumbo graphic services and capabilities,
Gumbo graphic implementations do require inheritance from Gumbo base classes.
Dimensional independence and simplicity (at the expense of performance,
although slight) is achieved by defining the graphic classes for use with
all spatial dimensions up to 3D, and by using the
for all data parameters. Unused dimension values are simply set to a
null operation value (zero for position, one for scale, etc.), and
integer arithmetic is handled by rounding.
javax.vecmath, AWT, Swing, and various personal libraries developed for ray-tracing and collision detection.
javax.vecmathand the AWT and Swing packages, the classes here are specifically designed for graphics independence and to allow the option of immutability (see below), which helps to minimize the creation of small objects.
gumbo.graphic.space, the right-handed system is preferred, with the origin at the center of the reference space (center of the world, view, display, screen, etc.). In general, virtual spaces (world, view) can remain unitless, but physical spaces (display, screen) are inherently pixelated, with physical (metric) dimensions.
impl???(for implementation), and are declared
protected. This allows sub-classes to easily hook into the base class to impose constraints, but it also exposes the base class to potential harm. Great care must be exercised in overriding such implementation methods to assure that the super class method is called, and any constraints on the subclass also apply to the base class methods. Higher level data classes do not use explicit implementation methods, for simplicity, but do note wh which methods are master mutators and accessors.
Constructors require special attention since they may or may not require that the constraints of the subclass be imposed on the initial state of a new object. Unless otherwise stated, constructors should use local mutators to initialize state, which assures that all constraints of the class are imposed on the class and any subclasses. For special situations, such as initializing an immutable subclass, implementation initializers allow direct initialization of the super class state without interference from overridden mutators.Note that a distinction is made between full and partial state mutators and accessors. This distinction is an important one if a constraint applies to the whole state rather than its individual state elements. For example, a normalized vector class would apply the normalization constraint on the whole state, and reject any attempt to set partial state. A point class that limits the extent of its value, however, could apply the constraint on an element-by-element basis.
All other mutators and accessors in the data classes are declared
if other methods in the data class use them. This allows the data
class to conveniently use its own methods while preventing subclasses
from inadvertently breaking the base class by casually overriding them.
In the future, as the need arises, data classes can be refactored
to only use their implementation methods, which would allow the
declarations to be removed.
An immutable view of a data object is created by extending the class as
a wrapper with all
impl??? mutator methods throwing an
and all accessor methods calling through to the target (wrapped) object..
|PREV PACKAGE NEXT PACKAGE||FRAMES NO FRAMES|