04/04/2025
Chapter One: Introdction to Computer Graphics
1
College of Natural and Computational Sciences
Department of Computer Science
Course Title : Computer Graphics
Chapter One:
Introduction to Computer Graphics
Outline
 Introduction
 What is Computer Graphics?
 Why Computer Graphics?
 Motivation for Computer Graphics
 Steps in Computer Graphics
 Some cool projects in Computer Graphics
 Application of Computer Graphics
 Representation of Computer Graphics
04/04/2025
Chapter One: Introdction to Computer Graphics
2
Introduction
Computer is information processing machine.
User needs to communicate with computer and the computer
graphics is one of the most effective and commonly used ways
of communication with the user
Computer Graphics(CG) displays the information in the forma
of graphical object such as pictures, charts, diagram and graphs.
Graphical objects convey more information in less time and
easily understandable formats for example statically graph
shown in stock exchange.
Generally Computer graphics is the computational creation and
manipulation of visual data.

04/04/2025
Chapter One: Introdction to Computer Graphics
3
Cont’d…
 The field of computer graphics has evolved significantly over
the years, and today, it plays a vital role in entertainment,
communication, design, education, and more.
 At its core, computer graphics involves creating images from
data through processes like rendering, modeling, and
simulation.
 Overall, computer graphics is an interdisciplinary field that
continues to drive advancements in technology and creativity,
pushing the boundaries of visual experiences.
04/04/2025
Chapter One: Introdction to Computer Graphics
4
 In today’s digital era, computer graphics technologies have
revolutionized how we perceive and interact with visual
information, playing a pivotal role in video games, movies,
architectural design, medical imaging, and more.
 There are several tools used for the implementation of
Computer Graphics.
 The basic is the graphics.h header file in Turbo-C, Unity for
advanced, and even OpenGL can be used for its
Implementation.
04/04/2025
Chapter One: Introdction to Computer Graphics
5
What is Computer Graphics?
 Computer graphics generally means creation, storage and
manipulation of models and images using Computers
 Models are representation of a real world object in the
computer
 Such models come from diverse and expanding set of fields
including physical, biological, mathematical, artistic, and
conceptual/abstract structures
04/04/2025
Chapter One: Introdction to Computer Graphics
6
 CG is in daily use in the field of science, engineering,
medicine, entertainment, advertising, the graphic arts, the
fine arts, business, education etc.
 The electronic industry is more dependent on the
technologies provided by CG such as engineers can draw
their circuit in a much shorter time,
 architects can have alternative solution to design problems,
 the molecular biologist can display pictures of molecules
and can study on the structure,
 the town planners and transportation engineers use the
computer generated maps which display data useful to them
in their planning work etc.
04/04/2025
Chapter One: Introdction to Computer Graphics
7
Cont’d…
 Computer graphics is an art of drawing pictures on computer
screens with the help of programming.
 It involves computations, creation, and manipulation of data.
 In other words, we can say that computer graphics is a rendering
tool for the generation and manipulation of images.
 Computer Graphics image is made up of number of Pixels.
 Pixel is the smallest addressable graphical unit represented on
computer screen.
04/04/2025
Chapter One: Introdction to Computer Graphics
8
Why Computer Graphics
 Understanding and interpreting information:
Visualization is necessary for dealing with complex data.
 Improved communication with computers:
Graphical and audio interfaces are helpful.
 Better product designs: Designers can explore more
avenues in less time and can focus on the creative aspects of
design (which do not include drafting).
 More economical designs: Design databases can be
"tested" electronically, reducing dependence on complex and
costly physical modes (e.g. aircraft).
 Better products: Design databases can be transmitted to
robots for manufacturing (3-D output).
04/04/2025
Chapter One: Introdction to Computer Graphics
9
Motivation for Computer Graphics
 Many engineering and scientific fields require visualization
to help people easily understand the problem in their
domain
It is better to see 3DView of a building than a simple 2D sketch
Cont’d…
 We want to have vivid imagination of things that we
couldn’t possibly see directly
Cont’d…
 We want to have vivid imagination of things that we
couldn’t possibly see directly
Cont’d…
 We want imaginary characters in entertainment to create
different experience and feeling
Steps in Computer Graphics
 Computer graphics involves a series of steps to create,
manipulate, and display visual content.
 These steps form a pipeline that transforms raw data
into a final image or animation.
 This pipeline is the foundation of computer graphics,
whether for creating static images, animations, or
interactive applications.
04/04/2025
Chapter One: Introdction to Computer Graphics
14
Cont’d…
 Each step can vary in complexity depending on the
desired level of realism and performance.
 Computer graphics works by combining
mathematical models, algorithms, and hardware to
create and manipulate visual content.
 It is a multidisciplinary field that continues to
evolve with advancements in technology and
creativity.
04/04/2025
Chapter One: Introdction to Computer Graphics
15
Cont’d…
 The steps in computer graphics includes:
1.Modeling: Create 3D objects.
2.Transformation: Position and orient objects.
3.Lighting: Simulate light interactions.
4.Viewing and Projection: Convert 3D to 2D.
5.Rasterization: Convert shapes to pixels.
6.Shading and Texturing: Add surface details.
7.Rendering: Generate the final image.
8.Post-Processing: Enhance the image.
9.Display: Show the image to the user.
10.Interaction: Enable real-time updates (if applicable).
04/04/2025
Chapter One: Introdction to Computer Graphics
16
Computer Graphics as Interdecipline
 Computer graphics is inherently interdisciplinary because it
blends multiple fields of study to create the complex visual
systems and imagery we interact with today.
 Here are some key disciplines that intersect with computer
graphics:
1. Computer Science:
 This is the foundation of computer graphics, providing algorithms, data
