Game Development Reference
In-Depth Information
And, of course, there are those perverse mathematicians who (moti-
vated by the need to save space when writing on a chalkboard?) insist on
assaulting your eyeballs with a slew of Greek letters. You may see any of
the following:
(φ,θ,ψ)
(ψ,θ,φ)
It's all Greek to us
(Ω,i,ω)
(α,β γ).
Of course, these are cosmetic differences. Perhaps more interesting is
that fact that you will often hear these same three words listed in the
opposite order: roll-pitch-yaw. (A quick Google search for “roll pitch yaw”
or “yaw pitch roll” yields plenty of results for both forms, with neither
appearing more predominant.) Considering how the order of rotations is
so critical, are people really that perverse that they choose to list them
in the reverse order? We're not just dwelling on terminology here; the
distinctions in thinking hinted at by the differences in terminology will
actually become useful when we consider how to convert Euler angles to a
rotation matrix. As it turns out, there is a perfectly reasonable explanation
for this “backwards” convention: it's the order in which we actually do the
rotations inside a computer!
The fixed-axis system is very closely related to the Euler angle system.
In an Euler angle system, the rotation occurs about the body axes, which
change after each rotation. Thus, for example, the physical axis for the
bank angle is always the longitudinal body space axis, but in general it is
arbitrarily oriented in upright space. In a fixed-axis system, in contrast,
the axes of rotation are always the fixed, upright axes. But as it turns out,
the fixed-axis system and the Euler angle system are actually equivalent,
provided that we take the rotations in the opposite order.
You should visualize the following example to convince yourself this
is true. Let's say we have a heading (yaw) of h and a pitch of p. (We'll
ignore bank/roll for the moment.) According to the Euler angle convention,
we first do the heading axis and rotate about the vertical axis (the y-
axis) by h. Then we rotate about the object-space lateral axis (the x-
axis) by the angle p. Using a fixed-axis scheme, we arrive at this same
ending orientation by doing the rotations in the opposite order. First, we
do the pitch, rotating about the upright x-axis by p. Then, we perform
the heading rotation, rotating about the upright y-axis by h. Although
we might visualize Euler angles, inside a computer when rotating vectors
from upright space to object space, we actually use a fixed-axis system.
We discuss this in greater detail in Section 8.7.1, when we show how to
convert Euler angles to a rotation matrix. The fixed-axis conventions are
also called extrinsic, the typical Euler angle conventions being referred to
as intrinsic.
Search WWH ::




Custom Search