# Overview

The good news is that Computer Graphics is fun: fun to look at, fun to use, and when done properly even fun to program and debug. There are also many fun applications of Computer Graphics, ranging from video games, to animated cartoons, to full length feature movies. If you learn Computer Graphics and Geometric Modeling, you might even get a job in a field where you can have lots of fun. Art and architecture, biomedical imaging, computational photography: whatever you can see, or whatever you imagine you can see, you can design with Geometric Modeling and you can display with Computer Graphics.

Broadly, the major themes of Computer Graphics can be divided into three categories: graphics, modeling, and mathematical foundations. Graphics consists of lighting and shading -- reflection and refraction, recursive ray tracing, radiosity, illumination models, polygon shading, and hidden surface procedures. Modeling is the theory of curves, surfaces, and solids -- planes and polygons, spheres and quadrics, algebraics and parametrics, constructive solid geometry, boundary files, and octrees, interpolation and approximation, Bezier and B-spline methods, fractal algorithms and subdivision techniques. The mathematical foundations are mostly linear algebra, but from a somewhat idiosyncratic perspective not typically encountered in standard linear algebra classes -- vector geometry and vector algebra, affine spaces and Grassmann spaces, affine maps and projective transformations, matrices and quaternions.

Unlike some Graphics courses at other universities, this course focuses on more advanced graphics, modeling, and mathematical methods -- ray tracing, polygon shading, radiosity, fractals, freeform curves and surfaces, vector methods, and transformation techniques. Low level graphics algorithms such as line drawing, polygon filling, and clipping are bypassed to give more time and space to high level graphics techniques such as ray-tracing, polygon shading, and radiosity.

I have written a book specifically for this course. I have kept the chapters for each lecture relatively short in the expectation that students will read them in full. Lots of exercises and projects are included to flesh out the text. Your job in this class will be to read and absorb the text, and to work on a few fun projects that will give you a feel for the excitement and the power of Computer Graphics. We hope you have lots of fun and that you learn a lot while enjoying this class.

# Comp 360/560

This class will teach the fundamental techniques and mathematical background of computer graphics. The topics of this class include 2D fractals, affine/projective transformations, ray-tracing, shading, radiosity, and curves, surfaces and solids. These concepts form the backbones of modern-day graphical applications in computer gaming, computer animation, and scientific visualization.

# Class Information

Prerequisites: You should be comfortable with the following concepts.

• Trigonometry
• Trigonometric Identities
• Law of Sines and Law of Cosines
• Vector Geometry and Vector Algebra
• Dot Product, Cross Product, Determinant
• Vector Algebra
• Matrix Multiplication
• Calculus
• Differentiation
• Programming
• General familiarity with software design at least equivalent to Comp 212

Time and Location:  TR 02:30PM - 03:45PM @ DCH 1042

Instructor:

Dr. Ron Goldman

Duncan 3116

Office Hours: Wednesday 9:55 AM - 11:55 AM or by appointment

rng@cs.rice.edu

Teaching assistant:

Binhang Yuan

Duncan 3113

Office Hours: Monday 9:55 AM - 11:55 AM or by appointment

by8@rice.edu

# Class details

#### Lectures

Each chapter of the text will correspond to roughly one lecture. Class Discussion will be informal. You should try to answer all the questions at the end of each chapter. Preparation is crucial. You should read the text BEFORE coming to class and submit a brief written essay with questions you have about the chapter.

Attendance is MANDATORY. One point (per lecture) will be taken off of your final grade if you

• missed class without a valid excuse
• failed to submit a written essay (see below)
• neglected to do the Problem of the Day (see below)

#### Written Essay

The purpose of the written essay is to prepare you for the class discussion. The essay should be one typed page in grammatically correct English (see hints for good writing). The essay should cover:

• The main themes of the chapter
• What you learned from reading the text
• What you did not understand in the text
• Errors in the text
• Questions on the text and on the problems at the end of the chapter.

#### Problem of the Day

Each student will be assigned one problem for each lecture. The solution should be handed in at the beginning of class. Students should be prepared to present their work during class time.

#### Required Labs

There will be 3 required programming assignments (or labs) for undergrads and 4 for grad students, each lasting between 2 and 3 weeks. For the first two labs, you will work by yourself. But for lab3 and lab4 you can work in pairs. You may choose your partner, but you must work with a different partner for lab3 and lab4. If you have trouble finding a partner, send your labby an email and we'll try to pair you up.

