Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

Computer Graphics Unit 1

Download as pdf or txt
Download as pdf or txt
You are on page 1of 41

Computer Graphics 1 Unit 1

Topics

Introduction: Fundamentals of Computer Graphics, point, dot, pixel,


Resolution, Elements of graphics workstation. Video Display Devices-Raster
Scan Systems Random Scan systems, aliasing problem and solution
techniques, Input devices. Graphics Coordinate Representations, Concepts of
v i d e o m e m o r y a n d f r a m e b u f f e r .

Fundamentals of Computer Graphics

Computer graphics is the field of visual computing that deals with generating,
manipulating, and displaying visual content using computers. It encompasses
a wide range of techniques and technologies for creating images, animations,
and interactive experiences.

 Rendering, in computer graphics, is the process of generating a 2D


image or animation from a 3D scene, simulating the interaction of light
with objects to produce a visual representation.

Graphics Pipeline: The graphics pipeline refers to the series of stages


involved in generating an image or animation. It typically includes stages such
as geometry processing, rasterization, shading, and rendering. Each stage
performs specific operations on input data to produce the final output.The
graphics pipeline encompasses various operations involved in generating images, including
geometry processing, rasterization, shading, and output to the screen.

Here's an overview of the typical stages in a graphics pipeline:

1. Application Stage:
- The graphics pipeline begins with the application stage, where higher-level operations
such as scene setup, object transformations, and camera positioning are performed.

TS 1
Computer Graphics 2 Unit 1

Application programs, such as 3D modeling software or video games, generate instructions


and data to describe the scene to be rendered.

2. Geometry Processing Stage:


- In this stage, the geometric data representing objects in the scene is processed and
transformed. This includes operations such as vertex transformations (e.g., scaling, rotation,
translation), culling (discarding invisible geometry), and possibly tessellation (breaking down
complex geometry into simpler primitives).

3. Rasterization Stage:
- Rasterization converts the geometric primitives (such as triangles or lines) generated in
the previous stage into fragments or pixels that correspond to points on the screen. Each
primitive is rasterized into a set of pixels, which are then processed further in subsequent
stages.

4. Vertex Shader:
- The vertex shader is a programmable stage in the graphics pipeline responsible for
manipulating individual vertices (points) of geometry. It can perform operations such as
lighting calculations, texture coordinate transformations, and vertex deformation.

5. Fragment Shader:
- The fragment shader, also known as the pixel shader, operates on each pixel generated
during rasterization. It calculates the final color of each pixel based on various factors such as
lighting, texture mapping, shading models, and material properties.

6. Raster Operations (ROP):


- Raster operations include operations performed on the fragments before they are written
to the frame buffer. This may involve depth testing (determining which fragments are visible),
alpha blending (combining colors from different fragments), and stencil testing (masking
fragments based on a stencil buffer).

7. Frame Buffer Output:


- Finally, the processed image data is written to the frame buffer, which holds the pixel
values for the entire screen. The contents of the frame buffer are then sent to the display
device for presentation on the screen.

The graphics pipeline is highly parallelized and optimized for efficiency, allowing for real-time
rendering of complex 3D scenes and animations in applications such as video games,
computer-aided design (CAD), virtual reality (VR), and scientific visualization. Each stage in
the pipeline performs specific tasks to transform and manipulate the graphical data, ultimately
resulting in the generation of visually compelling images and animations.

 Types of Computer Graphics


There are two kinds of computer graphics are– 
1. Interactive Computer Graphics 
2. Non-Interactive Computer Graphics

1) Interactive Computer Graphics


In interactive computer graphics, users have some controls over the image,
i.e., the user can make any changes to the image produced. Interactive
Computer Graphics involves computer-user two-way communication.

For Example: 
 Ping-pong game. 
 Drawing on touch screens. 

TS 2
Computer Graphics 3 Unit 1

 Display weather forecast or other moving charts/graphs on the


screen.
 Animating pictures or graphics in movies. 
 Graphics animation in video games.

Working of Interactive Computer Graphics

The modern display of graphics is very simple to build. It is composed of


three components:
 Display controller or video controller 
 Digital memory or frame buffer 
 Television monitor

TS 3
Computer Graphics 4 Unit 1

2) Non- Interactive Computer Graphics


