0% found this document useful (0 votes)
22 views32 pages

CG Material Unit 1 To 3

Uploaded by

fghg56
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
22 views32 pages

CG Material Unit 1 To 3

Uploaded by

fghg56
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 32

UNIT – 1

Computer Graphics refers to the field of computer science that involves the creation,
manipulation, and representation of visual images using computational methods and tools.
It encompasses techniques for rendering 2D and 3D visuals, animations, and simulations on
digital devices.

Computer Graphics is the discipline of producing and manipulating visual content, such as images,
diagrams, and animations, using computers and software tools. It focuses on the digital creation and
representation of visual data for communication, analysis, and interaction.

1. Application Areas of Graphics Systems

Graphics systems are an integral part of various fields, enabling users to create, process, and
interact with visual information. Below are some of the primary application areas where
graphics systems are widely utilized:

1.1.1. Presentation Graphics

Definition: Presentation graphics refer to the use of graphical representations of data and
information to communicate ideas, trends, or concepts clearly and effectively.

Applications:

- Business Presentations: Graphics are used in tools like PowerPoint or Google Slides to
create visually engaging presentations, including charts, graphs, and info graphics.

- Reports and Dashboards: Visualizing financial reports, sales data, or performance metrics
to allow better understanding and decision-making.

- Marketing: Visual aids such as promotional banners, logos, and product designs help in
effectively marketing products.

- Data Visualization: Complex data, such as statistical or scientific data, can be represented
graphically, making it easier to comprehend and analyze.

1.1.2. Entertainment

Definition: The entertainment industry makes extensive use of graphics systems for creating
visually captivating content for films, video games, and other forms of media.

Applications:

- Video Games: Graphics systems render real-time 3D environments, characters, and objects
in gaming. Game engines like Unity or Unreal Engine use advanced graphics techniques to
create realistic or stylized gaming worlds.
- Film and Animation: Special effects (SFX) in movies rely on graphics systems for creating
realistic environments, characters, and motion graphics.

- Virtual Reality (VR) and Augmented Reality (AR): VR and AR technologies provide
immersive experiences through computer-generated graphics, including virtual worlds or
overlays in the real world.

- TV Graphics: News channels, sports broadcasts, and entertainment shows use graphics for
scoreboards, live data overlays, and motion graphics.

1.1.3. Education and Training

Definition: Graphics systems are widely used in educational and training contexts to
improve understanding and engagement through visual aids and simulations.

Applications:

- E-learning: Interactive tutorials, virtual classrooms, and digital textbooks incorporate


graphics for better explanation of complex concepts.

- Simulations and Models: Graphics systems create virtual simulations for training in various
fields such as aviation, medicine, and engineering. For example, flight simulators or medical
procedure simulations help trainees practice skills without real-world consequences.

- Interactive Learning Tools: Educational games or quizzes with graphical elements enhance
student engagement and learning outcomes.

- 3D Models and Diagrams: Scientific concepts like anatomy, molecular structures, or


historical events are often represented using 3D graphics for better visualization.

1.1.4. Image Processing

Definition: Image processing refers to the manipulation of digital images using algorithms
and graphical systems to enhance, transform, or analyze the images.

Applications:

- Medical Imaging: Graphics systems process medical images such as X-rays, MRIs, and CT
scans to detect anomalies and assist doctors in diagnosis and treatment planning.

- Remote Sensing: Satellite images are processed and analyzed for applications in weather
forecasting, urban planning, and environmental monitoring.

- Computer Vision: Graphics systems help in object detection, facial recognition, and
autonomous vehicle navigation by analyzing images from cameras and sensors.
- Art and Design: Image editing tools like Photoshop or Illustrator rely heavily on graphics
systems for artistic creation, image manipulation, and design work.

In summary, graphics systems play a crucial role across various sectors, from making data
visually accessible in presentations, creating immersive entertainment experiences, to
enhancing education with interactive tools, and processing images for medical, scientific,
and creative purposes.

1.2 Computer Graphics Files

Computer graphics files are digital files used to store images, graphics, and other visual data
that can be created, edited, and displayed using computers. These files are fundamental for
various applications in graphics systems, ranging from professional image editing to online
media sharing. The structure, format, and content of these files are designed to suit specific
purposes, including storing raster or vector images, animations, and other visual content.

There are two primary categories of computer graphics files:

1. Raster Graphics Files

2. Vector Graphics Files

1.2.1 Raster Graphics Files

Raster graphics are made up of pixels (small dots of color), and raster image files store this
pixel-based data. These types of images are resolution-dependent, meaning that their
quality diminishes if resized beyond their original resolution.

Common Raster Graphics File Formats:

- JPEG (Joint Photographic Experts Group):

- Usage: Photographs, web images, and other types of complex images.

- Compression: Lossy compression (reduces file size by discarding some image data).

- Advantages: High compression ratio, small file size.

- Disadvantages: Loss of quality after compression and multiple edits.

- PNG (Portable Network Graphics):

- Usage: Web images, transparent backgrounds.

- Compression: Lossless compression (no loss of image data).

- Advantages: Supports transparency, no quality loss.

- Disadvantages: Larger file sizes than JPEG.


- GIF (Graphics Interchange Format):

- Usage: Web images, simple graphics, animations.

- Compression: Lossless compression.

- Advantages: Supports animations and transparency (binary transparency).

- Disadvantages: Limited to 256 colors (not suitable for complex images).

- BMP (Bitmap):

- Usage: Windows-based graphics, often used in older applications.

- Compression: Typically uncompressed.

- Advantages: Simple format with wide support.

- Disadvantages: Large file sizes, does not support advanced features like transparency.

- TIFF (Tagged Image File Format):