structures, and computational techniques for rendering, animation, and
image processing.
 Topics like graphics programming, hardware acceleration (e.g., using
GPUs), and rendering algorithms are deeply rooted in computer science.
04/04/2025
Chapter One: Introdction to Computer Graphics
17
Cont’d…
2. Mathematics: Computer graphics relies heavily on
mathematics, especially geometry, linear algebra, and calculus.
Understanding 3D transformations, vector spaces, matrix
operations, and trigonometry is crucial for manipulating shapes,
performing animations, and rendering realistic images.
3. Physics: In graphics, physics helps simulate real-world
behaviors, such as lighting, shadows, textures, and motion.
Concepts from physics, such as ray tracing, reflections, refraction,
and fluid dynamics, are key to creating realistic environments and
animations.
04/04/2025
Chapter One: Introdction to Computer Graphics
18
Cont’d…
4.Art and Design: Computer graphics is also tied to the artistic
and design aspects of visual representation. Knowledge of color
theory, composition, texture mapping, and user interface (UI)
design is crucial for creating aesthetically pleasing and functional
visual content.
5. Psychology: Understanding how humans perceive visual
information is important for designing graphics that communicate
effectively. Concepts like visual perception, color psychology, and
attention theories guide how graphics are presented to users to
evoke desired reactions or behaviors.
6. Engineering: Hardware and software engineering play a key
role in computer graphics, especially in terms of developing
efficient algorithms, optimizing performance for rendering, and
building graphics hardware like GPUs (Graphics Processing Units)
that drive real-time rendering and gaming.
04/04/2025
Chapter One: Introdction to Computer Graphics
19
Cont’d…
7.Human-Computer Interaction (HCI): In this area, the
focus is on how people interact with graphical interfaces and
virtual environments. Knowledge from HCI helps improve the
usability and accessibility of graphics, ensuring that users can
navigate digital environments easily and intuitively.
8.Animation and Film Studies: Graphics often intersect with
animation techniques and cinematic storytelling, requiring an
understanding of motion, timing, narrative structures, and special
effects to create compelling animated sequences or visual effects
in movies.
04/04/2025
Chapter One: Introdction to Computer Graphics
20
Cont’d…
9.Artificial Intelligence (AI): AI is used in computer graphics
for tasks such as procedural content generation, facial recognition,
motion capture, and deep learning techniques applied to image
recognition and enhancement.
10. Geographic Information Systems (GIS): Graphics are
also used in geospatial data visualization, mapping, and
simulations. Here, spatial analysis and visual representation
techniques from graphics are used to interpret and display large
datasets like topographical maps or satellite imagery.
04/04/2025
Chapter One: Introdction to Computer Graphics
21
Some cool projects in Computer Graphics
 Computer graphics is a broad and exciting field with many
creative and technically challenging projects. Here are some
cool examples of computer graphics projects that demonstrate
the diversity and impact of this area:
1. Photorealistic Rendering (RayTracing)
-Achieving photorealistic images of virtual environments and objects
is both technically challenging and visually stunning.
2. 3D Modeling forVirtual Reality (VR)
- The ability to "paint" in a 3D space gives users a unique artistic
experience that traditional 2D mediums can't replicate.
3. Augmented Reality (AR) Applications
CombiningAR and machine learning for practical use cases like
furniture shopping shows how computer graphics can improve real-
world experiences.
04/04/2025
Chapter One: Introdction to Computer Graphics
22
Types of computer Graphics
 Computer Graphics is broadly classified into two main
categories based on the dimensionality and representation of
the visual content:
1. Based on Dimensionality
a) 2D Graphics (Two-Dimensional Graphics)
 Graphics that are created and manipulated in a two-dimensional
plane (width and height).
 Flat images with no depth.
 Composed of shapes, lines, curves, and text.
 Used for simpler visual representations.
 Example: Icons, logos, and user interface elements. Digital paintings and illustrations. 2D
animations and games.
Application: Web design, mobile apps, and print media.2D animation and
cartoons.
04/04/2025
Chapter One: Introdction to Computer Graphics
23
Cont’d…
 b) 3D Graphics (Three-Dimensional Graphics)
 Definition: Graphics that are created and manipulated in a
three-dimensional space (width, height, and depth).
 Characteristics:
 Objects have volume and depth.
 Realistic lighting, shading, and textures.
 Used for complex and immersive visualizations.
 Examples:
 3D models of characters, environments, and objects.
 3D animations, movies, and video games.
 Virtual reality (VR) and augmented reality (AR).
04/04/2025
Chapter One: Introdction to Computer Graphics
24
Cont’d…
 Techniques:
 Modeling (creating 3D objects).
 Rendering (generating images from 3D models).
 Animation (simulating motion).
 Applications:
 Film and entertainment (e.g., CGI in movies).
 Video games and simulations.
 Architectural visualization and product design.
04/04/2025
Chapter One: Introdction to Computer Graphics
25
2. Based on Representation
a) Raster Graphics
 Images represented as a grid of pixels, where each pixel has
a specific color.
 Characteristics:
 Resolution-dependent (loses quality when scaled up).
 File formats: JPEG, PNG, BMP, GIF.
 Suitable for detailed images like photographs.
 Applications:
 Digital photography.
 Web images and textures.
04/04/2025
Chapter One: Introdction to Computer Graphics
26
Cont’d…
b)Vector Graphics
 Images represented using mathematical equations to define
shapes, lines, and curves.
 Characteristics:
 Resolution-independent (can be scaled without losing quality).
 File formats: SVG,AI, EPS.
 Suitable for logos, icons, and illustrations.
 Applications:
 Graphic design and branding.
 Printing and signage.
04/04/2025
Chapter One: Introdction to Computer Graphics
27
3. Based on Interaction
a) Non-Interactive Graphics (Offline Graphics)
 Graphics that are pre-rendered and do not allow user interaction.
 Examples: Movies, pre-rendered animations, and static images.
 Applications:
 Film production, advertisements, and presentations.
b) Interactive Graphics (Real-Time Graphics)
 Graphics that are rendered in real-time and allow user
interaction.
 Examples:Video games, simulations, and interactive applications.
 Applications: Gaming, virtual reality, and training simulations.
04/04/2025
Chapter One: Introdction to Computer Graphics
28
4. Based on Purpose
a) Artistic Graphics
 Focus on creativity and aesthetics.
 Examples: Digital art, animations, and visual effects.
 b) Scientific andTechnical Graphics
 Focus on accuracy and visualization of data.
 Examples: Medical imaging, scientific simulations, and
engineering designs.
04/04/2025
Chapter One: Introdction to Computer Graphics
29
Cont’d…
04/04/2025
Chapter One: Introdction to Computer Graphics
30
Interactive Computer Graphics
 The Interactive computer graphics (ICG) provides two way
communications between the computer and the user.
 The various applications of ICG are as follows.
 Using ICG system the integrated electronic circuits which are
very complex can be drawn in a much shorter time.
 It is very useful in training of the pilots as they spend much of
their training on the ground at the controls of a flight simulator
and not in a real aircraft.
 There are many tasks that can be made easier & less expensive
by the use of ICG. The effectiveness of the ICG is the speed with
which the user can absorb the displayed information.
Contd..
 The Interactive Graphics display consists of three major components as
follows & shown in Figure 1:
(1) Frame Buffer (2) T.V. Monitor (3)Display Controller
10001101
01101010
00101001
11100111
00111000
01010100
00111001
01010101
Display Adapter/
Display Controller
Frame Buffer
Video Monitor/
T. V. Monitor
Scan line Data
Contd..
1) Frame Buffer
 The images that are to be displayed are stored in a frame buffer in the form
of matrix of intensity values.
 The frame buffer contains the image stored in binary form as a matrix of
0’s and 1’s which represent the pixel. 0 indicates the darkness and 1
indicates the image.
 The Frame Buffer holds the set of intensity values for all the screen
points.
 The intensity values stored in a Frame Buffer are retrieved and painted on a
screen one row at a time. This row is called as scan line.
2) Display Controller
 The Display Controller passes the contents of frame buffer to the T.V.