Non-interactive computer graphics are also known as passive computer
graphics. It is a type of computer graphics in which the user has no control
over the image. The photo is completely controlled by the instructions of the
program, not by the user.
For Example: 
 Screen savers. 
 Map representation of the data. 
 Graphic elements are used in the text, document, and PDF
presentation.
 Static images are used in mobile applications and websites.
 Business graphics are used as brochures, business cards, menu
of the hotel.

Display Processor is the interpreter or a hardware that converts display


processor code into picture. The Display Processor converts the digital
information from CPU to analog values. The main purpose of the Digital
Processor is to free the CPU from most of the graphic chores. The Display
Processor digitize a picture definitions given in an application program into a
set of pixel intensity values for storage in the frame buffer. This digitization
process is called Scan Conversion.

The terms "display processor" and "display controller" are related but not
exactly the same. They refer to different components involved in managing
the display of visual information on a screen or monitor. Here's a brief
explanation of each:

1. Display Processor:

TS 4
Computer Graphics 5 Unit 1

- A display processor is a specialized component or subsystem responsible


for generating and processing graphical data. It performs tasks such as
rendering 2D or 3D graphics, applying visual effects, and managing display
output. Display processors are commonly found in graphics cards (GPU) and
integrated graphics solutions within computers and gaming consoles. They
are responsible for executing rendering pipelines, geometry processing,
texture mapping, shading, and other graphics-related operations.

2. Display Controller:
- A display controller is a hardware or software component responsible for
managing the interface between a display device (such as a monitor or screen)
and the rest of the computing system. It controls the timing and signal
generation required to send video data from the graphics processor to the
display device. The display controller is responsible for tasks such as
refreshing the screen, adjusting resolution and refresh rate, handling multiple
displays, and implementing features like scaling, rotation, and color
management. In simpler terms, the display controller acts as an intermediary
between the graphics processor and the display device, ensuring that visual
information is properly formatted and transmitted for display.

In summary, while both the display processor and display controller play
essential roles in managing the display of visual content, they serve different
functions. The display processor focuses on generating and processing
graphics data, while the display controller manages the interface between the
graphics processor and the display device, ensuring proper communication
and display output.

 Frame Buffer

A frame buffer is like a temporary storage area in a computer's memory that


holds the images or frames that you see on your screen. When your computer
needs to display something, like a picture or a video, it first stores that
information in the frame buffer. Then, the computer sends the data from the
frame buffer to your screen, which quickly shows the image. This process
happens very fast, so it looks like the images are moving smoothly on your
screen, even though they're actually made up of many individual frames.
Think of the frame buffer as a kind of "waiting area" for images before they
appear on your screen.

TS 5
Computer Graphics 6 Unit 1

 Video Memory

Also known as VRAM (Video Random Access Memory), is a special type of


memory in a computer dedicated to storing and accessing visual data used for
displaying images, videos, and graphics on a screen. In simpler terms, it's like
a storage space specifically designed to hold all the pictures and videos that
you see on your computer or device's screen.

Here's how video memory works:

1. Storage: Video memory stores the graphical data needed to create images
and videos on your screen. This includes information about colors, shapes,
textures, and other visual elements.

2. Access: The computer's graphics processing unit (GPU) accesses the


video memory to retrieve the graphical data and process it to create the
images you see on your screen. The GPU can quickly access and manipulate
the data in video memory to generate smooth animations, sharp images, and
vibrant colors.

3. Performance: The amount and speed of video memory can affect the
performance and quality of graphics on your screen. More video memory
allows for higher-resolution displays, more detailed textures, and smoother
animations. Faster video memory speeds up the process of rendering
graphics, leading to better overall performance in games, video playback, and
other graphics-intensive applications.

In summary, video memory is a dedicated memory space in a computer or


device that holds the graphical data used to create images and videos on the
screen. It plays a crucial role in delivering smooth, high-quality graphics and
animations for an enhanced visual experience.

Video memory and frame buffer are related concepts, both involved in
the process of displaying images and graphics on a screen, but they
serve slightly different purposes:

TS 6
Computer Graphics 7 Unit 1

1. Video Memory (VRAM):


