A3: PathTracer

Assignment 3 Instructions

PathTracer is the second of three components of Scotty3D. You should build on top of the same code repository you used for the MeshEdit assignment; you do NOT need to download a fresh new copy. This way, the mesh editing features you developed for A2 will still be available in A3. Do not worry if you did not successfully implement all the features of MeshEdit - they are not strictly necessary for PathTracer (but may still be fun to play with!). The documentation website is the primary source of information about this assignment, this document only contains administrative details about grading and submission.

A NOTE: To help keep you on schedule, we have split up this assignment into two deadlines. You must complete the first set of tasks for the first deadline, and the second set of tasks for the second deadline. We will not grade improved versions of the first task set after the first deadline, so please make sure to complete them on time!

Due date I: Tasks 1-3 on March 28th at 11:59 pm ET

Due date II: Tasks 4-7, rendered image, documentation and writeup on April 6th at 11:59 pm ET

Evaluation

The assignment consists of a total of 105 pts. The point breakdown is as follows:

  • Task 1 - Generating Camera Rays: 3
  • Task 2 - Intersecting Triangles and Spheres: 14
  • Task 3 - Implementing a Bounding Volume Hierarchy (BVH): 18
  • Task 4 - Adding Path Tracing: 14
  • Task 5 - Adding New Materials: 14
  • Task 6 - Direct lighting: 8
  • Task 7 - Infinite Environment Lighting: 14
  • Beautiful Image: 10
  • Documentation: 5
  • Writeup: 5

NOTE (I): As with your creative mesh example from A2, we will grade you on the quality/creativity of the "beautiful image," so don't submit something totally lame! ;-)

NOTE (II): Please add comments that say "Task 1", "Task 2", etc., in your writeup.txt so we can use them for grading.

Note (III): Task 3 is notoriously difficult - we recommend starting early as it will require using a lot of C++ that you may otherwise be unfamiliar with. Do note that while tasks 4-7 do not directly depend on having a working task 3 (they do require a working task 1 and 2), you may not be able to test your renderer on meshes with a lot of primitives.

Beautiful Image

Finally, you will need to create some kind of beautiful image with your path tracer (worth 10 percent of your grade!). Beauty is of course in the eye of the beholder, but generally we are looking for clear effort in the generation of one special "capstone" image for this assignment, beyond just basic debugging/confirming that the technical features work. For this part you may use whatever resources you like, such as free COLLADA files from places like TurboSquid (or any other free online resource); you may also find it helpful to use free software like Blender to assemble a scene. Better still would be to make your own 3D models using the MeshEdit tools you implemented for A2. Finally, the better your path tracer is, the better your image will become! For instance, is it running slowly? Identifying and eliminating performance bottlenecks will enable you to more rapidly improve your image. Going above and beyond the basic features of A3 will let you render even more beautiful phenomena. Basically we want you to "eat your own dog food," i.e., become a user of your own software, so that you can really get some intuition for where it works well---and where it still needs improvement! Please name your image as rendered.png.

For some inspirational images, check out some of these rendering competitions:

These folks had a full semester to work on their renderer, but these images should still provide some inspiration for what you can achieve with software like this!

Documentation

Clear, well-written documentation is a critical part of software development. Since you (the students) are the ones who will most benefit from good documentation---or will suffer through bad documentation---we are "crowd sourcing" improvements to the course material. What did you find confusing---and then finally figure out?

As 5 points of your assignment grade, you will need to submit suggested edits to the assignment documentation. These could be:

  • Suggested changes or additions to the assignment writeup
  • Suggested changes or additions to assignment website (for A2, A3, and A4)
  • Suggested changes or additions to comments in the skeleton code

Do not wait until the due date to submit these suggested edits. They will be most helpful to your classmates (and to us!) if they are submitted ahead of time, so that we can immediately incorporate any good suggestions into the actual course material. To submit your edits, you must therefore:

  • Go on Piazza
  • Find the thread with the appropriate label
  • Make an anonymous (not private) post with your suggested edit

The TAs will monitor this label, and immediately update the docs with any/all useful suggestions. This Piazza post will also be recorded as part of your assignment grade. Note that we do not have to accept your edit in order for you to receive full credit on the assignment. However, we will grade your edits based on whether they appear to be a "good faith effort" to make a useful comment. In other words, did you really think about what is clear/unclear and provide a useful edit? Or did you just write something totally random at the very last minute? :-) Especially useful edits (e.g., those that provide nice insights, or point out serious bugs/errors) may receive extra credit.

Writeup

Additionally, you will submit a short document explaining which tasks you successfully implemented, and any particular details of your submission. If your submission includes any implementations which are not entirely functional, please detail what works and what doesn't, along with where you got stuck. This document does not need to be long; correctly implemented tasks may simply be listed as completed.

If you wish, you may also include render result images to explain the any bugs or show off extra credit work. If so, please add these files to your submission archive, and mention them in the writeup.

The writeup must be a pdf, markdown, or plaintext file. Include it in the root directory of your submission as writeup.pdf, writeup.md, or writeup.txt. If you did extra credit, you must note it under a heading "Extra Credit," otherwise it will not be counted.

Failure to submit this writeup in your final submission will incur a 5 pt penalty on the assignment.

Code Environment

This codebase should compile on Linux, macOS, and Windows on a typical environment. The build instructions given on the project page will walk you through installing dependencies and building the code. If you have difficulties running the code on your local machine, the GHC 5xxx cluster machines have all the packages required to build the project.

Handin Instructions

As with the previous assignments, we will be submitting on Autolab. You should create a tar archive of your entire src subdirectory along with the writeup (e.g. writeup.txt) for the checkpoint, and a tar archive of your entire src subdirectory along with the writeup (e.g. writeup.txt) and rendered photo (rendered.png) for the final submission.

Checkpoint:

$ pwd
> (...)/Scotty3D
$ tar cvzf handin.tgz src writeup.txt 
> a src
> a src/main.cpp
(...)
> a writeup.txt

Final:

$ pwd
> (...)/Scotty3D
$ tar cvzf handin.tgz src writeup.txt rendered.png
> a src
> a src/main.cpp
(...)
> a writeup.txt
> a rendered.png

The Autolab system will run a simple script that checks for the extra files. If the output indicates that something is missing, fix it or risk losing points!