Monitor.
 Display Controller reads successive bytes of data from the frame buffer &
then converts 0’s and 1’s into the corresponding video signal.
 These signals are fed to the T.V. Monitor.
3) T.V. Monitor
 The T.V. Monitor then produces black and white pattern on the screen.
 The frame Buffer contents are to be modified, in order to represent the new
pattern of pixels or if some changes are to be made on the displayed
picture.
Properties of Video Monitor:
1.Persistence: Persistence is the duration of
phosphorescence. Different kinds of phosphors are
available for use in CRT. Besides color, a major
difference between phosphor in their persistence how
they continue to emit light after the electron beam is
removed.
2. Resolution: Use to describe the number of pixels that
are used on display image.
3. Aspect Ratio: It is the ratio of width to its height. Its
measure is unit in length or number of pixels.
Non-Interactive / Passive Computer
Graphics
 In non-interactive computer graphics, the picture is
produced on the monitor, and the user does not have any
controlled over the image, i.e., the user cannot make any
change in the rendered image.
One example of its Titles shown on T.V.
 Non-interactive Graphics involves only one-way
communication between the computer and the user, User
can see the produced image, and he cannot make any
change in the image.
GRAPHICS AREAS
The following major areas of computer graphics are:
 Modeling deals with the mathematical specification of
shape and appearance properties in a way that can be
stored on the computer. For example, a coffee mug might
be described as a set of ordered 3D points along with some
interpolation rule to connect the points and a reflection
model that describes how light interacts with the mug.
 Rendering is a term inherited from art and deals with the
creation of shaded images from 3D computer models.
 Animation is a technique to create an illusion of motion
through sequences of images. Animation uses modeling
and rendering but adds the key issue of movement over
time, which is not usually dealt with in basic modeling and
rendering.
Contd..
There are many other areas that involve computer graphics.
 User interaction deals with the interface between input devices such as
mice and tablets, the application, feedback to the user in imagery, and
other sensory feedback.
 Virtual reality attempts to immerse the user into a 3D virtual world.
This typically requires at least stereo graphics and response to head
motion. For true virtual reality, sound and force feedback should be
provided as well.
 Visualization attempts to give users insight into complex information
via visual display.
 Image processing deals with the manipulation of 2D images and is
used in both the fields of graphics and vision.
 3D scanning uses range-finding technology to create measured 3D
models. Such models are useful for creating rich visual imagery, and
the processing of such models often requires graphics algorithms.
 Computational photography is the use of computer graphics,
computer vision, and image processing methods to enable new ways of
photographically capturing objects, scenes, and environments.
Application of Computer Graphics
Almost any field can make some use of computer
graphics, but the major consumers of computer
graphics technology include the following
industries:
 Video games increasingly use sophisticated 3D
models and rendering algorithms.
 Cartoons are often rendered directly from 3D
models. Many traditional 2D cartoons use
backgrounds rendered from 3D models, which
allows a continuously moving viewpoint without
huge amounts of artist time.
04/04/2025
Chapter One: Introdction to Computer Graphics
38
Cont’d…
 Visual effects use almost all types of computer graphics
technology. Almost every modern film uses digital
compositing to superimpose backgrounds with separately
filmed foregrounds. Many films also use 3D modeling and
animation to create synthetic environments, objects, and even
characters that most viewers will never suspect are not real.
 Animated films use many of the same techniques that are
used for visual effects, but without necessarily aiming for
images that look real.
 CAD/CAM stands for computer-aided design and computer-
aided manufacturing. These fields use computer technology to
design parts and products on the computer and then, using
these virtual designs, to guide the manufacturing process. For
example, many mechanical parts are designed in a 3D
computer modeling package and then automatically produced
on a computer-controlled milling device.
04/04/2025
Chapter One: Introdction to Computer Graphics
39
Cont’d…
 Simulation can be thought of as accurate video gaming.
 For example, a flight simulator uses sophisticated 3D
graphics to simulate the experience of flying an airplane.
 Such simulations can be extremely useful for initial training
in safety-critical domains such as driving, and for scenario
training for experienced users such as specific fire-fighting
situations that are too costly or dangerous to create
physically.
04/04/2025
Chapter One: Introdction to Computer Graphics
40
Cont’d…
 Medical imaging creates meaningful images of scanned patient data. For
example, a computed tomography (CT) dataset is composed of a large 3D
rectangular array of density values. Computer graphics is used to create
shaded images that help doctors extract the most salient information from
such data.
 Information visualization creates images of data that do not necessarily
have a “natural” visual depiction. For example, the temporal trend of the
price of ten different stocks does not have an obvious visual depiction, but
clever graphing techniques can help humans see the patterns in such data.
 Presentation graphics: In applications like summarizing of data of
financial, statistical, mathematical, scientific and economic research
reports, presentation graphics are used. It increases the understanding
using visual tools like bar charts, line graphs, pie charts and other displays.
04/04/2025
Chapter One: Introdction to Computer Graphics
41
Representation of Graphics
 There are different formats used for storing a picture in a
computer; but, unlike text and data files, which are
primarily made up of alphanumeric characters, graphics
formats are more complex.
 Two major categories of graphics formats are vector
graphics (objects made up of lines) and bitmapped graphics
(TV-like dots).
 Images stored in vector format can be moved to another
vector system typically without loss of resolution. There are
2D vector formats as well as 3D vector formats.
 During transfer of raster images among different devices,
resolution is a major concern. Such transfers can occur
without loss of resolution as long as the new format supports
the same or is of higher resolution to the old one.
Cont’d…
 Standard graphics formats allow images to be moved from
machine to machine, while standard graphics languages let
graphics programs be moved from machine to machine.
 For example, GKS, PHIGS and OpenGL are major graphics
languages that have been adopted by high-performance
workstation and CAD vendors. GDI and DirectX are the
graphics languages inWindows.
 High-resolution graphics is typically expensive to implement
due to its large storage and fast processing requirements.
However, as desktop computers become more powerful,
graphics have become widely used in every application.
Raster Scan Displays
 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 a memory area called the
refresh buffer or frame buffer used for redrawn
Cont’d…
 Each screen point is referred to as a pixel or pel (picture
element).
 Intensity range for pixel positions depends on the capability
of the raster system.
 In a B&W system, each screen point is either on or off. So
only one bit is needed.
 The frame buffer in B&W system is called as bitmap. For
multi-color systems the frame buffer is called as pixmap.
 Refreshing on raster-scan displays is carried out at the rate
of 60 to 80 frames per second. The unit for refreshing rate
is Hertz (Hz).
Cont’d…
Random-Scan Displays
 The CRT has the electron beam directed only to the parts of
the screen where a picture is to be drawn.
 Random-scan monitors draw a picture one line at a time,
called as vector display.
 Refresh rates on a ransom-scan system depends on the
number of lines to be displayed.
 Picture definition is stored as a set of line-drawing
