3d viewing illustrated. what you see depends on your position in the real world, what you see...
TRANSCRIPT
![Page 1: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/1.jpg)
3D VIEWING ILLUSTRATED
![Page 2: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/2.jpg)
WHAT YOU SEE DEPENDS ON YOUR POSITION
• In the real world, what you see depends on where you stand, the direction you look, how you tilt your head, and so on.
![Page 3: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/3.jpg)
3D VERSUS 2D
• In 3D, the y-axis typically points up instead of down. • Negative coordinates, which are rarely used in
2D, are quite common in 3D. • Because of this, the origin is at the center of
space as opposed to the top-left corner as in 2D
![Page 4: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/4.jpg)
MAJOR DIFFERENCES BETWEEN 2D AND 3D
![Page 5: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/5.jpg)
RIGHT HANDED COORDINATE SYSTEM
![Page 6: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/6.jpg)
CAMERA POSITION
• Camera positioned at (5, 5, 5):• Looking at the southeast side
![Page 7: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/7.jpg)
SOUTHWEST SIDE
• Move the camera to position (-5,5,5):• Looking at the southwest side
![Page 8: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/8.jpg)
LOOKDIRECTION
• The lookdirection is a vector that tells the camera where to look.• For the camera below the lookdirection is (-1,-1,-
1):
![Page 9: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/9.jpg)
MOVING THE CAMERA
• Moving the camera does not change the lookdirection:
![Page 10: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/10.jpg)
THE LOOKDIRECTION IS BASED ON A LOOKAT POINT
• Changing the lookdirection:
![Page 11: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/11.jpg)
LOOKAT AND LOKDIRECTION
• The easiest way to determine the lookdirection is specify a lookat point in the scene and subtract the camera position from it:
lookat – camera position• For the above camera position, if the lookat is
(0,0,0), then look direction is:• Lookdirection = (0,0,0) – (-5,5,5) = (5, -5, -5)
![Page 12: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/12.jpg)
SOUTHWEST VIEW
• Given an orthographic camera and the above lookdirection we get the following scene:
![Page 13: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/13.jpg)
THE UP DIRECTION
• The lookdirection is not enough to get the correct view:
![Page 14: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/14.jpg)
UP DIRECTION NOT CHANGED
![Page 15: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/15.jpg)
UP DIRECTION WRONG
![Page 16: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/16.jpg)
CORRECT
![Page 17: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/17.jpg)
CORRECT
![Page 18: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/18.jpg)
TRANSFORM UP DIRECTION
![Page 19: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/19.jpg)
UP DIRECTION ANALOGY
if you're designing a flight simulator, up is the direction perpendicular to the plane's wings, from the plane toward the sky when the plane is on the ground.
![Page 20: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/20.jpg)
DEFAULT CAMERA POSITION
![Page 21: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/21.jpg)
ROTATING THE CAMERA
• We will call rotation around the look vector (or z axis) Roll. • Rotation around the up vector (or y axis) is called
Yaw. • Rotation around the Right vector (x axis) is called
Pitch. • Below is a picture of an aircraft showing roll, pitch
and yaw in terms of the aircraft's local axis. Note: we can use a similar system for our object rotations
![Page 22: 3D VIEWING ILLUSTRATED. WHAT YOU SEE DEPENDS ON YOUR POSITION In the real world, what you see depends on where you stand, the direction you look, how](https://reader035.vdocuments.site/reader035/viewer/2022062516/56649dc75503460f94abb7f0/html5/thumbnails/22.jpg)
ROLL, PITCH AND YAW