- Usage: High-quality images, scanning, and professional printing.

- Compression: Supports both lossy and lossless compression.

- Advantages: High quality, flexible, supports multiple layers.

- Disadvantages: Larger file sizes.

- RAW (Raw Image Format):

- Usage: Professional photography, high-quality images.

- Compression: Uncompressed or minimally compressed.

- Advantages: Highest quality, retains more data for post-processing.

- Disadvantages: Very large file sizes, requires special software for processing.

1.2.2 Vector Graphics Files

Vector graphics are based on mathematical formulas to represent shapes like lines, curves,
and polygons. Unlike raster images, vector graphics are resolution-independent and can be
scaled to any size without losing quality. These files are ideal for logos, illustrations,
diagrams, and any graphic that requires frequent resizing.

Common Vector Graphics File Formats:

- SVG (Scalable Vector Graphics):


- Usage: Web graphics, scalable logos, and interactive graphics.

- Compression: Can be compressed using XML-based methods.

- Advantages: Scalable without loss of quality, supports interactivity and animation.

- Disadvantages: Can become complex for very detailed images.

- AI (Adobe Illustrator):

- Usage: Professional vector illustrations and designs.

- Compression: Generally uncompressed or lightly compressed.

- Advantages: Wide toolset for design, industry-standard format.

- Disadvantages: Proprietary format (Adobe software needed to open).

- EPS (Encapsulated PostScript):

- Usage: High-quality vector graphics for printing, illustrations.

- Compression: Generally uncompressed.

- Advantages: Can include both vector and raster content.

- Disadvantages: Less commonly used in modern web graphics.

- PDF (Portable Document Format):

- Usage: Document sharing, vector graphics in publications.

- Compression: Supports both lossless and lossy compression.

- Advantages: Can embed vector and raster images, widely supported.

- Disadvantages: Larger file size with embedded raster images, limited editability.

- WMF (Windows Metafile):

- Usage: Windows-based vector graphics format.

- Compression: Typically uncompressed.

- Advantages: Supported by many Windows applications.

- Disadvantages: Less commonly used outside Windows environments.

1.2.3 Animation and 3D Graphics Files

These formats are used to store animated or three-dimensional graphics and models.
- GIF (Graphics Interchange Format): Also used for simple animations.

- SWF (Shockwave Flash): Used for vector-based animations and interactive content
(commonly used in early web design).

- FBX (Filmbox): A format for 3D modeling, animation, and interchange between different
3D software.

- OBJ (Wavefront): A format for 3D object models used in 3D rendering software.

- 3DS (3D Studio): A format used for 3D models and scenes created with 3D Studio Max.

1.2.4 Other Specialized Graphics Formats

- WEBP: A modern image format developed by Google, offering both lossless and lossy
compression for web use.

- HEIF (High Efficiency Image Format): Used for storing images and sequences of images,
such as in Apple's photo library.

1.2.5 Choosing the Right File Format

The choice of a file format depends on the intended application:

- For Web Use: Formats like JPEG, PNG, GIF, and SVG are commonly used due to their
optimization for loading speed and quality.

- For Printing: Formats such as TIFF, AI, and EPS are preferred due to their high quality and
scalability.

- For Professional Photography and Editing: RAW and TIFF offer the best quality and
flexibility in post-processing.

- For Animation: GIF, SWF, and modern formats like WebM are typically used for web-based
animations.

1.3 Introduction to Graphic Standards

Graphic standards refer to a set of guidelines, rules, and best practices that are used to
ensure the consistency, quality, and compatibility of graphical elements across various
platforms, devices, and applications. These standards help streamline the creation, sharing,
and display of graphical content, ensuring that it remains clear, professional, and functional
regardless of the system or medium used.

Graphic standards play a crucial role in various fields, such as web design, print media, user
interface design, and digital content creation. By adhering to these standards, designers and
developers can produce high-quality, accessible, and user-friendly graphics.
1.3.1 Purpose of Graphic Standards

- Consistency: Graphic standards ensure that designs, visuals, and layouts follow consistent
rules, which helps in creating a uniform experience for users or viewers.

- Interoperability: They help in making sure that graphics can be shared and viewed across
different platforms, devices, and software without compatibility issues.

- Quality Control: Standards set guidelines for image resolution, color schemes, file formats,
and other visual elements to maintain high-quality output.

- Brand Identity: In corporate environments, graphic standards help maintain a consistent


visual identity, such as logo usage, color schemes, fonts, and layout structures.

- Usability: Standards also ensure that the graphical content is designed to be user-friendly
and accessible to a wide audience, including those with disabilities.

1.3.2 Categories of Graphic Standards

Graphic standards can be classified into several categories based on their application:

1.3.2.1 File Format Standards

- JPEG, PNG, GIF, SVG: These formats have become widely accepted for web use due to
their balance between file size and image quality.

- TIFF, EPS, AI: For print and professional design, these formats are used for high-quality
graphics.

- WEBP: A modern standard for web images that provides both lossless and lossy
compression while maintaining good quality.

- PDF: A standard format for sharing documents that may include vector graphics, raster
images, and other multimedia elements.

1.3.2.2 Color Standards

- RGB (Red, Green, Blue): Primarily used for digital displays (screens), the RGB color model
defines colors based on varying intensities of red, green, and blue light.

- CMYK (Cyan, Magenta, Yellow, Black): Used for color printing, CMYK is a subtractive color
model where the colors are created by combining four inks.

- Pantone Color Matching System (PMS): A standardized color system widely used in
printing for consistency across different manufacturers.
1.3.2.3 Resolution and Image Quality Standards