commands in the refresh display file or refresh buffer.
 To display a specified picture, the system cycles through
the set of commands in the display file, drawing each
component line.
 These systems are designed for the line-drawing
applications and can’t display realistic shaded scenes.
Cont’d…
Cont’d…
Cont’d…
GPU for Computer Graphics
 A GPU (Graphics Processing Unit) is a specialized electronic circuit
designed to rapidly manipulate and alter memory to accelerate the
creation of images in a frame buffer intended for output to a display
device.
 GPUs are used in embedded systems, mobile phones, personal
computers, workstations, and game consoles.
 Modern GPUs are very efficient at manipulating computer graphics
and image processing, and their highly parallel structure makes them
more effective than general-purpose CPUs for algorithms where
processing of large blocks of data is done in parallel.
 In the context of computer graphics, GPUs are used for rendering
images, animations, and video for the computer's screen. This includes
both 2D and 3D graphics rendering.
04/04/2025
Chapter One: Introdction to Computer Graphics
51
DISPLAY TECHNOLOGIES
Cathode Ray Tube (CRT)
 The most common graphics output device is the video
monitor which is based on the standard cathode ray tube
(CRT) design. Figure 4 illustrates the basic operation of a
CRT.
Figure 4: Cathode Ray Tube (CRT)
Contd..
 As shown in above figure, it consists of electron gun, focusing
system, deflection plates and a phosphor-coated screen.
 Electron gun is the primary component of a CRT. When the heat
is supplied to the electron gun by directing a current, a beam of
electrons emitted by an electron gun, passes through focusing
and deflection systems that direct the beam toward specified
positions on the phosphor-coated screen.
 The focusing system in a CRT is needed to force the electron
beam to converge into a small spot as it strikes the phosphor.
 There are two pairs of deflection plates - Horizontal deflection
plates and vertical deflection plates.
 One pair of plates is mounted horizontally to control the vertical
deflection, and the other pair is mounted vertically to control
horizontal deflection.
Contd..
 The beam passes between the two pairs of deflection
plates and positioned on the screen.
 The phosphor then emits a small spot of light at each
position contacted by the electron beam.
 Because the light emitted by the phosphor fades very
rapidly, some method is needed for maintaining the
screen picture.
 One Way to keep the phosphor glowing is to redraw the
picture repeatedly by quickly directing the electron beam
back over the same points. This type of display is called a
refresh CRT.
 In CRT monitors there are two techniques of displaying
images:
Raster scan displays
Random scan displays
Raster Scan Displays
Figure 5: Raster Scan Display
Figure 6: Horizontal and Vertical
Retrace
Raster Scan Systems
Figure 7: Architecture of a simple raster system
Contd..
Figure 8: Architecture of a raster system
Raster Scan Display Processor
 Figure 9 shows one way to set up the
organization of a raster system containing
a separate display processor, sometimes
referred to as a graphics controller or a
display coprocessor.
Figure 9: Architecture of a raster-graphics system with a
display processor
Random Scan Display/ Vector-
Scan Display/ Calligraphic
Displays
Figure 10: Random Scan Display
Random-Scan Systems/ Random-Scan Display
Processor
Figure 11: Architecture of a simple random scan system
How CRT works?
Cont’d…
 Techniques used to produce image in CRT:
 1.Vector Scan /Random Scan Display
 2. Raster Scan Display
1. Vector Scan /Random Scan Display
Cont’d…
Raster Scan Display
Cont’d…
Cont’d…
Cont’d…
Cont’d…
Difference between Random Scan
and Raster Scan
Cont’d…
3D Viewing Devices
Cont’d…
Applications of 3D viewing Devices
Stereoscopic and Virtual Reality
Systems
 Stereoscopic Systems
Virtual Reality
Cont’d…
Raster Graphics System
Cont’d…
Graphic Input Devices
Summary
 Computer graphics is the study of generating and manipulating
images using computers.
 In CG, we create, process and manipulate models of real world
objects
 It’s used in various engineering and scientific fields for
visualization, simulation and problem solving
 Interactive computer graphics is in which a user controls
appearance of graphics using a control mechanism (using some
input mechanism)
 The images in computer can be constructed by manipulating
points, lines and simple shapes
 Generally vectors
Syllabus
 Vector andVector Manipulations
 Representing points and vectors in computer
program
 Graphics Pipeline and OpenGL
 How the image drawing process goes and the library
that helps us to implement the process
 Drawing with OpenGL
 Applying translation, scaling and rotation to an
object
 Vector Geometry
 Constructing lines and planes, calculating distances
and angles
Syllabus
 Transformation
 Applying translation, scaling and rotation to
an object
 Viewing and Camera
 Viewing objects from many position and
perspectives
 Lighting
 Images are all about light and we will see
implementation of light here
 Curves and Surfaces
 Drawing curved surfaces
Syllabus - Programming
 Computer graphics is combination of Math and
Programming
 Mostly the Math is Linear Algebra
 OpenGL 3.0 or greater will be used as Graphics Library
 We will be implementing using Python 2.7
 What we will not learn
 Game Engines like Unity and PyGame
 3DS Max or Blender
 Aftereffect or other Graphics Software
Syllabus – Reading
 We will not have a single book, instead we will use many books,
websites, tutorials
 Books
 Learn OpenGL - An offline transcript of learnopengl.com Joey deVries
 OpenGL Programming 8th Edition by Dave Shreiner,Graham Sellers,
John Kessenich,Bill Licea-Kane
 Mathematical Structures for Computer Graphics by Steven J.Janke
 Computer GraphicsThrough OpenGL by Sumantah Guha
 NumPyTutorial
Syllabus – Issues
 Sadly all books and other materials are written with C++
developers in mind 
 Don’t Panic
 OpenGL Library uses “python wrapper” which has exactly same
functions, classes, variables and programming methodology for
python just like the C++ ones
 It shouldn’t be that hard to read the C++ code by now, thanks to
Java 
 It shouldn’t be that hard to change C++ code to Python 
Syllabus – Issues
OpenGL C++ vs Python
void display(){
glClearColor(0.0f, 1.0f, 0.0f, 1.0f);
glClear(GL_COLOR_BUFFER_BIT);
glBegin(GL_QUADS);
glEnd();
glFlush();
}
int main(int argc, char ** argv){
glutInit(&argc, argv);
glutCreateWindow("OpenGL");
glutInitWindowSize(320, 320);
glutInitWindowPosition(50, 50);
glutDisplayFunc(display);
glutMainLoop();
return 0;
}
def init():
pygame.init()
display = (500, 500)
pygame.display.set_mode(display,
DOUBLEBUF|OPENGL)
glClearColor(0.0, 0.0, 0.0, 1.0)
gluOrtho2D(-1.0, 1.0, -1.0, 1.0)
def draw():
glClear(GL_COLOR_BUFFER_BIT)
glColor3f(1.0, 0.0, 0.0)
glBegin(GL_POINTS)
glVertex2f(0.0, 0.0)
glEnd()
glFlush()

