120 likes | 324 Views
Computer Graphics. Chapter 7 Three-Dimensional Viewing. Andreas Savva. Viewing a 3D Scene. When we model and display a tree-dimensional scene, there are many more considerations we must take into account besides just including coordinate values for the third dimension.
E N D
Computer Graphics Chapter 7 Three-Dimensional Viewing Andreas Savva
Viewing a 3D Scene • When we model and display a tree-dimensional scene, there are many more considerations we must take into account besides just including coordinate values for the third dimension. • We first set up a coordinate reference for the viewing, or “camera”, parameters. In this case, surface-rendering procedures are applied so that screen pixels contain only the color patterns for the front surfaces.
Parallel Projection • Generate a view of a solid object by projecting points along parallel lines onto the display plane. • Parallel lines in the world-coordinate scene project into parallel lines on the two-dimensional display plane.
Perspective Projection • View of a three-dimensional scene by projecting points to the display plane along converging paths. This causes objects further from the viewing position to be displayed smaller than objects of the same size that are nearer to the viewing position. • In a perspective projection, parallel lines in a scene that are not parallel to the display plane are projected into converging lines. -> more realistic.
Perspective Projection yd (x,y,z) zd (xc,yc,zc) (0,0,0) xd
Perspective Projection yd (x,y,z) E C (x’,y’,0) A zd (xc,yc,zc) B D (0,0,0) (0,0,z) xd
(x’,y’,z’) Change from World coordinatesto View coordinates (x,y,z) yw zw xw (0,0,0)
(x’,y’,z’) yw xw (0,0,0) zw (x,y,z)
Change from World coordinatesto View coordinates • Camera at (x, y, z)