Download presentation
Presentation is loading. Please wait.
Published byChristiana Wade Modified over 9 years ago
1
Perspective CS418 Computer Graphics John C. Hart
2
Graphics Pipeline Homogeneous Divide Model Coords Model Xform World Coords Viewing Xform Still Clip Coords. Clipping Window Coordinates Window Coordinates Window to Viewport Window to Viewport Coordinates Viewport Coordinates Clip Coords. Viewing Coords Perspective Distortion
3
Graphics Pipeline x y z x y z Model Coords World Coords Viewing Coords Clip Coords Screen Coords
4
Foreshortening Projections squash receding surfaces Andrea Mantegna The Lamentation over the Dead Christ
5
Zollner Illusion
6
Orthographic Projection glOrtho(left,right,bottom,top,near,far) Foreshortens No change in size by depth Projection matrix simply zeros the z- coordinate Ortho Viewing Coordinates Clip Coordinates foreshortening x y x y z View Volume -z (left,top,-near) (right,bottom,-far)
7
Isometric Projection Foreshortens by using z-coord to shear x and y coordinates Used in videogames to place sprites x clip = x view + z view y clip = y view – z view x clip = x view + y view y clip = -x view + y view + 2z view y x z x y
8
Isometric Projection h = x + y v = -x + y + 2z y x z h v h v y x z
9
Perspective Brain depends on shape constancy –Real world objects do not resize –Change in size due to depth Closer objects larger Farther objects smaller © 1997 Illusionworks
10
Ames Distorting Room
11
Hering Illusion
15
A B C
16
A B C
17
Linear Perspective Brain depends on shape constancy –Real world objects do not resize –Change in size due to depth Closer objects larger Farther objects smaller How large, how small? Albrecht Durer woodcut c. 1525, swiped from Marc Levoy’s CS48N notes c. 2007 More Durer, swiped from Fredo Durand’s Art of Depiction ?
18
Linear Perspective screen -z y z view y view d y clip
19
Homogeneous Coordinates Fourth homogeneous coordinate can be any non-zero value To find the point it corresponds to: –multiply all four coordinates by the same value –precisely the value that makes the fourth coordinate one When homogeneous coordinate is zero –Denotes a “point” at infinity –Represents a vector instead of a point –Not affected by translation
20
Linear Perspective screen -z y z view y view d y clip
21
Perspective Distortion x y x y -z (Using a later version of Perspective matrix that preserves depth ordering)
22
Parameter d screen -z y z view y view d y clip d’ y' clip y clip = d y view /(-z view ) y' clip = d’ y view /(-z view ) = (d’/d) y clip Changing parameter d just changes scale of projection Using dUsing d’
23
Parameter d screen -z y z view y view d y clip d’ y' clip screen To change degree of perpective distortion, need to change distance from eye to scene, …by moving scene closer or farther to eye, … along z axis in viewing coordinates
24
Stereo
26
Disparity – differences (in image distance) between similar features images (varies with depth) Stereo methods –Cross eye & wall eye –Anaglyph (colored glasses) –Polarized glasses –Field sequential using alternately blinking lcd’s in the glasses –Autostereograms (barrier strip or lenticular)
27
Rotation v. Shear
28
Sheared Perspective Shear first, then perspective Shear should preserve plane distance f from eyepoint Shear should move eyepoint d units perp to view direction Translate +f in z direction (remember view in -z dir) Shear the point (0,0,f ) to the point (-d,0,f ) (opposite shear) Translate back, by (0,0,-f ) Apply perspective f d ½ f -½ d
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.