- Video memory, also known as VRAM, is a type of memory specifically
dedicated to storing graphical data used for displaying images, videos, and
graphics on a screen. It is a physical memory module integrated into the
graphics processing unit (GPU) or graphics card.
- VRAM holds the raw pixel data, textures, and other graphical elements
that are used by the GPU to render images. It acts as a high-speed buffer
between the GPU and the display device, allowing for quick access to
graphical data during rendering.
- Video memory is responsible for storing and managing the graphical data
necessary for generating images and animations in real-time, making it
essential for high-performance graphics rendering in gaming, video editing,
and other graphics-intensive applications.

2. Frame Buffer:
- The frame buffer, sometimes referred to as the frame buffer, is a portion of
video memory used to temporarily store the rendered image or frame that is
currently being displayed on the screen.
- When the GPU finishes rendering an image, it stores the resulting pixel
data in the frame buffer. This allows the display device to quickly access the
image data and refresh the screen at the appropriate refresh rate.
- The frame buffer acts as a "waiting area" for completed frames before they
are displayed on the screen. It holds the most recently rendered image until
the display device is ready to refresh the screen with the next frame.
- The size of the frame buffer determines the maximum resolution and color
depth supported by the display device, as well as the number of frames that
can be stored in memory at once.

In summary, video memory (VRAM) is the dedicated memory space used for
storing graphical data, while the frame buffer is a portion of video memory
used to temporarily hold the rendered image or frame that is currently being
displayed on the screen. Both are essential components in the process of
rendering and displaying images and graphics on a computer or device's
screen.

TS 7
Computer Graphics 8 Unit 1

 Application of Computer Graphics

1. Computer-Aided Design (CAD) for Engineering and Architectural Systems:


- Used for creating digital models of mechanical parts, buildings, and other
structures.
- Objects can be displayed in wireframe, solid, or surface representation.
- Multi-window environments facilitate working with different views and
scales.
- Animations help in testing the performance of designs.

2. Presentation Graphics:
- Utilized to create illustrations summarizing various types of data.
- 3D graphics are particularly useful for visualizing complex data.
- Enables the creation of visually appealing presentations for reports or
conferences.

TS 8
Computer Graphics 9 Unit 1

3. Computer Art:
- Painting packages allow artists to create electronic paintings with various
brush strokes, widths, and colors.
- Photorealistic techniques, morphing, and animations are used for
commercial art and film production.
- Motion pictures, music videos, and computer games are forms of
entertainment that heavily rely on computer graphics.

4. Education and Training:

TS 9
Computer Graphics 10 Unit 1

- Computer-generated models are used for training purposes, such as


simulating specialized systems for training ship captains or aircraft pilots.
- Interactive simulations help in understanding complex concepts and
procedures.

5. Visualization:
- Used for analyzing scientific, engineering, medical, and business data.
- Converting data into visual forms aids in understanding large volumes of
information more efficiently.

6. Image Processing:
- Involves modifying or interpreting existing images using various techniques.
- Widely used in medical applications for tasks like image enhancement,
segmentation, and analysis.

TS 10
Computer Graphics 11 Unit 1

7. Graphical User Interface (GUI):


- GUIs provide user-friendly interfaces for interacting with computers.
- Features like multiple windows, icons, and menus enhance usability and
efficiency.

TS 11
Computer Graphics 12 Unit 1

 Point:
- Definition: A point in computer graphics typically refers to a location in a
two- or three-dimensional coordinate system, often represented by its x, y,
and sometimes z coordinates. It is a fundamental element used to define
geometric primitives such as lines, curves, and shapes.
- Example: In a 2D coordinate system, a point might be represented as (x,
y), where x and y are numerical values indicating its position along the
horizontal and vertical axes, respectively. For instance, the point (3, 5)
represents a location three units to the right and five units up from the origin.

 Dot:
- Definition: In colloquial language, "dot" is often used interchangeably with
"point." In computer graphics, it typically refers to a small, round mark on a
screen or surface. While it can represent a geometric point, it is often used
more informally.
In the context of a printer, the term "dot" typically refers to a small mark or
spot produced by the printer's printing mechanism. Printers, especially older
ones, often use a technique called dot matrix printing or similar methods
where characters or images are formed by a matrix of small dots.
- Example: When using a drawing program, clicking the mouse creates dots
on the screen, each representing a point in the digital space. These dots can
be connected to form lines or shapes.

 Pixel (Picture Element):


