Lecture 13 - Review of Pitch and Yaw

Announcements:

Review of Pitch and Yaw

Some tidbits that are the most important:

[uxuyuz0vxvyvz0wxwywz00001][100ex010ey001ez0001]

where the first applied matrix is the translation that helps us move the world to the eye coordinates.

You'll need to be able to compute w or u so you can dolly or strafe in P4.

Issues with This

If your gaze vview points in the direction of vup, then the cross product's don't work from Lecture 12 - Pitch and Yaw Camera#^df77d6. Hence, when you look straight up your world will start to spin.

So when you look straight up in a game or otherwise, you can just restrict it. Even if it's something really small like ε=0.0001 or something like that, you can have the impression that it looks like you're looking straight up:

Things for P4

For the lab we just put the eye at the origin. In lab, you'll have θ(0,360) degrees while we have:

85α85

To update α we want to do:

alpha += deltaY * scale;
beta += deltaX * scale;

Make sure for WASD that, not only for updating the eye position, we need to update the look-at point too.