- DPI (Dots Per Inch): Refers to the resolution of an image for printing. Typically, a higher
DPI (300 DPI) is used for print materials, while screen images use a lower DPI (72 DPI or 96
DPI).

- PPI (Pixels Per Inch): Refers to the pixel density of digital displays. The higher the PPI, the
sharper and clearer the image will be on the screen.

1.3.2.4 Typography Standards

- Font Usage: Guidelines about which fonts should be used in various design contexts (e.g.,
business documents, advertising, or websites).

- Font Sizes: Standards for font size and spacing to ensure readability and a consistent visual
appearance.

- Line Spacing and Kerning: Specific rules about the space between lines of text (leading)
and the space between characters (kerning) to improve legibility.

1.3.2.5 Layout and Design Standards

- Grid Systems: The use of grids ensures a structured and balanced layout for both digital
and print media. It helps designers organize text, images, and other elements in a visually
pleasing way.

- Whitespace (Negative Space): Adequate use of whitespace ensures that designs are not
cluttered and improve readability and overall aesthetics.

- Alignment and Margins: Ensuring proper alignment of text and images within a layout
improves the overall look and functionality of the graphic.

1.3.2.6 Interactive Graphics Standards

- UI/UX Guidelines: In interactive graphics, such as web design or software interfaces,


standards ensure that elements like buttons, sliders, and navigation menus are designed to
be intuitive and user-friendly.

- Accessibility: Standards like WCAG (Web Content Accessibility Guidelines) provide rules for
designing web content that is accessible to users with disabilities, such as those with visual
or motor impairments.

1.3.3 Common Graphic Standards Organizations

Several organizations and groups have developed graphic standards that are widely used
across industries:
- W3C (World Wide Web Consortium): Develops standards for web technologies, including
graphic formats (like SVG) and web accessibility guidelines (WCAG).

- ISO (International Organization for Standardization): Provides international standards for


various fields, including image quality, color matching, and print resolution.

- ANSI (American National Standards Institute): Publishes standards for graphic design and
technical illustrations, among other areas.

- Adobe Systems: Adobe has developed several industry standards related to graphics,
including the PDF format and the use of PostScript for printing.

1.3.4 Benefits of Adhering to Graphic Standards

1. Efficiency and Time Savings: By following predefined standards, designers and developers
can save time, as they don't need to reinvent rules for each project. This also simplifies
collaboration across teams.

2. Consistency in Brand Identity: Graphic standards ensure that a company or product’s


visual identity is consistent across all materials (e.g., advertisements, websites, business
cards).

3. Better User Experience: Consistent visual language improves the user experience by
making content easier to navigate, understand, and interact with.

4. Improved Accessibility: Standards for accessibility ensure that content can be consumed
by all users, including those with disabilities.

5. Enhanced Professionalism: Following graphic standards gives a polished and professional


appearance to content, making it more effective in communicating the intended message.

Graphic standards are essential for maintaining consistency, quality, and usability across
various forms of media and applications. By adhering to these standards, designers and
developers can ensure that their graphics are clear, professional, and accessible to a wide
audience, while also improving the overall user experience. As digital and print media
continue to evolve, graphic standards remain crucial for maintaining high-quality visual
content.
UNIT - 2
2.1 Video Display Devices

Video display devices are hardware components used to present visual information from
computers and other digital devices. These devices can display graphics, text, and video,
allowing users to interact with the system. In graphics systems, the type of video display
device used has a significant impact on image quality, performance, and overall user
experience. The main types of video display devices include CRT (Cathode Ray Tube)
displays, LCD (Liquid Crystal Display), and Direct View Storage Tubes. Below, we explore the
different types of video display devices.

2.1.1 Refresh CRT (Cathode Ray Tube)

Overview:

A Refresh CRT is a traditional display device that uses a cathode ray tube to display images
on a screen. The tube consists of an electron gun that fires electrons onto the
phosphorescent screen, which then illuminates to form images. The screen is refreshed
multiple times per second, creating a stable image.

How It Works:

- Electron Gun: The electron gun emits a stream of electrons that is directed toward the
screen's phosphor coating.

- Phosphors: When the electrons hit the phosphor coating on the screen, it glows and
produces light.
- Raster Scan: In a refresh CRT, the image is built up by scanning the electron beam across
the screen in a series of horizontal lines (raster scan). The image is refreshed many times per
second (typically 60 or 75 Hz), making it appear stable.

Characteristics:

- Resolution: The resolution is defined by the number of electron gun positions and the size
of the phosphor dots, which limits the screen resolution.

- Color Display: Early CRTs were monochrome, but color CRTs use multiple electron guns to
produce red, green, and blue light to create a full spectrum of colors.

- Image Persistence: CRTs exhibit image persistence, meaning that images may linger
temporarily on the screen after the beam has passed.

Advantages:

- High Refresh Rates: CRTs can display images with very high refresh rates, making them
suitable for dynamic graphics and fast motion.

- Deep Blacks: CRTs offer high contrast ratios, producing deep blacks and vivid colors.

Disadvantages:

- Bulky Design: CRTs are large, heavy, and take up significant space.

- Power Consumption: They consume more power compared to newer display technologies.

2.1.2 Color CRT (Cathode Ray Tube)

Overview:

A Color CRT is a type of CRT that is designed to display color images by using three electron
guns (red, green, and blue) to produce the full spectrum of colors.

How It Works:

- Trinitron Technology: The Color CRT uses a technology known as Trinitron (or similar
technologies like Shadow Mask) to direct the electron beams onto red, green, and blue
phosphor dots or stripes on the screen.

- Phosphor Coating: Each pixel on the screen consists of sub-pixels that emit red, green, and
blue colors when the electron beams strike them. The combination of these three colors
produces the full color spectrum.
Characteristics:

- Higher Color Accuracy: Color CRTs can produce accurate and vibrant colors, with deep
contrasts.

- Screen Geometry: Color CRTs often suffer from slight distortions due to the curvature of
the screen.

Advantages:

- High Color Fidelity: Excellent color reproduction and deep contrasts.

- Good Refresh Rate: Suitable for fast-moving images and video, providing smooth motion.

Disadvantages:

- Heavy and Bulky: Much larger and heavier than modern display technologies like LCD.

- Power Consumption: Consumes more power compared to flat-panel displays.

2.1.3 LCD (Liquid Crystal Display)

Overview:

An LCD is a flat-panel display that uses liquid crystal technology to produce images. Unlike
CRTs, LCDs do not rely on electron beams or phosphors. Instead, liquid crystals are
manipulated to block or transmit light, creating images.

How It Works:

- Backlight: A light source, often a LED (light-emitting diode) or CCFL (cold cathode
fluorescent lamp), provides the illumination behind the LCD panel.
- Liquid Crystals: The liquid crystals do not emit light by themselves. When electrical voltage
is applied, the crystals change their alignment to either block or allow light to pass through,
creating an image.

- Pixel Grid: Each pixel in an LCD is made up of sub-pixels that can display red, green, and
blue colors, forming the full range of colors in combination.

Characteristics:

- Resolution: LCDs have high resolutions and can display crisp and clear images.

- Thin Profile: LCDs are flat, lightweight, and take up significantly less space than CRTs.

- Power Efficiency: LCDs are more power-efficient compared to CRTs.

Advantages:

- Thin and Compact: LCDs are much thinner and lighter than CRTs, making them ideal for
portable and space-saving devices.

- Low Power Consumption: LCDs consume far less power than CRTs and are more energy-
efficient.

- Higher Resolution and Clarity: LCDs support higher resolutions, sharper images, and better
clarity.

Disadvantages:

- Limited Viewing Angles: Some LCDs suffer from poor viewing angles, where the image
quality degrades when viewed from the side.

- Motion Blur: Some lower-end LCDs may suffer from motion blur during fast-moving
images or video.

- Color Accuracy: Some LCDs may not be able to match the color accuracy of CRTs,
especially in darker scenes.
2.1.4 Direct View Storage Tube (DVST)

Direct View Storage Tube (DVST) resembles CRT as it uses electron gun to draw picture and
phosphor coated screen to display it. The phosphor used in this is of high persistence. DVST
does not use refresh buffer or frame buffer to store picture definition. Picture definition is
stored in inside CRT in form positive charged distribution. Because of this reason DVST is
knows as Storage Type CRT. In DVST no refreshing is required as result picture drawn on
DVST will be seen for several minutes before fading.

Various components of DVST :

1. Electron guns –
Two electron guns are used in DVST : Primary Gun and Flood Gun. Primary gun is
used to store picture pattern. Flood gun is used to maintain picture display on
phosphor coated screen.

2. Phosphor Coated Screen –


In DVST the inner surface of CRT is coated with phosphor crystals is of high
persistence that emit light when beam of electrons strike them.

3. Storage Mesh –
It is thin and high quality wire that is coated with dielectric and is located just behind
phosphor coated screen. Primary gun deposits pattern of positive charge on this grid
and it is transferred to phosphor coated screen by continuous flood of electrons
produced by flood gun. Thus Storage Mesh stores picture to be displayed in form of
positive charge distribution.

4. Collector –
This grid is located just behind storage mesh and purpose of this negatively charged
grid is to smooth out flow of flood electrons.

Working principle of DVST:


In DVST similar with CRT electron gun and phosphor coated method is used. But in this no
electron beam is used to directly writing pictures on screen, but instead of this we can used
Storage mesh wire grid is used it is just located behind phosphor coated screen. There is
also another grid located just behind storage mesh is called Collector and this purpose is to
smooth out flow of flood electrons. The flood gun produce large number of electrons, this
negatively charged grid reduces speed of these electrons. Then electrons pass through
collector at low velocity and attracted by positive charged portions of storage mesh and
strike at portions of phosphor coated screen to display picture. Some electrons get repelled
by other portions of mesh that are negatively charged.

Since the collector has slowly down electrons, in this way they not able to produce
sharpened images. So to reduce this problem, screen itself is maintained at a high positive
potential by means of voltage applied to thin aluminium coating between tube face and
phosphor.

Figure – Direct View Storage Tube

Advantages of DVST :

 For picture display it does not require refreshing.

 Display complex pictures at high resolution without any flicker.

 No use of frame buffer or refresh buffer.

Disadvantages of DVST :

 Not used for dynamic graphic such as animation.

 These systems do not display colors.

 To erase selected part of an image, entire screen needs to be erased and modified
pictures needs to be redrawn.

Different video display devices serve unique purposes and come with distinct advantages
and disadvantages. CRT displays (both refresh and color) were the dominant technology for
decades but have been largely replaced by LCD technology due to its compact form, lower
power consumption, and higher resolution capabilities. Meanwhile, the Direct View Storage
Tube (DVST) remains a specialized tool, valuable for applications requiring image
persistence and high-speed graphics. Understanding the characteristics and uses of these
display technologies is essential for selecting the appropriate device for specific applications
in graphics systems.

2.2 Raster Scan and Random Scan Display

In computer graphics systems, display devices can be categorized based on how they render
images on the screen. Two common methods of displaying graphics are Raster Scan and
Random Scan (also known as Vector Scan) displays. These two methods are fundamentally
different in how they generate and update images on the screen. Below, we will explore
both types of displays, their working principles, and their advantages and disadvantages.

2.2.1 Raster Scan Display