- Definition: A pixel is the smallest unit of a digital image or display. It
represents a single point in a raster image and contains color information.
Pixels are arranged in a grid pattern, and the combination of multiple pixels
forms an image.
- Example: Consider a digital photograph displayed on a computer screen.
Each tiny square on the screen represents a pixel. By combining millions of
pixels, the image is formed. For instance, a 1920x1080 pixel image has 1920
pixels in width and 1080 pixels in height, resulting in over two million individual
pixels contributing to the overall

TS 12
Computer Graphics 13 Unit 1

picture.

 Resolution:

 Resolution, in the context of computer graphics and digital imaging,


refers to the level of detail that can be represented or captured in an
image or display.
 It is often quantified in terms of the number of pixels or dots per unit of
length, such as pixels per inch (PPI) or dots per inch (DPI).
 The resolution of a display is determined by counting the horizontal and
vertical pixels. DPI is a resolution measurement used by printers (dots
per inch).
 Resolution plays a crucial role in determining the clarity, sharpness,
and quality of images and displays.

 Graphics Workstation:

A workstation is a powerful computer designed for professional use in tasks


requiring significant computational power, such as graphic design,
engineering, scientific research, and multimedia production. It typically
features high-performance hardware components optimized for specialized
applications and workflows. Workstations are used in industries where
reliability, performance, and support for demanding software are essential.

A graphics workstation is a specialized computer system designed specifically


for tasks related to creating, editing, and rendering visual content. It is
optimized to handle graphics-intensive applications such as graphic design,
animation, video editing, 3D modeling, architectural design, and scientific
visualization.

TS 13
Computer Graphics 14 Unit 1

Key features of a graphics workstation include:

1. High-Performance Hardware: Graphics workstations are equipped with


powerful processors (CPUs), dedicated graphics processing units (GPUs),
ample memory (RAM), and fast storage drives to handle complex graphics
computations and data processing tasks.

2. Professional-Grade Graphics Cards: Graphics workstations typically feature


professional-grade GPUs from manufacturers like NVIDIA (Quadro series) or
AMD (Radeon Pro series). These GPUs offer optimized drivers and
specialized features to support advanced graphics rendering, modeling, and
visualization tasks.

3. High-Resolution Displays: Graphics workstations often use high-resolution


monitors with wide color gamuts and accurate color calibration to ensure
precise color reproduction and detailed imagery.

4. Specialized Software and Tools: Graphics workstations come with industry-


standard software tools tailored for specific creative disciplines, such as
Adobe Creative Cloud suite for graphic design and video editing, Autodesk
Maya or Blender for 3D modeling and animation, and CAD/CAM software for
engineering and architectural design.

5. Color Management and Calibration: Graphics workstations employ color


management systems and calibration tools to maintain accurate color
reproduction across different devices and outputs, ensuring consistency in
visual content creation.

6. Specialized Input Devices: Graphics professionals use specialized input


devices such as graphics tablets, stylus pens, and high-precision mice for
precise control and manipulation of digital content.

7. Expandability and Upgradeability: Graphics workstations are designed to


be highly expandable and customizable, allowing users to upgrade hardware
components such as memory, storage, and graphics cards to meet evolving
performance requirements and workflow demands.

TS 14
Computer Graphics 15 Unit 1

Graphics workstations are essential tools for professionals in fields such as


graphic design, animation, film production, architecture, engineering, and
scientific research, enabling them to create and manipulate visual content with
precision, efficiency, and reliability.

Graphics Monitor:
i) The name itself giving some idea that, Monitor which is capable of
displaying “Graphics”. Generally most of the Monitors support Text modes.
ii) So Monitors which are capable of showing and supporting Graphics
mode along with the Text modes.
iii) Graphic monitors who can display pictures on its screen, of course it
acts like an output device. The monitors which support the following Graphic
applications are said to be Graphic Monitors.

TS 15
Computer Graphics 16 Unit 1

TS 16
Computer Graphics 17 Unit 1

TS 17
Computer Graphics 18 Unit 1

Video Display Devices:


Video display devices, also known as display monitors or screens, are
electronic devices used to visually display digital content such as images,
videos, text, and graphical user interfaces (GUIs). These devices come in
various forms, sizes, and technologies, catering to different applications and
preferences.

