Computer Graphics Introduction Graphics: All aspects of the production of pictures (images) using a computer Application areas: Display of Information Design Simulation User Interfaces Basic Graphics System: Processor Memory Frame buffer Output device Input device Pixels & Frame buffer Raster: array of pixels Pixel: picture element Frame Buffer: memory area used to store pixel/raster data VRAM: Video random access memory DRAM: Dynamic random access memory Depth: number of bits of information stored for each pixel Resolution: number of pixels in frame buffer (on screen) Processor: - may be main CPU or special purpose processor on video card - performs Rasterization (Scan Conversion) conversion of geometric primitives (line, circle, etc) to pixel values in frame buffer Output devices CRT: Cathode Ray Tube refresh flicker triads shadow mask LCD: Liquid crystal display Refresh RASTER SCAN Output devices CRT: Cathode Ray Tube refresh flicker triads shadow mask TRIAD SHADOW MASK Vector Displays graphics primitives are made of sequences of strokes or vectors Raster Displays display graphics primitives in a refresh buffer in terms of the primitive’s component pixels Vector Displays graphics primitives are made of sequences of strokes or vectors IDEAL LINE DRAWING RANDOM SCAN Raster Displays display graphics primitives in a refresh buffer in terms of the primitive’s component pixels IDEAL LINE DRAWING RASTER SCAN Raster Displays display graphics primitives in a refresh buffer in terms of the primitive’s component pixels IDEAL LINE DRAWING FILLED RASTER SCAN IMAGES: Point: a location on an object (or in space) relative to a Reference Coordinate System Cartesian Coordinates: 3D space, perpendicular axes, equal distance measures on each axis Object: specified by an organized grouping of Metric and topological information Vertices: corner points. They carry metric information - (X,Y,Z) coordinates. Vertex listing: list of vertex identifiers forming polygon boundary (usually a list of indices into the vertex array) Image creation: NOTE: An image is generally a 2D projection or rendering of a 3D scene What must be specified (known) 1 1 -- What What are are the the objects objects in in the the scene scene 2 objects in in the 2 -- Where Where are are the the objects the scene scene 3 3 -- Where Where is is the the viewer viewer 4 4 -- Where Where is is the the viewer viewer looking looking 5 - What type of projection is assumed 6 - Where are the lights 7 - .... Light: visible part of the electromagnetic spectrum Wavelength: identifies light color (350-780 nanometers) Light sources characterized by location, nature (point or area), color, brightness (Simplifying assumption for now -- assume monochromatic (single color) lights) Ray tracing is a method for following the path of a photon from its origin at a light source, bouncing off the various surfaces it strikes, before it strikes the image plane. The Pinhole Camera Simple model for a camera. Film Pinhole The pinhole allows only a small number of light rays to pass through from the scene to the film. Computer graphics model of pinhole camera Eye The pinhole is replaced by the eye and the film plane moves out in front of the pinhole (eye).