Chapter One-Introduction to Computer Graphics.pdf

  • 1.
    04/04/2025 Chapter One: Introdctionto Computer Graphics 1 College of Natural and Computational Sciences Department of Computer Science Course Title : Computer Graphics Chapter One: Introduction to Computer Graphics
  • 2.
    Outline  Introduction  Whatis Computer Graphics?  Why Computer Graphics?  Motivation for Computer Graphics  Steps in Computer Graphics  Some cool projects in Computer Graphics  Application of Computer Graphics  Representation of Computer Graphics 04/04/2025 Chapter One: Introdction to Computer Graphics 2
  • 3.
    Introduction Computer is informationprocessing machine. User needs to communicate with computer and the computer graphics is one of the most effective and commonly used ways of communication with the user Computer Graphics(CG) displays the information in the forma of graphical object such as pictures, charts, diagram and graphs. Graphical objects convey more information in less time and easily understandable formats for example statically graph shown in stock exchange. Generally Computer graphics is the computational creation and manipulation of visual data.  04/04/2025 Chapter One: Introdction to Computer Graphics 3
  • 4.
    Cont’d…  The fieldof computer graphics has evolved significantly over the years, and today, it plays a vital role in entertainment, communication, design, education, and more.  At its core, computer graphics involves creating images from data through processes like rendering, modeling, and simulation.  Overall, computer graphics is an interdisciplinary field that continues to drive advancements in technology and creativity, pushing the boundaries of visual experiences. 04/04/2025 Chapter One: Introdction to Computer Graphics 4
  • 5.
     In today’sdigital era, computer graphics technologies have revolutionized how we perceive and interact with visual information, playing a pivotal role in video games, movies, architectural design, medical imaging, and more.  There are several tools used for the implementation of Computer Graphics.  The basic is the graphics.h header file in Turbo-C, Unity for advanced, and even OpenGL can be used for its Implementation. 04/04/2025 Chapter One: Introdction to Computer Graphics 5
  • 6.
    What is ComputerGraphics?  Computer graphics generally means creation, storage and manipulation of models and images using Computers  Models are representation of a real world object in the computer  Such models come from diverse and expanding set of fields including physical, biological, mathematical, artistic, and conceptual/abstract structures 04/04/2025 Chapter One: Introdction to Computer Graphics 6
  • 7.
     CG isin daily use in the field of science, engineering, medicine, entertainment, advertising, the graphic arts, the fine arts, business, education etc.  The electronic industry is more dependent on the technologies provided by CG such as engineers can draw their circuit in a much shorter time,  architects can have alternative solution to design problems,  the molecular biologist can display pictures of molecules and can study on the structure,  the town planners and transportation engineers use the computer generated maps which display data useful to them in their planning work etc. 04/04/2025 Chapter One: Introdction to Computer Graphics 7
  • 8.
    Cont’d…  Computer graphicsis an art of drawing pictures on computer screens with the help of programming.  It involves computations, creation, and manipulation of data.  In other words, we can say that computer graphics is a rendering tool for the generation and manipulation of images.  Computer Graphics image is made up of number of Pixels.  Pixel is the smallest addressable graphical unit represented on computer screen. 04/04/2025 Chapter One: Introdction to Computer Graphics 8
  • 9.
    Why Computer Graphics Understanding and interpreting information: Visualization is necessary for dealing with complex data.  Improved communication with computers: Graphical and audio interfaces are helpful.  Better product designs: Designers can explore more avenues in less time and can focus on the creative aspects of design (which do not include drafting).  More economical designs: Design databases can be "tested" electronically, reducing dependence on complex and costly physical modes (e.g. aircraft).  Better products: Design databases can be transmitted to robots for manufacturing (3-D output). 04/04/2025 Chapter One: Introdction to Computer Graphics 9
  • 10.
    Motivation for ComputerGraphics  Many engineering and scientific fields require visualization to help people easily understand the problem in their domain It is better to see 3DView of a building than a simple 2D sketch
  • 11.
    Cont’d…  We wantto have vivid imagination of things that we couldn’t possibly see directly
  • 12.
    Cont’d…  We wantto have vivid imagination of things that we couldn’t possibly see directly
  • 13.
    Cont’d…  We wantimaginary characters in entertainment to create different experience and feeling
  • 14.
    Steps in ComputerGraphics  Computer graphics involves a series of steps to create, manipulate, and display visual content.  These steps form a pipeline that transforms raw data into a final image or animation.  This pipeline is the foundation of computer graphics, whether for creating static images, animations, or interactive applications. 04/04/2025 Chapter One: Introdction to Computer Graphics 14
  • 15.
    Cont’d…  Each stepcan vary in complexity depending on the desired level of realism and performance.  Computer graphics works by combining mathematical models, algorithms, and hardware to create and manipulate visual content.  It is a multidisciplinary field that continues to evolve with advancements in technology and creativity. 04/04/2025 Chapter One: Introdction to Computer Graphics 15
  • 16.
    Cont’d…  The stepsin computer graphics includes: 1.Modeling: Create 3D objects. 2.Transformation: Position and orient objects. 3.Lighting: Simulate light interactions. 4.Viewing and Projection: Convert 3D to 2D. 5.Rasterization: Convert shapes to pixels. 6.Shading and Texturing: Add surface details. 7.Rendering: Generate the final image. 8.Post-Processing: Enhance the image. 9.Display: Show the image to the user. 10.Interaction: Enable real-time updates (if applicable). 04/04/2025 Chapter One: Introdction to Computer Graphics 16
  • 17.
    Computer Graphics asInterdecipline  Computer graphics is inherently interdisciplinary because it blends multiple fields of study to create the complex visual systems and imagery we interact with today.  Here are some key disciplines that intersect with computer graphics: 1. Computer Science:  This is the foundation of computer graphics, providing algorithms, data structures, and computational techniques for rendering, animation, and image processing.  Topics like graphics programming, hardware acceleration (e.g., using GPUs), and rendering algorithms are deeply rooted in computer science. 04/04/2025 Chapter One: Introdction to Computer Graphics 17
  • 18.
    Cont’d… 2. Mathematics: Computergraphics relies heavily on mathematics, especially geometry, linear algebra, and calculus. Understanding 3D transformations, vector spaces, matrix operations, and trigonometry is crucial for manipulating shapes, performing animations, and rendering realistic images. 3. Physics: In graphics, physics helps simulate real-world behaviors, such as lighting, shadows, textures, and motion. Concepts from physics, such as ray tracing, reflections, refraction, and fluid dynamics, are key to creating realistic environments and animations. 04/04/2025 Chapter One: Introdction to Computer Graphics 18
  • 19.
    Cont’d… 4.Art and Design:Computer graphics is also tied to the artistic and design aspects of visual representation. Knowledge of color theory, composition, texture mapping, and user interface (UI) design is crucial for creating aesthetically pleasing and functional visual content. 5. Psychology: Understanding how humans perceive visual information is important for designing graphics that communicate effectively. Concepts like visual perception, color psychology, and attention theories guide how graphics are presented to users to evoke desired reactions or behaviors. 6. Engineering: Hardware and software engineering play a key role in computer graphics, especially in terms of developing efficient algorithms, optimizing performance for rendering, and building graphics hardware like GPUs (Graphics Processing Units) that drive real-time rendering and gaming. 04/04/2025 Chapter One: Introdction to Computer Graphics 19
  • 20.
    Cont’d… 7.Human-Computer Interaction (HCI):In this area, the focus is on how people interact with graphical interfaces and virtual environments. Knowledge from HCI helps improve the usability and accessibility of graphics, ensuring that users can navigate digital environments easily and intuitively. 8.Animation and Film Studies: Graphics often intersect with animation techniques and cinematic storytelling, requiring an understanding of motion, timing, narrative structures, and special effects to create compelling animated sequences or visual effects in movies. 04/04/2025 Chapter One: Introdction to Computer Graphics 20
  • 21.
    Cont’d… 9.Artificial Intelligence (AI):AI is used in computer graphics for tasks such as procedural content generation, facial recognition, motion capture, and deep learning techniques applied to image recognition and enhancement. 10. Geographic Information Systems (GIS): Graphics are also used in geospatial data visualization, mapping, and simulations. Here, spatial analysis and visual representation techniques from graphics are used to interpret and display large datasets like topographical maps or satellite imagery. 04/04/2025 Chapter One: Introdction to Computer Graphics 21
  • 22.
    Some cool projectsin Computer Graphics  Computer graphics is a broad and exciting field with many creative and technically challenging projects. Here are some cool examples of computer graphics projects that demonstrate the diversity and impact of this area: 1. Photorealistic Rendering (RayTracing) -Achieving photorealistic images of virtual environments and objects is both technically challenging and visually stunning. 2. 3D Modeling forVirtual Reality (VR) - The ability to "paint" in a 3D space gives users a unique artistic experience that traditional 2D mediums can't replicate. 3. Augmented Reality (AR) Applications CombiningAR and machine learning for practical use cases like furniture shopping shows how computer graphics can improve real- world experiences. 04/04/2025 Chapter One: Introdction to Computer Graphics 22
  • 23.
    Types of computerGraphics  Computer Graphics is broadly classified into two main categories based on the dimensionality and representation of the visual content: 1. Based on Dimensionality a) 2D Graphics (Two-Dimensional Graphics)  Graphics that are created and manipulated in a two-dimensional plane (width and height).  Flat images with no depth.  Composed of shapes, lines, curves, and text.  Used for simpler visual representations.  Example: Icons, logos, and user interface elements. Digital paintings and illustrations. 2D animations and games. Application: Web design, mobile apps, and print media.2D animation and cartoons. 04/04/2025 Chapter One: Introdction to Computer Graphics 23
  • 24.
    Cont’d…  b) 3DGraphics (Three-Dimensional Graphics)  Definition: Graphics that are created and manipulated in a three-dimensional space (width, height, and depth).  Characteristics:  Objects have volume and depth.  Realistic lighting, shading, and textures.  Used for complex and immersive visualizations.  Examples:  3D models of characters, environments, and objects.  3D animations, movies, and video games.  Virtual reality (VR) and augmented reality (AR). 04/04/2025 Chapter One: Introdction to Computer Graphics 24
  • 25.
    Cont’d…  Techniques:  Modeling(creating 3D objects).  Rendering (generating images from 3D models).  Animation (simulating motion).  Applications:  Film and entertainment (e.g., CGI in movies).  Video games and simulations.  Architectural visualization and product design. 04/04/2025 Chapter One: Introdction to Computer Graphics 25
  • 26.
    2. Based onRepresentation a) Raster Graphics  Images represented as a grid of pixels, where each pixel has a specific color.  Characteristics:  Resolution-dependent (loses quality when scaled up).  File formats: JPEG, PNG, BMP, GIF.  Suitable for detailed images like photographs.  Applications:  Digital photography.  Web images and textures. 04/04/2025 Chapter One: Introdction to Computer Graphics 26
  • 27.
    Cont’d… b)Vector Graphics  Imagesrepresented using mathematical equations to define shapes, lines, and curves.  Characteristics:  Resolution-independent (can be scaled without losing quality).  File formats: SVG,AI, EPS.  Suitable for logos, icons, and illustrations.  Applications:  Graphic design and branding.  Printing and signage. 04/04/2025 Chapter One: Introdction to Computer Graphics 27
  • 28.
    3. Based onInteraction a) Non-Interactive Graphics (Offline Graphics)  Graphics that are pre-rendered and do not allow user interaction.  Examples: Movies, pre-rendered animations, and static images.  Applications:  Film production, advertisements, and presentations. b) Interactive Graphics (Real-Time Graphics)  Graphics that are rendered in real-time and allow user interaction.  Examples:Video games, simulations, and interactive applications.  Applications: Gaming, virtual reality, and training simulations. 04/04/2025 Chapter One: Introdction to Computer Graphics 28
  • 29.
    4. Based onPurpose a) Artistic Graphics  Focus on creativity and aesthetics.  Examples: Digital art, animations, and visual effects.  b) Scientific andTechnical Graphics  Focus on accuracy and visualization of data.  Examples: Medical imaging, scientific simulations, and engineering designs. 04/04/2025 Chapter One: Introdction to Computer Graphics 29
  • 30.
  • 31.
    Interactive Computer Graphics The Interactive computer graphics (ICG) provides two way communications between the computer and the user.  The various applications of ICG are as follows.  Using ICG system the integrated electronic circuits which are very complex can be drawn in a much shorter time.  It is very useful in training of the pilots as they spend much of their training on the ground at the controls of a flight simulator and not in a real aircraft.  There are many tasks that can be made easier & less expensive by the use of ICG. The effectiveness of the ICG is the speed with which the user can absorb the displayed information.
  • 32.
    Contd..  The InteractiveGraphics display consists of three major components as follows & shown in Figure 1: (1) Frame Buffer (2) T.V. Monitor (3)Display Controller 10001101 01101010 00101001 11100111 00111000 01010100 00111001 01010101 Display Adapter/ Display Controller Frame Buffer Video Monitor/ T. V. Monitor Scan line Data
  • 33.
    Contd.. 1) Frame Buffer The images that are to be displayed are stored in a frame buffer in the form of matrix of intensity values.  The frame buffer contains the image stored in binary form as a matrix of 0’s and 1’s which represent the pixel. 0 indicates the darkness and 1 indicates the image.  The Frame Buffer holds the set of intensity values for all the screen points.  The intensity values stored in a Frame Buffer are retrieved and painted on a screen one row at a time. This row is called as scan line. 2) Display Controller  The Display Controller passes the contents of frame buffer to the T.V. Monitor.  Display Controller reads successive bytes of data from the frame buffer & then converts 0’s and 1’s into the corresponding video signal.  These signals are fed to the T.V. Monitor. 3) T.V. Monitor  The T.V. Monitor then produces black and white pattern on the screen.  The frame Buffer contents are to be modified, in order to represent the new pattern of pixels or if some changes are to be made on the displayed picture.
  • 34.
    Properties of VideoMonitor: 1.Persistence: Persistence is the duration of phosphorescence. Different kinds of phosphors are available for use in CRT. Besides color, a major difference between phosphor in their persistence how they continue to emit light after the electron beam is removed. 2. Resolution: Use to describe the number of pixels that are used on display image. 3. Aspect Ratio: It is the ratio of width to its height. Its measure is unit in length or number of pixels.
  • 35.
    Non-Interactive / PassiveComputer Graphics  In non-interactive computer graphics, the picture is produced on the monitor, and the user does not have any controlled over the image, i.e., the user cannot make any change in the rendered image. One example of its Titles shown on T.V.  Non-interactive Graphics involves only one-way communication between the computer and the user, User can see the produced image, and he cannot make any change in the image.
  • 36.
    GRAPHICS AREAS The followingmajor areas of computer graphics are:  Modeling deals with the mathematical specification of shape and appearance properties in a way that can be stored on the computer. For example, a coffee mug might be described as a set of ordered 3D points along with some interpolation rule to connect the points and a reflection model that describes how light interacts with the mug.  Rendering is a term inherited from art and deals with the creation of shaded images from 3D computer models.  Animation is a technique to create an illusion of motion through sequences of images. Animation uses modeling and rendering but adds the key issue of movement over time, which is not usually dealt with in basic modeling and rendering.
  • 37.
    Contd.. There are manyother areas that involve computer graphics.  User interaction deals with the interface between input devices such as mice and tablets, the application, feedback to the user in imagery, and other sensory feedback.  Virtual reality attempts to immerse the user into a 3D virtual world. This typically requires at least stereo graphics and response to head motion. For true virtual reality, sound and force feedback should be provided as well.  Visualization attempts to give users insight into complex information via visual display.  Image processing deals with the manipulation of 2D images and is used in both the fields of graphics and vision.  3D scanning uses range-finding technology to create measured 3D models. Such models are useful for creating rich visual imagery, and the processing of such models often requires graphics algorithms.  Computational photography is the use of computer graphics, computer vision, and image processing methods to enable new ways of photographically capturing objects, scenes, and environments.
  • 38.
    Application of ComputerGraphics Almost any field can make some use of computer graphics, but the major consumers of computer graphics technology include the following industries:  Video games increasingly use sophisticated 3D models and rendering algorithms.  Cartoons are often rendered directly from 3D models. Many traditional 2D cartoons use backgrounds rendered from 3D models, which allows a continuously moving viewpoint without huge amounts of artist time. 04/04/2025 Chapter One: Introdction to Computer Graphics 38
  • 39.
    Cont’d…  Visual effectsuse almost all types of computer graphics technology. Almost every modern film uses digital compositing to superimpose backgrounds with separately filmed foregrounds. Many films also use 3D modeling and animation to create synthetic environments, objects, and even characters that most viewers will never suspect are not real.  Animated films use many of the same techniques that are used for visual effects, but without necessarily aiming for images that look real.  CAD/CAM stands for computer-aided design and computer- aided manufacturing. These fields use computer technology to design parts and products on the computer and then, using these virtual designs, to guide the manufacturing process. For example, many mechanical parts are designed in a 3D computer modeling package and then automatically produced on a computer-controlled milling device. 04/04/2025 Chapter One: Introdction to Computer Graphics 39
  • 40.
    Cont’d…  Simulation canbe thought of as accurate video gaming.  For example, a flight simulator uses sophisticated 3D graphics to simulate the experience of flying an airplane.  Such simulations can be extremely useful for initial training in safety-critical domains such as driving, and for scenario training for experienced users such as specific fire-fighting situations that are too costly or dangerous to create physically. 04/04/2025 Chapter One: Introdction to Computer Graphics 40
  • 41.
    Cont’d…  Medical imagingcreates meaningful images of scanned patient data. For example, a computed tomography (CT) dataset is composed of a large 3D rectangular array of density values. Computer graphics is used to create shaded images that help doctors extract the most salient information from such data.  Information visualization creates images of data that do not necessarily have a “natural” visual depiction. For example, the temporal trend of the price of ten different stocks does not have an obvious visual depiction, but clever graphing techniques can help humans see the patterns in such data.  Presentation graphics: In applications like summarizing of data of financial, statistical, mathematical, scientific and economic research reports, presentation graphics are used. It increases the understanding using visual tools like bar charts, line graphs, pie charts and other displays. 04/04/2025 Chapter One: Introdction to Computer Graphics 41
  • 42.
    Representation of Graphics There are different formats used for storing a picture in a computer; but, unlike text and data files, which are primarily made up of alphanumeric characters, graphics formats are more complex.  Two major categories of graphics formats are vector graphics (objects made up of lines) and bitmapped graphics (TV-like dots).  Images stored in vector format can be moved to another vector system typically without loss of resolution. There are 2D vector formats as well as 3D vector formats.  During transfer of raster images among different devices, resolution is a major concern. Such transfers can occur without loss of resolution as long as the new format supports the same or is of higher resolution to the old one.
  • 43.
    Cont’d…  Standard graphicsformats allow images to be moved from machine to machine, while standard graphics languages let graphics programs be moved from machine to machine.  For example, GKS, PHIGS and OpenGL are major graphics languages that have been adopted by high-performance workstation and CAD vendors. GDI and DirectX are the graphics languages inWindows.  High-resolution graphics is typically expensive to implement due to its large storage and fast processing requirements. However, as desktop computers become more powerful, graphics have become widely used in every application.
  • 44.
    Raster Scan Displays 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 a memory area called the refresh buffer or frame buffer used for redrawn
  • 45.
    Cont’d…  Each screenpoint is referred to as a pixel or pel (picture element).  Intensity range for pixel positions depends on the capability of the raster system.  In a B&W system, each screen point is either on or off. So only one bit is needed.  The frame buffer in B&W system is called as bitmap. For multi-color systems the frame buffer is called as pixmap.  Refreshing on raster-scan displays is carried out at the rate of 60 to 80 frames per second. The unit for refreshing rate is Hertz (Hz).
  • 46.
  • 47.
    Random-Scan Displays  TheCRT has the electron beam directed only to the parts of the screen where a picture is to be drawn.  Random-scan monitors draw a picture one line at a time, called as vector display.  Refresh rates on a ransom-scan system depends on the number of lines to be displayed.  Picture definition is stored as a set of line-drawing commands in the refresh display file or refresh buffer.  To display a specified picture, the system cycles through the set of commands in the display file, drawing each component line.  These systems are designed for the line-drawing applications and can’t display realistic shaded scenes.
  • 48.
  • 49.
  • 50.
  • 51.
    GPU for ComputerGraphics  A GPU (Graphics Processing Unit) is a specialized electronic circuit designed to rapidly manipulate and alter memory to accelerate the creation of images in a frame buffer intended for output to a display device.  GPUs are used in embedded systems, mobile phones, personal computers, workstations, and game consoles.  Modern GPUs are very efficient at manipulating computer graphics and image processing, and their highly parallel structure makes them more effective than general-purpose CPUs for algorithms where processing of large blocks of data is done in parallel.  In the context of computer graphics, GPUs are used for rendering images, animations, and video for the computer's screen. This includes both 2D and 3D graphics rendering. 04/04/2025 Chapter One: Introdction to Computer Graphics 51
  • 52.
  • 53.
    Cathode Ray Tube(CRT)  The most common graphics output device is the video monitor which is based on the standard cathode ray tube (CRT) design. Figure 4 illustrates the basic operation of a CRT. Figure 4: Cathode Ray Tube (CRT)
  • 54.
    Contd..  As shownin above figure, it consists of electron gun, focusing system, deflection plates and a phosphor-coated screen.  Electron gun is the primary component of a CRT. When the heat is supplied to the electron gun by directing a current, a beam of electrons emitted by an electron gun, passes through focusing and deflection systems that direct the beam toward specified positions on the phosphor-coated screen.  The focusing system in a CRT is needed to force the electron beam to converge into a small spot as it strikes the phosphor.  There are two pairs of deflection plates - Horizontal deflection plates and vertical deflection plates.  One pair of plates is mounted horizontally to control the vertical deflection, and the other pair is mounted vertically to control horizontal deflection.
  • 55.
    Contd..  The beampasses between the two pairs of deflection plates and positioned on the screen.  The phosphor then emits a small spot of light at each position contacted by the electron beam.  Because the light emitted by the phosphor fades very rapidly, some method is needed for maintaining the screen picture.  One Way to keep the phosphor glowing is to redraw the picture repeatedly by quickly directing the electron beam back over the same points. This type of display is called a refresh CRT.  In CRT monitors there are two techniques of displaying images: Raster scan displays Random scan displays
  • 56.
    Raster Scan Displays Figure5: Raster Scan Display Figure 6: Horizontal and Vertical Retrace
  • 57.
    Raster Scan Systems Figure7: Architecture of a simple raster system
  • 58.
  • 59.
    Raster Scan DisplayProcessor  Figure 9 shows one way to set up the organization of a raster system containing a separate display processor, sometimes referred to as a graphics controller or a display coprocessor. Figure 9: Architecture of a raster-graphics system with a display processor
  • 60.
    Random Scan Display/Vector- Scan Display/ Calligraphic Displays Figure 10: Random Scan Display
  • 61.
    Random-Scan Systems/ Random-ScanDisplay Processor Figure 11: Architecture of a simple random scan system
  • 62.
  • 63.
  • 64.
     Techniques usedto produce image in CRT:  1.Vector Scan /Random Scan Display  2. Raster Scan Display
  • 65.
    1. Vector Scan/Random Scan Display
  • 67.
  • 69.
  • 70.
  • 71.
  • 72.
  • 73.
  • 74.
    Difference between RandomScan and Raster Scan
  • 75.
  • 76.
  • 77.
  • 78.
    Applications of 3Dviewing Devices
  • 79.
    Stereoscopic and VirtualReality Systems  Stereoscopic Systems
  • 82.
  • 83.
  • 84.
  • 88.
  • 89.
  • 91.
    Summary  Computer graphicsis the study of generating and manipulating images using computers.  In CG, we create, process and manipulate models of real world objects  It’s used in various engineering and scientific fields for visualization, simulation and problem solving  Interactive computer graphics is in which a user controls appearance of graphics using a control mechanism (using some input mechanism)  The images in computer can be constructed by manipulating points, lines and simple shapes  Generally vectors
  • 92.
    Syllabus  Vector andVectorManipulations  Representing points and vectors in computer program  Graphics Pipeline and OpenGL  How the image drawing process goes and the library that helps us to implement the process  Drawing with OpenGL  Applying translation, scaling and rotation to an object  Vector Geometry  Constructing lines and planes, calculating distances and angles
  • 93.
    Syllabus  Transformation  Applyingtranslation, scaling and rotation to an object  Viewing and Camera  Viewing objects from many position and perspectives  Lighting  Images are all about light and we will see implementation of light here  Curves and Surfaces  Drawing curved surfaces
  • 94.
    Syllabus - Programming Computer graphics is combination of Math and Programming  Mostly the Math is Linear Algebra  OpenGL 3.0 or greater will be used as Graphics Library  We will be implementing using Python 2.7  What we will not learn  Game Engines like Unity and PyGame  3DS Max or Blender  Aftereffect or other Graphics Software
  • 95.
    Syllabus – Reading We will not have a single book, instead we will use many books, websites, tutorials  Books  Learn OpenGL - An offline transcript of learnopengl.com Joey deVries  OpenGL Programming 8th Edition by Dave Shreiner,Graham Sellers, John Kessenich,Bill Licea-Kane  Mathematical Structures for Computer Graphics by Steven J.Janke  Computer GraphicsThrough OpenGL by Sumantah Guha  NumPyTutorial
  • 96.
    Syllabus – Issues Sadly all books and other materials are written with C++ developers in mind   Don’t Panic  OpenGL Library uses “python wrapper” which has exactly same functions, classes, variables and programming methodology for python just like the C++ ones  It shouldn’t be that hard to read the C++ code by now, thanks to Java   It shouldn’t be that hard to change C++ code to Python 
  • 97.
    Syllabus – Issues OpenGLC++ vs Python void display(){ glClearColor(0.0f, 1.0f, 0.0f, 1.0f); glClear(GL_COLOR_BUFFER_BIT); glBegin(GL_QUADS); glEnd(); glFlush(); } int main(int argc, char ** argv){ glutInit(&argc, argv); glutCreateWindow("OpenGL"); glutInitWindowSize(320, 320); glutInitWindowPosition(50, 50); glutDisplayFunc(display); glutMainLoop(); return 0; } def init(): pygame.init() display = (500, 500) pygame.display.set_mode(display, DOUBLEBUF|OPENGL) glClearColor(0.0, 0.0, 0.0, 1.0) gluOrtho2D(-1.0, 1.0, -1.0, 1.0) def draw(): glClear(GL_COLOR_BUFFER_BIT) glColor3f(1.0, 0.0, 0.0) glBegin(GL_POINTS) glVertex2f(0.0, 0.0) glEnd() glFlush()