Overview:

A Raster Scan Display is a type of display in which the screen is divided into a grid of pixels
(picture elements). The image is created by scanning the electron beam in a series of
horizontal lines (called scan lines) from top to bottom, with each line consisting of a
sequence of pixels. This process is similar to how a traditional television or computer
monitor works.

How It Works:

- Electron Beam: In a raster scan display, the image is created by an electron beam (in the
case of CRTs) or a similar light-emitting source (in LCDs or LEDs) that moves in a systematic
pattern across the screen.

- Scanning Process: The beam starts at the top-left corner of the screen and scans left to
right along each line. Once it completes a line, it moves down to the next line until the
entire screen is filled. This process is known as raster scanning.
- Frame Rate and Refresh Rate: The screen is refreshed many times per second (usually 60
or 75 times per second), creating a continuous display. A frame represents one complete
pass of the electron beam across all scan lines.

Characteristics:

- Pixel-Based: The image is formed by a grid of individual pixels, with each pixel representing
a small part of the image.

- Resolution: The resolution of a raster scan display is determined by the number of pixels
on the screen (e.g., 1920x1080, 4K).

- Color Depth: Each pixel can represent a specific color, and the depth of color depends on
the display technology used (e.g., 24-bit color depth).
Advantages:

- Good for Complex Images: Raster scan displays are excellent for displaying complex
images, photographs, and video.

- Wide Compatibility: Most modern displays, including televisions, computer monitors, and
smartphones, use raster scan technology.

- Efficient for Static and Moving Images: Raster scan is ideal for displaying both static and
dynamic images such as videos and games.

Disadvantages:

- Resolution Limitations: The quality of the image is limited by the resolution, meaning that
if an image is stretched beyond its native resolution, it may appear pixelated or blurry.

- Fixed Grid: The fixed grid of pixels may not be as precise as vector-based graphics for
certain applications, such as detailed drawings or geometric shapes.

Applications:

- Television Screens: Standard televisions, as well as computer monitors, use raster scan
technology.

- Digital Imaging: Raster scan displays are used to view digital photographs, videos, and
multimedia content.

2.2.2 Random Scan Display (Vector Scan Display)

Overview:

A Random Scan Display (also known as Vector Scan Display) is a display technology where
the electron beam directly traces the shapes and lines that make up the image, as opposed
to scanning the entire screen in a systematic raster pattern. The electron beam moves to
specific points on the screen and draws lines between them to form objects.

How It Works:

- Vector Drawing: In random scan displays, the image is created by drawing lines one by
one. The electron beam moves directly to each point in the graphic and then draws the
appropriate line or shape.

- No Fixed Grid: Unlike raster scan displays, random scan displays are not restricted by a grid
of pixels. The image is drawn based on vectors (mathematical equations representing
shapes like lines, circles, and polygons).
- Direct Drawing of Lines: The system draws lines from one point to another, making it ideal
for drawing geometric shapes and line art, as well as other graphics that consist of vectors
rather than pixel-based images.

Characteristics:

- Vector-Based: The display is based on mathematical vectors (lines and curves), making it
ideal for displaying simple geometric shapes.

- Resolution Independence: The resolution is not determined by the number of pixels, but
by the precision with which the lines are drawn. The image quality can be more flexible and
smooth, especially for high-precision shapes.

- Faster Updates for Line Graphics: Since only the lines (or vectors) need to be drawn,
random scan displays can render these types of graphics quickly and efficiently.

Advantages:

- High Precision for Line Graphics: Random scan displays are ideal for drawing clear and
accurate lines, making them well-suited for applications that require detailed geometric
drawings, CAD (Computer-Aided Design) systems, and scientific plotting.

- Smooth Graphics: Images are not limited by pixels, so complex curves and fine lines can be
displayed without the pixelation that may appear in raster scan displays.

- Efficient for Simple Graphics: For applications that require the display of line drawings and
vectors, random scan displays can be more efficient and faster.

Disadvantages:

- Not Ideal for Complex Images: Random scan displays are not well-suited for displaying
complex images like photographs, because they lack the pixel grid structure that raster scan
displays use to reproduce complex color details.

- Limited Color Representation: Depending on the system, random scan displays may have
limited color reproduction because they typically use simpler hardware for rendering.

- Higher Power Consumption: For certain applications, random scan displays may consume
more power because of the need to continuously move the electron beam to different
locations on the screen.

Applications:

- Vector Graphics: Random scan displays were commonly used in early computer-aided
design (CAD) systems, flight simulators, and certain types of scientific instrumentation.
- Line-Based Graphics: They are ideal for displaying vector graphics, such as technical
drawings, wireframe models, and diagrams.

- Video Games (Early Years): In the early years of computer graphics, random scan displays
were used in some arcade games (such as Asteroids) that relied on vector graphics rather
than raster-based images.

2.2.3 Comparison of Raster Scan and Random Scan Displays

Feature Raster Scan Display Random Scan Display

Builds images using a grid of pixels Draws lines and shapes directly based
Image Creation
(raster). on vector graphics.

Best for complex, photo-realistic Best for simple geometric shapes and
Type of Graphics
images and video. line drawings.

Electron beam scans the entire Electron beam moves directly to


Display Method
screen line by line. points and draws lines.

Determined by the number of Resolution independent, depends on


Resolution
pixels on the screen. the vector precision.

Can represent millions of colors Limited color depth, often black and
Color Depth
(depending on system). white or limited colors.

Speed of Moderate, requires refreshing the Faster for line-based graphics, as only
Updates entire screen. specific points are drawn.

Television, computer monitors, CAD, scientific applications, vector-


Applications
video games, multimedia. based video games.

More suitable for complex, More suitable for simple, geometric,


