Page 97 - DCAP504_Computer Graphics
P. 97

Computer Graphics





                                        Two-dimensional computer graphics generally do not involve the need for any kind of
                          Did you know?
                                        three-dimensional internal representation of objects or characteristics in the computer.
                                        However, some 2-D software employs 3-D techniques and ideas.

                          This unit discusses the concept of window and viewport  and how they are mapped.  We will also
                          discuss the different stages involved in the graphic pipeline. The panning and zooming concepts will
                          also be discussed in this unit.
                          7.1   Concept of Window and Viewport
                          The region of the scene or an object bounded by a rectangular area is known as a window. A window
                          simply means the frame outlines that define the part of a scene or object that is visible from a particular
                          position at a particular time.
                          The zone of the monitor screen within which a selected object is viewed is known as a viewport. The
                          zone is termed as viewport since it defines the area of the screen which can be viewed. The viewport is
                          generally seen as a rectangular area of the monitor screen in which the selected view is seen.

                                      A window or viewport can be of any shape. However, the analysis for shapes other
                                      than a rectangular area is complex. The overall method of analysis for all shapes will be
                                      similar to the method of analysis followed for rectangles.


                          Window Definitions
                          There are few ways of defining a window. Firstly, a window should be described in any length
                          dimension, both horizontally and vertically.


                                             Feet, meters and miles

                          As a common practice, the corners of  a  window  are defined with reference to the world coordinate
                          origin. The dimensions are set into the computer as (x, y) data and subsequently changes will be applied
                          to the computer model.



































                          90                      LOVELY PROFESSIONAL UNIVERSITY
   92   93   94   95   96   97   98   99   100   101   102