Graphics Reference
In-Depth Information
• be able to utilize alpha blending and file texture mapping to increase the
apparent complexity of a graphics scene.
We have learned many technical details of building interactions and designing ge-
ometric manipulations of graphical objects. We need two important areas to make
our applications interesting: intelligence and visual appearance. To be intelligent,
our application must be aware of its state and react meaningfully. To be visually
appealing, the graphical objects in our program should include appropriate real-
life complexity. In general, these two topic areas are highly application-specific
and can involve knowledge and skills from diverse backgrounds (e.g., artificial
intelligence, machine learning, computer arts).
In many interactive applications, one of the most important application states
is the notion of orientation of the graphical objects, the knowledge of which way
is front, left, and right, such that the application can steer or move the objects
accordingly. In this chapter, we present tutorials that apply simple linear algebra
to orient graphical objects and individual nodes in a scene graph. To address vi-
sual appearance, we extend the library to support simple transparency effects (via
blending) and texture mapping. In these ways, we can increase the sophistication
of our applications in intelligence and in appearance.
12.1
Orientation of Objects
One important operation shared by many intelligent applications is to move graph-
ical objects purposefully. For example, moving an object forward or turning an
object towards its left or right. To implement this operation, we first recall that
objects are defined in individual OC spaces. These objects are then placed into
the world coordinate (WC) space with an OC-to-WC transformation matrix. Re-
call that with the UWBGL implementation, the OC-to-WC matrix is stored in the
SceneNode class. In addition, we must remember that user mouse clicks are in
device DC space. When computing orientations to navigate objects, it is impor-
tant to make sure that all geometries and positions are transformed to a common
coordinate space where computations are performed. In the following tutorials,
we choose to work in the WC space.
Tutorial 12.1.
Project Name:
D3D _ OrientationIn2D
Library Support:
UWB_MFC_Lib1
UWB_D3D_Lib12
Tutorial 12.1. Automatic Arm Object Navigation
Goal. Understand how to compute orientation and navigate graphics ob-
jects.
Search WWH ::




Custom Search