Here are some common types of video display devices:

 Cathode Ray Tube (CRT) Monitors


 Liquid Crystal Display (LCD) Monitors
 Light-Emitting Diode (LED) Monitors
 Organic Light-Emitting Diode (OLED) Displays
 Plasma Displays

Cathode Ray Tube

CRT stands for Cathode ray tube. It is a technology which is used in


traditional computer monitor and television. Cathode ray tube is a particular
type of vacuum tube that displays images when an electron beam collides on
the radiant surface. The primary output device in a graphical system is the
video monitor. Cathode-Ray Tubes (CRT) - still the most common video
display device presently.

Component of CRT:
 Electron Gun: The electron gun is made up of several elements, mainly a
heating filament (heater) and a cathode.
 The electron gun is a source of electrons focused on a narrow beam
facing the CRT. 
 Focusing & Accelerating Anodes: These anodes are used to produce a
narrow and sharply focused beam of electrons.
 Horizontal & Vertical Deflection Plates: These plates are used to guide the
path of the electron the beam. The plates produce an electromagnetic
field that bends the electron beam through the area as it travels. 
 Phosphorus-coated Screen: The phosphorus coated screen is used to
produce bright spots when the high-velocity electron beam hits it.

TS 18
Computer Graphics 19 Unit 1

The operation of CRT is very simple − 


1. The electron gun emits a beam of electrons cathode rays. 
2. The electron beam passes through focusing and deflection systems that
direct it towards specified positions on the phosphor-coated screen. 
3. When the beam hits the screen, the phosphor emits a small spot of light
at each position contacted by the electron beam. 
4. It redraws the picture by directing the electron beam back over the same
screen points quickly.

Color CRT Monitor:

It is similar to a CRT monitor. The basic idea behind the color CRT monitor is
to combine three basic colors- Red, Green, and Blue. By using these three
colors, we can produce millions of different colors.

The two basic color display producing techniques are:

1. Beam–Penetration Method: It is used with a random scan monitor for


displaying pictures. There are two phosphorus layers- Red and Green are
coated inside the screen. The color shown depends on how far the electron
beam penetrates the phosphorus surface.

A powerful electron beam penetrates the CRT, it passes through the red layer
and excites the green layer within. A beam with slow electrons excites only
the red layer. A beam with the medium speed of electrons, a mixture of red
and green light is emitted to display two more colors- orange and yellow.

Advantages: 1. Better Resolution 2. Half cost 3. Inexpensive


Disadvantages: 1. Only four possible colors 2. Time Consuming

2. Shadow–Mask Method: It is used with a raster scan monitor for


displaying pictures. It has more range of color than the beam penetration
method.

It is used in television sets and monitors.

TS 19
Computer Graphics 20 Unit 1

Structure:
1. It has three phosphorus color dots at each position of the pixel

First Dot: Red color


Second Dot: Green color
Third Dot: Blue color

1. It has three different guns. Each for one color.


2. It has a metal screen or plate just before the phosphorus screen, named
“Shadow-Mask.”
3. It also has a shadow grid just behind the phosphorus coated screen with
tiny holes in a triangular shape.

Working:
 A Shadow Mask is a metal plate with tiny holes present inside a color
monitor.
 A Shadow Mask directs the beam by consuming the electrons so that the
beam hits only the desired point and displays a resulting picture.
 It has three different guns.
 These guns direct their beams to shadow mask, which allows them to
pass.
 It is a task of a shadow mask to direct the beam on its particular dot on
the screen and produce a picture on the screen.
 A Shadow Mask can display a wider range of pictures than beam
penetration.

Advantages:
1. Display a wider range picture.
2. Display realistic images.
3. 3. In-line arrangement of RGB color.

TS 20
Computer Graphics 21 Unit 1

Disadvantages:
1) Difficult to cover all three beams on the same hole.
2) Poor Resolution

TS 21
Computer Graphics 22 Unit 1

TS 22
Computer Graphics 23 Unit 1

TS 23
Computer Graphics 24 Unit 1

TS 24
Computer Graphics 25 Unit 1

There are two ways Random scan and Raster scan by which we can
display an object on the screen.

1. Raster Scan

 In a raster scan system, the electron


beam is swept across the screen,
one row at a time from top to bottom.
 As the electron beam moves across
