CS40: Computer Graphics

Fall 2018
Welcome to CS40: Computer Graphics! This course focuses on the creation and manipulation of 3D geometric models and the rendering of these models on a two dimensional screen. We will examine modeling from both a pixel-based view and a more geometric vector-based approach. Core topics include geometric primitives, 2D and 3D matrix transformations, projective geometry, and object modelling. We'll examine the traditional rendering pipeline and will explore advanced techniques for scene manipulation using programmable shaders. Intermediate topics include texture mapping, lighting, and shadows. We will be using the modern OpenGL programming approach which uses programmable vertex and fragment shaders throughout the course. Advanced topics may include GPGPU computing using CUDA, particle systems, noise, and additional programmable shaders.

Course Basics

Lecture: MWF 9:30AM-10:20AM, Science Center 240
Lab A: Thursday 1:05PM - 2:35PM, Science Center 240
Lab B: Thursday 2:45PM - 4:15PM, Science Center 240

Instructor: Andrew Danner
Textbook: None required
Optional Refs: The Graphics Codex
Learn OpenGL
OpenGL Programming Guide (8e)
OpenGL Shading Language (3e)
OpenGL 4 Shading Language Cookbook
CUDA by Example
Email: adanner at cs dot swarthmore.edu
Office: Science Center 247
Office Hours: TBA by appointment

Lab Assignments: weekly, due Wednesday 11:59PM
Course Discussion: Piazza (by invitation, mandatory enrollment)


This course will use clickers to facilitate feedback, discussion, and student evaluation during class. For many upper level courses including CS40, we are now requiring that students purchase their own clicker for personal use. Please see the department clicker page for purchasing and registering information.

Additional references

How to ask questions on Piazza

Local Links

Git help
Git merge conflicts
Understanding git status
CMake in CS40 help
Tia's Language Notes
OpenGL 3.2 tutorial - most of this also works for OpenGL 4.x OpenGL docs
QT docs
OpenGL 4.2 Quick Reference Card
GLSL 1.20 specs
Tia's Language Notes
CMake (feedback welcome)

Common C++ Libraries

stdio, stdlib, cmath, cassert
STL summary, and vector class.