Complexity
detailed images. and line-based graphics.

Power Generally more power-efficient May consume more power for line-
Consumption for complex images. based drawing.

Both Raster Scan Displays and Random Scan Displays have their own strengths and
weaknesses, making them suitable for different applications in computer graphics systems.
Raster Scan Displays are widely used for general-purpose applications, including television
and monitors, where complex images and video are required. Random Scan Displays, on the
other hand, are ideal for vector-based graphics, such as CAD systems and technical
illustrations, where high precision and smooth line rendering are needed. Understanding
the differences between these two types of displays helps in selecting the right technology
for specific graphics tasks.

2.3 Raster Graphics and Vector Graphics

In computer graphics, images can be categorized into two primary types based on their
representation and structure: Raster Graphics and Vector Graphics. These two types of
graphics differ fundamentally in how they represent and store visual information, and each
is suited to different applications.

2.3.1 Raster Graphics

Overview:

Raster graphics (also known as bitmap graphics) represent images as a grid of individual
pixels, where each pixel holds a color or grayscale value. Raster graphics are the most
commonly used graphics format for digital images, especially for photographs, scanned
images, and other complex visuals.

How It Works:

- Pixels: A raster image is made up of a matrix of tiny square units called pixels (picture
elements). Each pixel contains specific color information, and collectively, these pixels form
the complete image.

- Resolution Dependent: The quality and detail of raster images depend on their resolution,
which refers to the number of pixels in the image. Higher resolution means more pixels and
greater detail.

- Common Formats: Some of the common file formats for raster graphics include JPEG,
PNG, GIF, TIFF, and BMP.

Characteristics:

- Resolution-Based: Raster images are resolution-dependent, meaning their quality is


determined by the number of pixels. If you resize a raster image (especially to a larger size),
it can become pixelated or blurry.

- Detail and Complexity: Raster graphics are well-suited for representing complex images
such as photographs, textures, and detailed visual compositions.

- Color Depth: Raster images can support a wide range of colors, from basic 256 colors in
older formats (like GIF) to millions of colors in high-quality images (like those in JPEG or PNG
formats).
Advantages:

- Realistic Images: Raster graphics are ideal for representing photographic images and other
highly detailed visuals, such as scanned photographs, digital paintings, and textures.

- Wide Support: Raster graphics are widely supported by almost all image editors, web
browsers, and devices.

Disadvantages:

- Resolution Dependency: Resizing raster images can result in loss of quality (blurriness or
pixelation), as they are dependent on resolution.

- File Size: High-resolution raster images can have large file sizes, which can be difficult to
handle or slow to load, especially for web usage.

- Limited Scalability: Raster images do not scale well; resizing them without loss of quality
can be challenging.

Applications:

- Photography: Digital photos and scanned images are typically raster graphics.

- Web and Print Media: Raster graphics are used for textures, backgrounds, and image-
heavy designs.

- Video and Animation: Most animated content, including video, uses raster graphics.

2.3.2 Vector Graphics

Overview:

Vector graphics represent images using geometric shapes such as points, lines, curves, and
polygons, which are defined by mathematical equations. Unlike raster graphics, vector
images do not rely on pixels and can be resized infinitely without losing quality.

How It Works:

- Geometric Primitives: In vector graphics, shapes like lines, curves, circles, and rectangles
are defined using mathematical equations. These shapes are then combined to form
complex images.

- Resolution Independent: Because vector graphics are based on mathematical formulas,


they are resolution-independent. This means that vector images can be resized without any
loss of quality, regardless of their size.
- Common Formats: Common vector graphic formats include SVG (Scalable Vector
Graphics), EPS (Encapsulated PostScript), PDF (Portable Document Format), and AI (Adobe
Illustrator).

Characteristics:

- Mathematically Defined: Each element of a vector graphic (lines, shapes, text) is


represented by precise mathematical coordinates, making it scalable and editable.

- Small File Sizes: Vector graphics are often smaller in file size compared to high-resolution
raster graphics, since they only store the mathematical description of the shapes.

- Scalability: Vector images can be resized infinitely without any loss of quality, making them
ideal for logos, icons, and illustrations.

Advantages:

- Infinite Scalability: Vector images can be resized to any dimension without any pixelation
or loss of detail, making them perfect for applications where resizing is required (e.g., logos,
signage).

- Smaller File Sizes: Since vector graphics store mathematical data, they typically require
less storage space than high-resolution raster images.

- Editable: Vector graphics are easy to edit because each element (such as a line or curve) is
independent and can be manipulated without affecting the rest of the image.

Disadvantages:

- Not Ideal for Complex Images: Vector graphics are not suitable for detailed images like
photographs, where subtle color variations and textures are required. They are better suited
for simple graphics with solid colors and shapes.

- Limited Color Depth: While vector graphics can represent a wide range of colors, they are
often not as color-detailed as raster images, especially when dealing with gradients and
photorealistic images.

Applications:

- Logo Design: Logos are often created as vector images because they need to be scalable
for different uses (e.g., business cards, billboards).

- Illustrations and Drawings: Vector graphics are ideal for creating illustrations, diagrams,
and line art.

- Web Design: Icons and web graphics are often designed as vector graphics due to their
scalability and small file size.
- CAD (Computer-Aided Design): Vector graphics are used extensively in CAD software for
creating architectural plans, engineering drawings, and technical schematics.

2.3.3 Comparison of Raster Graphics and Vector Graphics

Feature Raster Graphics Vector Graphics

Made up of geometric shapes


Structure Made up of pixels (grid of color values).
(lines, curves).

Resolution-dependent (pixel count Resolution-independent (quality


Resolution
determines quality). remains the same at any size).

