2022 November 13,

CS 311: Exam B

Exam B was oral — that is, a one-on-one interview. Two or three days before the exam, students were given this list of questions. They were told that they would be asked two or three of them.

  1. What is the swap chain? Why does it exist? What is it made of?
  2. In the jargon of our hardware triangle rasterization project, what is the distinction between a mesh and a vesh? Why are there two concepts?
  3. One of the Day 22 study questions: Consider all of the lighting effects in 600mainSpecular.c. That's diffuse, ambient, specular based on a directional light and a positional light. Could we implement all of this lighting in the software triangle rasterizer from our first project? If not, why not? If so, what would unifDim, attrDim, and varyDim be?
  4. The other Day 22 study question: We have implemented specular reflection under the assumption that the camera is perspective. How would things change if the camera were orthographic?
  5. What is the core algorithm of ray tracing?
  6. In our ray tracer, each body has three "shaders" attached to it: getIntersection, getTexCoordsAndNormal, and getMaterial. Why are they separated like this? Why not combine them into two functions or one? Alternatively, why not split getTexCoordsAndNormal into two shaders and getMaterial into two or more shaders?

On the day of the exam, each student had a 15-minute time slot (although many of them used only 10 minutes). They were asked questions 2 and 6. Then they were asked question 3 in front of a computer showing my vertex and fragment shaders.