Computer Graphics and Image Processing

*Lecturer: Dr N.A. Dodgson*
(`nad@cl.cam.ac.uk`)

*No. of lectures:* 12
*Prerequisite courses: Data Structures and Algorithms, Continuous
Mathematics *(*for the Image Processing part only*)

*This course is a prerequisite for Advanced
Graphics and HCI *(*Part II*)*.*

**Aims**

The aim of the course is to introduce the necessary background, the basic algorithms, and the applications of computer graphics and image processing.

**Lectures**

**Background.**What is an image? What are computer graphics, image processing, and computer vision? How do they relate to one another? Image capture. Image display. Human vision. Resolution and quantisation. Colour and colour spaces. Storage of images in memory, and double buffering. Display devices: the inner workings of CRTs, LCDs, and printers. [3 lectures]**2D Computer graphics.**Drawing a straight line. Drawing circles and ellipses. Cubic curves: specification and drawing. Clipping lines. Filling polygons. Clipping polygons. 2D transformations, vectors and matrices, homogeneous co-ordinates. [3 lectures]**3D Computer graphics.**Projection: orthographic and perspective. 3D transforms and matrices. 3D clipping. 3D curves. 3D scan conversion.*z*-buffer. A-buffer. Ray tracing. Lighting: theory, flat shading, Gouraud, Phong. [4 lectures]**Image processing.**Operations on images: filtering, point processing, compositing. Halftoning and dithering, error diffusion.*If there is time, we will also cover:*Encoding and compression: difference encoding, predictive, run length, transform encoding (including JPEG). [2 lectures]

**Objectives**

At the end of the course students should be able to

- explain the basic function of the human eye and how this
impinges on resolution, quantisation, and colour representation
for digital images;
describe a number of colour spaces and their relative merits;
explain the workings of cathode ray tubes, liquid crystal
displays, and laser printers
- describe and explain the following algorithms: Bresenham's line
drawing, mid-point line drawing, mid-point circle drawing, Bezier
cubic drawing, Douglas and Pucker's line chain simplification,
Cohen-Sutherland line clipping, scanline polygon fill,
Sutherland-Hodgman polygon clipping, depth sort, binary space
partition tree,
*z*-buffer, A-buffer, ray tracing, error diffusion - use matrices and homogeneous coordinates to represent and
perform 2D and 3D transformations;
understand and use 3D to 2D projection, the viewing volume, and
3D clipping
- understand Bezier curves and patches;
understand sampling and super-sampling issues;
understand lighting techniques and how they are applied to both
polygon scan conversion and ray tracing
- explain how to use filters, point processing, and arithmetic
operations in image processing and describe a number of examples of
the use of each; explain how halftoning, ordered dither, and error
diffusion work; understand and be able to explain image compression
and the workings of a number of compression techniques

**Recommended books**

Foley, J.D., van Dam, A., Feiner, S.K. & Hughes, J.F. (1990). *Computer Graphics: Principles and Practice*. Addison-Wesley (2nd
ed.).

Gonzalez, R.C. & Woods, R.E. (1992). *Digital Image
Processing*. Addison-Wesley. [Gonzalez, R.C. & Wintz, P. (1977). *Digital Image Processing* is the earlier edition and is almost as
useful.]