Not scalable without loss of quality Infinitely scalable without any loss
Scalability
(resizing can cause pixelation). of quality.

Larger file sizes, especially at high Smaller file sizes, especially for
File Size
resolutions. simple graphics.

Complexity of Best for complex images (e.g., Best for simple graphics (e.g.,
Images photographs, textures). logos, illustrations).

Less flexible for editing individual


Editing Highly editable since each element
elements (editing a pixel-based image
Flexibility (line or shape) is independent.
can be cumbersome).

Photographs, scanned images, detailed Logos, icons, illustrations,


Use Cases
artwork, videos. diagrams, technical drawings.

Limited in color depth, especially


Can represent a wide range of colors
Color Detail for complex color transitions (e.g.,
and details (e.g., gradients, textures).
gradients).

Web and print media, digital photos, Graphic design, typography, CAD,
Applications
video games, 3D modeling. icons, illustrations.

Conclusion

Both Raster Graphics and Vector Graphics have their own distinct advantages and are suited
for different types of projects. Raster graphics are ideal for complex, detailed images like
photographs and digital art, where color depth and texture are crucial. On the other hand,
Vector graphics excel in scenarios where scalability, precision, and small file sizes are
important, such as for logos, illustrations, and technical diagrams.

Choosing between raster and vector graphics depends largely on the type of image you
need to create and the specific use case. For high-quality, scalable designs, vector graphics
are typically the best choice, while for intricate, high-detail images, raster graphics are the
better option.

2.4. Concepts of various objects: Point, Line, Circle, Ellipse and Polygons

The concepts of various geometric objects such as Point, Line, Circle, Ellipse, and Polygons
are fundamental in mathematics, computer graphics, and related fields. Here's an overview:

1. Point

 Definition: A point is a location in space. It has no dimensions (length, width, or


height).

 Representation: Typically represented as coordinates in a space. For example:

o In 2D: (x,y)

o In 3D: (x,y,z)

 Use: Points are the building blocks of geometric objects.

2. Line

 Definition: A line is a straight one-dimensional figure extending infinitely in both


directions.

 Representation:

o Defined by two points or a point and a slope.

o Equation in 2D: y=mx+c (slope-intercept form), or ax+by+c=0 (general form).

 Properties:

o Has length but no thickness.

o Can be classified as infinite, ray (extending in one direction), or line segment


(with two endpoints).
3. Circle

 Definition: A circle is a set of points in a plane that are equidistant from a fixed point
called the center.

 Representation:

o Center: (h,k)

o Radius: r

o Equation: (x−h)2+(y−k)2=r2

 Properties:

o Perfectly symmetrical.

o Circumference: 2πr, Area: πr2.

4. Ellipse

 Definition: An ellipse is a curve where the sum of distances from any point on the
curve to two fixed points (foci) is constant.

5. Polygons

 Definition: A polygon is a closed figure made up of straight-line segments (edges)


that meet at vertices.

 Classification:

o Based on sides: Triangle (3 sides), Quadrilateral (4 sides), Pentagon (5 sides),


etc.

o Regular polygons: All sides and angles are equal (e.g., square, equilateral
triangle).

o Irregular polygons: Sides and/or angles are not equal.

 Properties:

o Sum of interior angles: (n−2)⋅180 for n sided polygon

o Convex or concave based on angle measurement.


UNIT – 3

Line Generation and Geometry of a Line

Understanding the geometry of a line is crucial for various applications in computer


graphics, computational geometry, and mathematics. Below is a detailed explanation:

3.1. Geometry of a Line

A line is a fundamental geometric entity with key properties and mathematical


representations.

Key Properties of a Line:

1. Infinite Length: A line extends infinitely in both directions.


2. Straightness: A line does not curve.
3. Defined by Points:
o A line can be uniquely determined by two points in a space, such as A(x1,y1)
and B(x2,y2).
4. Slope (m):
o Indicates the steepness or angle of the line.
o Formula: m=y2−y1/x2−x1, (change in y over change in x).
5. Intercepts:
o Y-intercept: Where the line crosses the y-axis (c in y=mx+c).
o X-intercept: Where the line crosses the x-axis (x0=−c/m if m≠0).

Mathematical Representations of a Line:

1. Slope-Intercept Form:

y=mx+c

o m: Slope of the line.


o c: Y-intercept.
2. Point-Slope Form:

y−y1=m(x−x1)

oUsed when the slope (m) and one point (x1,y1) are known.
3. Two-Point Form:

y−y1=(y2−y1/x2−x1)(x−x1)

Connects two points (x1,y1) and (x2,y2).


4. General Form:

ax+by+c=0

o a,b,c are constants.


5. Parametric Form:

x=x1+t(x2−x1),y=y1+t(y2−y1)

o t: Parameter (usually between 0 and 1 for line segments).

Line Generation in Computer Graphics

When creating lines on a digital display, algorithms are used to approximate the geometric
line on a pixel grid. Popular line generation algorithms include:

1. DDA (Digital Differential Analyzer) Algorithm:

 Uses incremental integer calculations to determine the next pixel position.


 Efficient but may cause rounding errors.

2. Bresenham’s Line Algorithm:

 Efficient algorithm using only integer arithmetic.


 Determines the optimal pixel positions to approximate a line.
 Particularly useful for raster graphics.

3. Midpoint Line Algorithm:

 Calculates the midpoint between two pixel choices and selects the pixel closer to the
line.

Applications of Line Generation:

 Drawing shapes like polygons and grids.


 Representing boundaries in computer graphics.
 Line-based graphical models and animations.

Understanding the geometry and algorithms for line generation is essential for tasks like
designing user interfaces, rendering graphics, and solving geometric problems
computationally.
3.2 Frame Buffer

