Introduction to Computer Graphics

Introduction to Computer Graphics


In this course students will be introduced to the basics of computer graphics, including how to define objects with vertices and meshes, how to write basic shaders, lighting and shading, projections, transformations in 3D, and texture mapping. Assignments will be done using Javascript and WebGL, and will build on each other.


CMPS101, MATH21 or AMS10. Concurrent enrollment in CMPS160L lab section is required.

This course is a 7-unit course with the lab. It involves significant programming, in 3 different languages: HTML 5%, javascript 80%, GLSL 15%. If you haven't had at least 4 courses already that involved programming, the instructors suggest you get some more experience before taking this course.That is, if you are fresh out of CMPS101, I suggest waiting (but I dont require it).


Professor: James Davis (

TA: Lucas Ferreira (

Office Hours

James Davis: E2-363, 1:00-2:30pm Tuesdays, 2:00-3:30pm Thursdays (or by appointment).

Lucas Ferreira: BE-119, 7:00-8:00pm Wednesdays(or by appointment).


WebGL programming guide: interactive 3D graphics programming with WebGL
Kouichi Matsuda and Rodger Lea

The assignments follow the flow of this book closely, and I assume you are reading the chapters. You'll want a copy. 


TuTh 09:50AM-11:25AM  Soc Sci 1-110

Lecture Schedule

Lecture 1 (Sep 27): Introduction to Class (Slides)
Lecture 2 (Oct 2): Linear Algebra Review, Assignment 1 Intro.
Lecture 3 (Oct 4): Quiz 1 - Linear Algebra
Lecture 4 (Oct 9): Assignment 2 Intro.
Lecture 5 (Oct 11): Object Modeling, triangles and meshes. (Slides)
Lecture 6 (Oct 16): Assignment 3 Intro., Transformations. (Slides)
Lecture 7 (Oct 18): Colors. (Slides)


Lecture 8 (Oct 30): Assignment 4 Intro., Texture Mapping. (Slides)
Lecture 9 (Nov 1): Quiz 2 - Transforms, Modeling, Color.
Lecture 10 (Nov 6): Assignment 5 Intro., Projection. (Slides)
Lecture 11 (Nov 8): Visibility. (Slides)
Lecture 12 (Nov 13): Assignment 6 Intro., Shading/Lighting. (Slides)
Lecture 13 (Nov 15): Perception. (Slides)
Lecture 14 (Nov 20): Quiz 3 - Texture, Camera, Projection.
Lecture 15 (Nov 22): Holiday
Lecture 16 (Nov 27): Assignment 7 Intro., Displays.ppt
Lecture 17 (Nov 29): Quiz 4 - Lighting, Visibility.
Lecture 18 (Dec 4): Ray Tracing. (Slides)
Lecture 19 (Dec 6): Discuss Next Years Class and how to make better


Tu 03:20PM-04:55PM  Soc Sci 1-135

Th 11:40AM-01:15PM  Soc Sci 1-135

Lab attendance is required, as important content regarding the more technical aspects of the assignments will be gone over during the lab sections. Each week there are two lab sections, which will cover identical material. You are free to attend whichever one you like, however, if the room is full, priority is given to those actually enrolled in that section.


Your grade for CMPS-160 is broken down as follows:

  • 4 Quizzes: 10% each (total 40%)
  • 8 Programming assignments: (total 60%)

Your grade for CMPS-160L is simply your grade for CMPS160.

Programming assignments are broken up into several points, each with equal weight. Your grade for the programming assignment is then calculated by the number of points you completed for that assignment. 

The grade breakdown is as follows:

A+ = 100-97%
A = 96-93%
A- = 92-90%
B+ = 89-87% 
B = 86-83% 
B- = 82-80%
C+ = 79-77%
C = 76-70%  
D = 69-60%  
F = 59-0%


There will be 8 programming assignments in Javascript and WebGL due weekly on Friday at 11:59pm (there will be a grace period until Sunday 11:59pm):

Assignment 1: Painting Points (Ch1,Ch2) - Due Oct 05
Assignment 2: Painting Geometric Objects (Ch3 67-91) - Due Oct 12
Assignment 3: Transforming Geometric Objects (Ch3 91-113, Ch4) - Due Oct 19
Assignment 4: Texturing and Coloring Geometric Objects (Ch5) - Due Oct 26
Assignment 5: Creating a Virtual World (Ch7) - Due Nov 2
Assignment 6: Lightening the Virtual World (Ch6) - Due Nov 9
Assignment 7: Animating the Virtual World (Ch 9 324-344) - Due Nov 16
Assignment 8: Expressive and Interactive Experience () - Due Dec 7

Each assignment builds on top of the previous ones. In technical terms, you will generally need features from previous assignment to properly do the points for the next assignment.

- Submissions

Assignments will be submitted on Canvas as zipped project folders containing all of the necessary HTML/Javascript/Shader code. 

- Late Policy

Assignments are always turned in weekly. That is, each week only one submission will be checked for each student. Late submissions of assignments  will be penalized 50% off and will be accepted no more than 1 week late. No assignments will be accepted after the Friday before finals week.


There will be four in-class quizzes to test your understanding of the material. In the week leading up to the quiz, sample problems similar to the ones that will appear on the quiz will be distributed. There will be no midterm or final.

  1. Quiz 1 (Oct 4)
  2. Quiz 2 (Oct 25)
  3. Quiz 3 (Nov 8)
  4. Quiz 4 (Nov 20)

Make-Up Policy: If you miss a quiz without informing us beforehand, you can make it up within the following week (no later), however, your grade on the make-up is cut in half (contact one of the TAs or the professor to organize). That is, if you get an 80/100 on the make-up, your actual score will be 40. If you know you will need to miss a quiz you need to get in touch at least 48 hours in advance to make arrangements.


Course Summary:

Date Details