each row, the beam intensity is
turned on and off to create a pattern
of illuminated spots.
 Picture definition is stored in memory
area called the Refresh Buffer or
Frame Buffer.
 This memory area holds the set of
intensity values for all the screen
points. Stored intensity values are
then retrieved from the refresh buffer
and “painted” on the screen one row
scan line at a time as shown in the
following illustration.
 Each screen point is referred to as a pixel picture element or pel. At the
end of each scan line, the electron beam returns to the left side of the
screen to begin displaying the next scan line.

2. Random Scan /Vector


Scan
 In this technique, the electron beam
is directed only to the part of the
screen where the picture is to be
drawn rather than scanning from left
to right and top to bottom as in raster
scan.
 It is also called vector display,
stroke-writing display, or calligraphic
display.
 Picture definition is stored as a set of
line-drawing commands in an area of
memory referred to as the refresh
display file.
 To display a specified picture, the system cycles through the set of
commands in the display file, drawing each component line in turn.

TS 25
Computer Graphics 26 Unit 1

 After all the line-drawing commands are processed, the system cycles
back to the first line command in the list.
 Random-scan displays are designed to draw all the component lines of a
picture 30 to 60 times each second.

 Pipeline
A pipeline refers to a series of stages or steps through which graphical data passes in order
to be processed and rendered onto a display device. The graphics pipeline encompasses
various operations involved in generating images, including geometry processing,
rasterization, shading, and output to the screen.

Here's an overview of the typical stages in a graphics pipeline:

1. Application Stage:
- The graphics pipeline begins with the application stage, where higher-level operations
such as scene setup, object transformations, and camera positioning are performed.
Application programs, such as 3D modeling software or video games, generate instructions
and data to describe the scene to be rendered.

2. Geometry Processing Stage:


- In this stage, the geometric data representing objects in the scene is processed and
transformed. This includes operations such as vertex transformations (e.g., scaling, rotation,
translation), culling (discarding invisible geometry), and possibly tessellation (breaking down
complex geometry into simpler primitives).

3. Rasterization Stage:
- Rasterization converts the geometric primitives (such as triangles or lines) generated in
the previous stage into fragments or pixels that correspond to points on the screen. Each
primitive is rasterized into a set of pixels, which are then processed further in subsequent
stages.

4. Vertex Shader:
- The vertex shader is a programmable stage in the graphics pipeline responsible for
manipulating individual vertices (points) of geometry. It can perform operations such as
lighting calculations, texture coordinate transformations, and vertex deformation.

5. Fragment Shader:
- The fragment shader, also known as the pixel shader, operates on each pixel generated
during rasterization. It calculates the final color of each pixel based on various factors such as
lighting, texture mapping, shading models, and material properties.

6. Raster Operations (ROP):


- Raster operations include operations performed on the fragments before they are written
to the frame buffer. This may involve depth testing (determining which fragments are visible),

TS 26
Computer Graphics 27 Unit 1

alpha blending (combining colors from different fragments), and stencil testing (masking
fragments based on a stencil buffer).

7. Frame Buffer Output:


- Finally, the processed image data is written to the frame buffer, which holds the pixel
values for the entire screen. The contents of the frame buffer are then sent to the display
device for presentation on the screen.

The graphics pipeline is highly parallelized and optimized for efficiency, allowing for real-time
rendering of complex 3D scenes and animations in applications such as video games,
computer-aided design (CAD), virtual reality (VR), and scientific visualization. Each stage in
the pipeline performs specific tasks to transform and manipulate the graphical data, ultimately
resulting in the generation of visually compelling images and animations.

 Graphics Coordinate Representations

Graphics coordinate representations are methods used to define and locate


points, shapes, or objects within a graphical environment. Different coordinate
systems are utilized based on specific requirements or the nature of the
graphical content.
1. Cartesian Coordinates: Represent points in a 2D plane using horizontal
(x-axis) and vertical (y-axis) axes, with the origin typically at the bottom-left
corner. Points are defined by their distances from the origin along each axis.
2. Viewport Coordinates: Define points within the visible region of a display
device, usually relative to the screen's resolution and aspect ratio, with the
origin at the top-left corner.

 Aliasing Problem

Antialiasing is a technique used in computer graphics to remove the


