You are on page 1of 23

Nazeer Hussain University

Faculty of Engineering Practices and Sciences


Department of Computer Science
COMPUTER GRAPHICS
Prepared by:- Engr.Hermain
LECTURE 1 Fayyaz
Glossary of Computer Graphics Terminology
2D: Two Dimensional. Flat, may refer to bitmap or flat vector graphics (see below.)
3D: Three Dimensional. A representation of objects or images with width, height, and depth.
Aliasing: “stair-stepping” effect created when edges of objects in a 2D images aren’t softened.
Anti-aliasing: Using intermediate shades and colors of pixels to soften aliasing effects on graphics.
Axis (Plural Axes): The main directions--left/right, up/down, close/far. Usually called X, Y, and Z.
Bitmap: Graphics where colors are laid out in a grid pattern, usually used for screen display. A bitmap image.
Bump Map: A shaded image that gives a renderer information about how to shade a 3D object to simulate
surface roughness or deformation.
Contrast: amount of variation in shade and color that allow visual distinction between near objects.
Coordinates: The specific location of something within the graphics area.
Deformation: A change to an object’s shape, size, angle, or position. Usually a change in shape.
Edge: Lines between points in a 3D object’s mesh.
Face: The polygon formed between vertexes and edges in a mesh.
Mesh: The “wire frame” that defines the shape of a 3D object.
Fiber: a “hair” or similar linear, flexible 3D object with behavior programming controlling its shape and position.
Geometry: The overall shape of a 3D object, or the shape of a particular part of its mesh.
Graphics: computer images, or more generally, images whether on the computer or not.
Hiding: Removing some items from display to allow others to be seen more easily.
Mask: A way of marking parts of an object or image to prevent them from being edited.
NURB: A vertex used as a control for the shape of a calculated curve.
OBJ: a mesh in Lightwave .obj file format. (popular format for exchanging 3D meshes between programs.)
Ortho, Orthogonal: Representation of objects on screen without perspective.
Perspective: A simulation of diminishing size with distance when representing 3D objects on the computer.
Pixel: “Picture Element”, a single dot drawn on the screen.
Quad: A face with four sides.
Render: Create a 2D image of a scene of 3D objects.
Rotation: Changing the angle of an object.
Scaling: Changing the size of a graphics object.
Snap: Computer inferring the location to connect something to based on how near the pointer is to that item or
point in its coordinate space. Used to make up for inaccuracy in positioning the pointer, or computer
calculations of position.
Solid Geometry: a means of building up 3D objects out of basic 3D shapes by adding and subtracting them
from each other, as if through physical mechanical processes like welding, machining, casting, etc.
Texture: Information about how a 3D object interacts with light--reflections, rooughness, etc. Also, can refer to
color information applied to a 3D object, e.g. a UV Map.
Translation: Moving an object, usually without changing its size or angle.
Tri, Triangle: A face with 3 sides.
U-V or U-V Map: A 2D image “wrapped” on to a 3D object.
Vector: A single line that is stored with a position relative to other items, a relative size, and an angle that it’s at.
Vector Graphics: Images defined by lines that have a relative size and a set angle, which can be scaled larger
or smaller.
Vertex (plural Vertices): A point in a 3D object. Connects to edges, forms the corner of a face.
DEFINITION OF COMPUTER GRAPHICS
Computer Graphics is principally concerned with the generation of images, with wide ranging
applications from entertainment to scientific visualization.

In other words, we can say that

Computer Graphics is a rendering tool for the generation and manipulation of images. Thus, by using a
computer as a rendering tool for the generation and manipulation of images is called computer graphics.

Computer graphics is an art of drawing pictures on computer screens with the help of programming. It
involves computations, creation, and manipulation of data. Graphics is a vast field that encompasses almost
any graphical aspect like special effects, simulation and training, games, medical imagery, animations and
much more.

“Computer Graphics refers to any sketch, drawing, special artwork or other material generated with the
help of computer to pictorially depict an object or a process or convey information, as a supplement to
or instead of written descriptions”.
 It relies on an internal model of the scene, that is, a
mathematical representation suitable for
 graphical computations.
 The model describes the 3D shapes, layout, projections to