Labs must be implemented in C or C++, using the OpenGL API for drawing. There will be a tutorial on C++ and OpenGL during the first week of classes (probably Wednesday in Symonds II at 7:00PM).

NOTE: You will need a PC Password for Symonds II (talk to the labby for instructions to obtain a password).

• Exams/Homeworks: One midterm, and one final, probably take-home, and homework. 50% of final grade.
• each approximately 2-3 weeks long
• Extra Credit Lab: The 4th optional programming assignment, only for undergrads .
• For students who do poorly on some of the labs and exams
• For A students who wish to be exempt from the final exam
• Worth up to a full letter grade
• See programing projects at the end of various lectures

#### Late Policy

where H is the number of hours after the deadline that the lab was submitted. You are aollowed to consult different sources, however, copying code is considered cheating and will not be tolerated.

#### Honor Code Policy

You are encouraged to consult with your classmates, TA, or instructor on the programming projects. Do not seek solutions or code from anyone not in the class, for example, you may not post questions to programming forums or get solutions from senior students. You may not transmit or receive code from anyone in the class in any way--visually (by showing someone your code), electronically (by emailing, posting, or otherwise sending someone your code), verbally (by reading your code to someone), or in any other way.

You may search the web and use the information you find to help understand the problem. However, you cannot take more than two lines of code from an external resource and actually include it in one of your assignments. Changing variable names or rewriting code you find does not void the "two line rule."

Exams are pledged, and you should discuss them with nobody except Dr. Goldman until everyone in the class has finished.

Any violations of these rules will be reported to the honor council.

#### Disabilities

Any student with a disability requiring accommodations in this course is encouraged to contact Dr. Goldman after class or during office hours; all discussions will remain confidential. Additionally, students will need to contact Disability Support Services in the Ley Student Center.

#### Required Text

Each student must have a copy of the required text for the class:
An Integrated Introduction to Computer Graphics and Geometric Modeling -- R. Goldman, CRC Press 2009

#### Other References

• General
• Computer Graphics: Principles and Practice -- Foley, Van Dam, Feiner, Hughes
• Computer Graphics -- Hearn and Baker
• Fractals
• Turtle Geometry -- Abelson and DiSessa
• Fractals Everywhere -- Barnsley
• Freeform Curves and Surface -- Bezier and Lagrange
• Curves and Surfaces for Computer Aided Geometric Design: A Practical Guide -- G. Farin
• Pyramid Algorithms: A Dynamic Programming Approach to Curves and Surfaces for Geometric Modeling -- R. Goldman

#### Syllabus

We will be covering the following topics in class this semester.

• 2-Dimensional Computer Graphics (Fractals)
• Turtle Graphics - 1.5 Weeks
• Affine Graphics - 1.5 Weeks
• Mathematical Methods for Computer Graphics
• Coordinate Free Methods - 1.5 Weeks
• Dot and Cross Products
• Determinants
• Vector and Matrix Techniques - 1.5 Weeks
• Affine and Projective Transformations
• Quaternions
• 3-Dimensional Computer Graphics (Realistic Rendering)
• Recursive Ray Tracing - 1 Week
• Surface Modeling - 1 Week
• Solid Modeling - 1 Week
• Polygonal Modeling - 1 Week
• Hidden Surface Algorithms - 1 Lecture
• Shading Algorithms - 1 Lecture
• Freefrom Curves and Surfaces - 2 Weeks
• Other topics - As time permits

# Lectures

 Date Topic Resources 08/25/15 Introduction (administration, overture) Textbook Ch.1 08/27/15 Turtle Graphics WheelRosette 10/01/15 Writing Using Articles 10/06/15 Chapter15 Quaternions QuaternionsNew QuatTransSAGA 11/18/15 Fractals and Splines FractalsandSplines Fractals.nb

# Labs/Homeworks/Exams

#### Exams

 Due Date Exams

#### Labs

• Lab Submission: All lab submissions should be done through owlspace. Please remember to remove any binaries and submit only the source and compilation files. These include VC++ files such as .dll, .suo, .ncb, .user, .sdf, and the debug/release folders.
• Project Files: All labs will be supplied with a Visual C++ Express 2010 project file. Please make sure to turn in your project with the project file properly configured so that the TA will not have any problem compiling your project.

 Due Date Labs Resources