aliasing effect. The aliasing effect is the appearance of jagged edges or
“jaggies” in a rasterized image (an image rendered using pixels). The
problem of jagged edges technically occurs due to distortion of the image
when scan conversion is done with sampling at a low frequency, which is also
known as Undersampling. Aliasing occurs when real-world objects which
comprise smooth, continuous curves are rasterized using pixels. The cause of
anti-aliasing is Undersampling.

Undersampling results in a loss of information about the picture.

TS 27
Computer Graphics 28 Unit 1

Methods of Anti-Aliasing (AA)

There are four methods of Anti-Aliasing. These methods are mentioned below.

 High-Resolution Display
 Post-Fingering
 Pre-Filtering
 Pixel Phasing

1. Using High-Resolution Display

One way to reduce the aliasing effect and increase the sampling rate is to
simply display objects at a higher resolution. Using high resolution, the jaggies
become so small that they become indistinguishable from the human eye.
Hence, jagged edges get blurred out and edges appear smooth.

Practical applications: For example, retina displays in Apple devices, and


OLED displays have high pixel density due to which jaggies formed are so
small that they blurred and are indistinguishable by our eyes.

2. Post Filtering (Supersampling)

In this method, we are increasing the sampling resolution by treating the


screen as if it’s made of a much more fine grid, due to which the effective
pixel size is reduced. But the screen resolution remains the same. Now,
intensity from each subpixel is calculated and the average intensity of the
pixel is found from the average of intensities of subpixels. Thus we do
sampling at a higher resolution and display the image at a lower resolution or
resolution of the screen, hence this technique is called supersampling. This
method is also known as post filtration as this procedure is done after
generating the rasterized image.

Practical Applications: In gaming, SSAA (Supersample Antialiasing) or


FSAA (Full-Scene Antialiasing) is used to create the best image quality. It is
often called pure AA and hence is very slow and has a very high

TS 28
Computer Graphics 29 Unit 1

computational cost. This technique was widely used in the early days when
better AA techniques were not available. Different modes of SSAA available
are: 2X, 4X, 8X, etc. denoting that sampling is done x times (more than) the
current resolution. A better style of Anti-Aliasing is MSAA (Multisampling
Antialiasing) which is a faster and more approximate style of supersampling
AA. It has a lesser computational cost. Better and more sophisticated
supersampling techniques are developed by graphics card companies like
CSAA by NVIDIA and CFAA by AMD.

3. Pre-Filtering (Area Sampling)

In area sampling, pixel intensities are calculated proportionally to areas of


overlap of each pixel with objects to be displayed. Here pixel color is
computed based on the overlap of the scene’s objects with a pixel area.

Example: Suppose, a line passes through two pixels. The pixel covering a
bigger portion(90%) of the line displays 90% intensity while less area(10%)
covering the pixel displays 10-15% intensity. If the pixel area overlaps with
different color areas, then the final pixel color is taken as an average of colors
of the overlap area. This method is also known as pre-filtering as this
procedure is done BEFORE generating the rasterized image. It’s done using
some graphics primitive algorithms.

4. Pixel Phasing

It’s a technique to remove aliasing. Here pixel positions are shifted to nearly
approximate positions near object geometry. Some systems allow the size of
individual pixels to be adjusted for distributing intensities which is helpful in
pixel phasing.

TS 29
Computer Graphics 30 Unit 1

Input Devices
Following are some of the important input devices which are used in a
computer − 
 Keyboard 
 Mouse
 Joy Stick 
 Light pen 
 Track Ball 
 Scanner 
 Graphic Tablet 
 Microphone 
 Magnetic Ink Card Reader(MICR) 
 Optical Character Reader(OCR) 
 Bar Code Reader 
 Optical Mark Reader(OMR)

TS 30
Computer Graphics 31 Unit 1

TS 31
Computer Graphics 32 Unit 1

TS 32
Computer Graphics 33 Unit 1

TS 33
Computer Graphics 34 Unit 1

TS 34
Computer Graphics 35 Unit 1

TS 35
Computer Graphics 36 Unit 1

TS 36
Computer Graphics 37 Unit 1

TS 37
Computer Graphics 38 Unit 1

TS 38
Computer Graphics 39 Unit 1

TS 39
Computer Graphics 40 Unit 1

TS 40
Computer Graphics 41 Unit 1

TS 41

You might also like