compute a 2D image from a given viewpoint and rendering which
involves projecting the objects (perspective),handling visibility
(which parts of objects are hidden) and computing their
appearance and lighting interactions and materials of the scene.
Types of Graphics
There are 2 types of Graphics:
◦ Raster Graphics – defined by pixel (picture element)
◦ Vector Graphics – defined by lines
Raster Graphics
Raster graphics or Bitmap image is a dot matrix data structure that represents a generally
rectangular grid of pixels (points of color), viewable via a monitor, paper, or other display
medium. Raster images are stored in image files with varying formats.
A bitmap is a rectangular grid of pixels, with each pixel's color being specified by a number of
bits. A bitmap might be created for storage in the display's video memory or as a device-
independent bitmap file.
A raster is technically characterized by the width and height of the image in pixels and by the
number of bits per pixel (or color depth, which determines the number of colors it can
represent).
Raster Graphics (cont.)
The printing and prepress industries know raster graphics as contones (from "continuous tones
"). The opposite to contones is "line work", usually implemented as vector graphics in digital
systems.
Vector images can be rasterized (converted into pixels), and raster images vectorized (raster
images converted into vector graphics), by software.
In both cases some information is lost, although certain vectorization operations can recreate
salient information, as in the case of optical character recognition.
Raster Graphics (Cont.)
It originates from the raster scan of cathode ray tube (CRT) video monitors,
which paint the image line by line by magnetically or electrostatically steering a
focused electron beam. By association, it can also refer to a rectangular grid of
pixels.
Computer displays
Most modern computers have bitmapped displays, where each on-screen pixel
directly corresponds to a small number of bits in memory. The screen is
refreshed simply by scanning through pixels and coloring them according to
each set of bits. The refresh procedure, being speed critical, is often
implemented by dedicated circuitry, often as a part of a
graphics processing unit.
Raster Graphics (Cont.)
Using this approach, the computer contains an area of memory that holds all the data that are
to be displayed. The central processor writes data into this region of memory and the video
controller collects them from there. The bits of data stored in this block of memory are related
to the eventual pattern of pixels that will be used to construct an image on the display.
An early scanned display with raster computer graphics was invented in the late 1960s by A.
Michael Noll at Bell Labs, but its patent application filed February 5, 1970 was abandoned at
the Supreme Court in 1977 over the issue of the patentability of computer software.
Vector Graphics
Vector graphics are computer graphics images that are defined in terms of points on a
Cartesian plane, which are connected by lines and curves to form polygons and other shapes.
Vector graphics have the unique advantage over raster graphics in that the points, lines, and
curves may be scaled up or down to any resolution with no aliasing.
The points determine the direction of the vector path; each path may have various properties
including values for stroke color, shape, curve, thickness, and fill.
Vector Graphics (cont.)
Instead of sectioning off a large region of computer memory and mapping that to the display
device, vector display devices use a variable number of lines to create images—hence the term
"vector graphics." Since vector display devices can define a line by dealing with just two points
(that is, the coordinates of each end of the line), the device can reduce the total amount of data
it must deal with by organizing the image in terms of pairs of points.
Vector graphics are commonly found today in the SVG, EPS, PDF or AI types of
graphic file formats, and are intrinsically different from the more common raster graphics file
formats such as JPEG, PNG, APNG, GIF, and MPEG4.
Vector Graphics (cont.)
Vector graphic displays were first used in 1958 by the US SAGE air defense system. Vector graphics
systems were retired from the U.S. en route air traffic control in 1999. Vector graphics were also used
on the TX-2 at the MIT Lincoln Laboratory by computer graphics pioneer Ivan Sutherland to run his
program Sketchpad in 1963.
Subsequent vector graphics systems, most of which iterated through dynamically modifiable stored
lists of drawing instructions, include the IBM 2250, Imlac PDS-1, and DEC GT40. There was a video
game console that used vector graphics called Vectrex as well as various arcade games like Asteroids,
Space Wars and many cinematronics titles such as Rip-Off, and Tail Gunner using vector monitors.
Storage scope displays, such as the Tektronix 4014, could display vector images but not modify them
without first erasing the display.
Vector Graphics (cont.)
Standards
The World Wide Web Consortium (W3C) standard for vector graphics is Scalable Vector Graphics
(SVG). The standard is complex and has been relatively slow to be established at least in part owing
to commercial interests. Many web browsers now have some support for rendering SVG data but full
implementations of the standard are still comparatively rare.
Modern displays and printers are raster devices; vector formats have to be converted to raster
format (bitmaps – pixel arrays) before they can be rendered (displayed or printed). The size of the
bitmap/raster-format file generated by the conversion will depend on the resolution required, but
the size of the vector file generating the bitmap/raster file will always remain the same.
Vector Graphics (cont.)
Vector art is ideal for printing since the art is made from a series of mathematical curves, it will print
very crisply even when resized. For instance, one can print a vector logo on a small sheet of copy
paper, and then enlarge the same vector logo to billboard size and keep the same crisp quality. A
low-resolution raster graphic would blur or pixelate excessively if it were enlarged from business card
size to billboard size.
If we regard typographic characters as images, then the same considerations that we have made for
graphics apply even to the composition of written text for printing (typesetting). Older character sets
were stored as bitmaps. Therefore, to achieve maximum print quality they had to be used at a given
resolution only; these font formats are said to be non-scalable. High-quality typography is nowadays
based on character drawings (fonts) which are typically stored as vector graphics, and as such are
scalable to any size. Examples of these vector formats for characters are Postscript fonts and
TrueType fonts.
Advantages of Vector Graphics over
Raster
Advantages to this style of drawing over raster graphics:
Because vector graphics consist of coordinates with lines/curves between them, the size of representation does
not depend on the dimensions of the object. This minimal amount of information translates to a much smaller
file size compared to large raster images which are defined pixel by pixel. This said, a vector graphic with a small
file size is often said to lack detail compared with a real world photo.
Correspondingly, one can infinitely zoom in on e.g., a circle arc, and it remains smooth. On the other hand, a
polygon representing a curve will reveal being not really curved.
On zooming in, lines and curves need not get wider proportionally. Often the width is either not increased or less
than proportional. On the other hand, irregular curves represented by simple geometric shapes may be made
proportionally wider when zooming in, to keep them looking smooth and not like these geometric shapes.
The parameters of objects are stored and can be later modified. This means that moving, scaling, rotating, filling
etc. doesn't degrade the quality of a drawing. Moreover, it is usual to specify the dimensions in device-
independent units, which results in the best possible rasterization on raster devices.
From a 3-D perspective, rendering shadows is also much more realistic with vector graphics, as shadows can be
abstracted into the rays of light from which they are formed. This allows for photorealistic images and renderings.
Vector Graphics (cont.)
For example, consider a circle of radius r.
The main pieces of information a program needs in order to draw this circle are:
an indication that what is to be drawn is a circle
the radius r
the location of the center point of the circle
stroke line style and color (possibly transparent)
fill style and color (possibly transparent)
Disadvantages of Vector Graphics
over Raster
Vector formats are not always appropriate in graphics work and also have numerous disadvantages.
For example, devices such as cameras and scanners produce essentially continuous-tone
raster graphics that are impractical to convert into vectors, and so for this type of work, an image
editor will operate on the pixels rather than on drawing objects defined by mathematical
expressions.
Comprehensive graphics tools will combine images from vector and raster sources, and may
provide editing tools for both, since some parts of an image could come from a camera source, and
others could have been drawn using vector tools.
Some authors have criticized the term vector graphics as being confusing. In particular, vector
graphics does not simply refer to graphics described by Euclidean vectors. Some authors have
proposed to use object-oriented graphics instead. However this term can also be confusing as it can
be read as any kind of graphics implemented using object-oriented programming.
Vector Graphics (cont.)
Typical primitive objects
Any particular vector file format supports only some kinds of primitive objects. Nearly all vector file
formats support simple and fast-rendering primitive objects - Lines, polylines and polygons, Bézier
curves and bezigons, Circles and ellipses
Most vector file formats support:
Text (in computer font formats such as TrueType where each letter is created from Bézier curves) or
quadratics, Color gradients, often, a bitmap image is considered as a primitive object. From the
conceptual view, it behaves as a rectangle.
A few vector file formats support more complex objects as primitives:
Many computer-aided design applications support splines and other curves, such as:
◦ Catmull–Rom splines and NURBS

iterated function systems, superellipses and superellipsoids, metaballs


If an image stored in one vector file format is converted to another file format that supports all the
primitive objects used in that particular image, then the conversion can be lossless.
Vector Graphics (cont.)
Vector operations
Vector graphics editors typically allow translation, rotation, mirroring, stretching, skewing,
affine transformations, changing of z-order (loosely, what's in front of what) and combination of
primitives into more complex objects. More sophisticated transformations include set operations on
closed shapes (union, difference, intersection, etc.).
Vector graphics are ideal for simple or composite drawings that need to be device-independent, or
do not need to achieve photo-realism. For example, the PostScript and PDF
page description languages use a vector graphics model.
Summery
This is the introductory lecture of Computer Graphics.
This lecture illustrates two popular Graphics Displays available in Computer Graphics including
standards, operations, advantages and disadvantages.
References
https://cseweb.ucsd.edu/classes/wi03/cse167/lectures/lec2.pdf
https://gorhamprinting.com/diy-book-printing/PDFS/VectorRaster.pdf
https://en.wikipedia.org/wiki/Vector_graphics
http://www.ijircce.com/upload/2017/february/128_Raster.pdf
https://www.researchgate.net/publication/228972543_Vectorialisation_of_raster_colour_image
s

You might also like