Game Development Reference
In-Depth Information
Figure 7-2. Transforms of a translation (left), a rotation (middle), and a scale (right)
Composing the scene view
To set up a scene, you have to multiply the original coordinates by three separate matrices. These are the
Model, View, and Projection (MVP) matrices.
Model to world transform
The model matrix performs scaling, transformation, and rotation of the coordinates of an object from its
original size, orientation, and position centered at the origin to its final place and size in the world, as
shown in Figure 7-3.
Figure 7-3. Diagram of model coordinates transformed to world coordinates
World to view transform
The view matrix transforms the world view to the “camera view” by zooming, positioning, and rotating the
camera, as shown in Figure 7-4.
 
Search WWH ::




Custom Search