A frame buffer is a key concept in computer graphics, playing a crucial role in rendering
images on a display. Below is a detailed explanation:

1. What is a Frame Buffer?

- A frame buffer is a dedicated block of memory used to store pixel data for rendering an
image on a screen.

- It acts as a bridge between the graphics rendering process and the display hardware.

- Each pixel's color and intensity information is stored in this buffer.

2. Structure of a Frame Buffer

The frame buffer is organized as a 2D array of memory locations, where:

- Rows and Columns correspond to the pixels on the screen.

- Each memory location stores information for a single pixel:

- Color: Typically represented as RGB (Red, Green, Blue) values.

- Depth: Some frame buffers include a z-buffer for depth information in 3D rendering.

Bit Depth

- The number of bits allocated for each pixel determines the color resolution (bit depth):

- 1-bit: Black and white.

- 8-bit: 256 shades of gray or colors.

- 16-bit: High color (65,536 colors).

- 24-bit or 32-bit: True color (16.7 million colors).

3. Types of Frame Buffers

1. Single Buffer:

- One buffer is used to store pixel data.

- May cause flickering during updates because the image is being written and displayed
simultaneously.
2. Double Buffer:

- Uses two buffers: one for rendering (off-screen) and the other for displaying (on-screen).

- Reduces flickering by swapping buffers after rendering is complete.

3. Triple Buffer:

- Adds a third buffer to reduce latency further in high-performance graphics.

4. Functions of a Frame Buffer

1. Pixel Storage: Stores pixel information, including color and depth.

2. Rasterization: Converts geometric primitives (e.g., lines, triangles) into pixel data.

3. Anti-Aliasing: Smoothens edges of objects by blending colors at boundaries.

4. Depth Management: In 3D graphics, stores depth values to handle occlusion (which


object is in front).

5. Applications of Frame Buffers

1. Computer Graphics: Rendering images for applications, games, and simulations.

2. Image Processing: Storing and manipulating image data.

3. Video Playback: Maintaining smooth rendering of video frames.

4. Virtual Reality: Ensures seamless transitions and rendering in immersive environments.

6. Challenges in Frame Buffers

1. Memory Usage: Higher resolutions and bit depths require significant memory.

2. Performance: Rendering and updating frame buffers in real-time can be computationally


intensive.

3. Synchronization: Maintaining synchronization between the frame buffer and display


refresh rate is crucial to prevent issues like tearing.

Understanding the frame buffer is essential for designing efficient rendering systems and
optimizing visual performance in graphics-intensive applications.
3.3 Line Drawing Algorithms

Line drawing algorithms are fundamental in computer graphics for approximating a straight
line on raster devices (pixel grids). These algorithms aim to identify the optimal pixel
positions to create the illusion of a continuous straight line.

3.3.1. DDA Algorithm (Digital Differential Analyzer)

The DDA algorithm is an incremental approach to line drawing that uses floating-point
calculations to determine intermediate points.

Steps of the DDA Algorithm:

1. Input:

o Start point (x1,y1) end point (x2,y2).

2. Calculate differences: Δx=x2−x1, Δy=y2−y1

3. Determine steps:

o steps=max (∣Δx∣,∣Δy∣)

4. Calculate increments: Increment for x: Δxs=Δx/steps, Increment for y: Δys=Δy/steps

5. Plot points:

o Start at (x,y)=(x1,y1)

o For each step, update: x=x+Δxs, y=y+Δys

 Round the values to the nearest integer for plotting.

Advantages:

 Simple to implement.

 Works for all line slopes.

Disadvantages:

 Involves floating-point arithmetic, which can be computationally expensive.

 Rounding introduces minor errors.


3.3.2. VECGEN Algorithm

The VECGEN (Vector Generator) algorithm is a hardware-friendly approach often used in


systems requiring high-speed rasterization.

Key Features:

 Uses integer arithmetic to avoid floating-point calculations.

 Focuses on minimizing computational overhead, making it suitable for hardware


implementation.

Steps:

1. Determine the slope and direction of the line.

2. Use pre-computed incremental values to decide which pixel to activate.

3. The algorithm adapts its plotting decision based on changes in x or y.

Applications:

 Used in older hardware systems where computational power was limited.

 Suitable for drawing fast lines in embedded systems.

3.3.3. Bresenham’s Line Algorithm

The Bresenham algorithm is an efficient and widely-used line-drawing algorithm that uses
only integer arithmetic.

Steps of Bresenham’s Algorithm:

1. Input:

o Start point (x1,y1) and end point (x2,y2).

2. Calculate differences: Δx=x2−x1, Δy=y2−y1

3. Determine decision parameter:

o Initial decision parameter: p=2Δy−Δx

4. Iterative calculation:

o Start at (x,y)=(x1,y1).

o For each x:

 Plot (x,y).
 Update decision parameter p:

 If p<0: p=p+2Δy

 Else:

 Increment y: y=y+1

 p=p+2Δy−2Δx

Advantages:

 Highly efficient; uses only integer calculations.

 Handles all line slopes effectively.

Disadvantages:

 Requires additional logic to handle negative slopes.

Comparison of Line Drawing Algorithms

Feature DDA Algorithm VECGEN Bresenham Algorithm

Arithmetic Floating-point Integer Integer

Speed Moderate Fast Fast

Accuracy Rounding errors Accurate Accurate

Complexity Simple Hardware-oriented Moderate

Applications Software rendering Embedded/hardware systems Modern graphics rendering

These algorithms are critical for rasterizing lines in applications ranging from video games to
graphical simulations. Bresenham's algorithm is often preferred due to its speed and
accuracy.

You might also like