In this assignment, you will be implementing a simplified 3D rendering pipeline. This will consist of several parts, introduced through a series of tests:
Your assignment is to implement the functions in driver_state.cpp.
Submit your driver_state.cpp file on iLearn.
Along with the sample code is a list of test cases and a grading script.
Each test case contains a list of commands, which are the OpenGL functions that will be called and the arguments that they will be given.
The grading is automated, so you will be able to determine what your score will be before you turn it in.
The file grading-scheme.txt tells you how many points each test case is worth.
This is the file that the grading script will use.
Some deviation is to be expected, but you should be able to get very close.
You should be able to get within 0.10 error on most, though not all, of the tests; the permitted error is very conservative.
The project will be graded out of 50 points.
The maximum number of points possible is 60; 10 points of extra credit are possible.
The tests are documented individually in the table below.
We are providing you with the grading script that we will be using to grade this project.
You can run it like this: "./grading-script.py .
".
This will automatically compile your code, run all of the tests in the table above, and compute your score based on the point values in the table.
This means you can run it yourself to see your progress.
This will allow you to quickly identify the next test to work on.
You can also run it before you submit your project so that you know what your score will be before you submit it.
This project has two checkpoints.
Checkpoints are intended to encourage you to start your project early.
At each checkpoint, you will submit your project just as you would when it is due.
At the first checkpoint, your program will be graded out of 20 points. At the second checkpoint, your program will be graded out of 35 points.
No extra credit is possible at checkpoints.
When your project is due, it will be graded out of 50 points, and extra credit will be given for scores higher than that.
The table below documents the tests.
Along with a thumbnail showing what the result should look like, I make some potentially helpful notes about the test case.
Click the thumbnail for a full-size image.
Thumbnail |
Notes |
|
00.txt
10 points
Get the basics working: basic pipeline structure, triangle rasterization, and pixel placement. Note that most aspects of this project can be ignored at this stage. In particular, you can pass this test without: shaders, uniform data, per-vertex data, clipping, colors, homogeneous coordinates, or z-buffering. These features will be introduced one by one in later tests. The idea is to implement and test features step by step as we progress through the test tests.
|
|
01.txt
1 points
Implement support for custom image sizes.
|
|
02.txt
3 points
Introduce support for more than one triangle.
|
|
03.txt
5 points
This test case introduces three new elements: simple transforms (non-uniform scale, no perspective), a vertex shader (which performs that transform), and uniforms (makes transformation data available to the vertex shader). Note that you do not need homogeneous coordinates to complete this test.
|
|
04.txt
2 points
This test is a combination of translation and scale; you will need to implement homogeneous coordinates for this test. There is no perspective in this test.
|
|
05.txt
1 points
Make sure things work with a perspective transformation.
|
|
06.txt
3 points
This test introduces two new elements: color support and fragment shaders.
|
|
07.txt
3 points
: This test includes vertex attributes (besides position), and it tests to make sure flat interpolation works. This test also checks to make sure you can handle more than one color in a scene.
|
|
08.txt
3 points
This test introduces non-perspective interpolation (interpolation using image-space barycentric coordinates) of per-vertex attributes.
|
|
09.txt
3 points
Implement z-buffering.
|
|
10.txt
2 points
Implement clipping against the near and far planes. Note that full perspective-correct clipping is not required to pass this test.
|
|
11.txt
1 points
Make sure z-buffering works with interpolated colors.
|
|
12.txt
1 points
Implement clipping against the sides of the image. Note that full perspective-correct clipping is not required to pass this test.
|
|
13.txt
1 points
Implement trianlge fan.
|
|
14.txt
1 points
Implement trianlge strip.
|
|
15.txt
1 points
Implement indexed rendering.
|
|
16.txt
1 points
Implement full perspective-correct clipping.
|
|
17.txt
1 points
Make sure flat interpolation is working.
|
|
18.txt
1 points
Make sure non-perspective interpolation is working.
|
|
19.txt
1 points
Implement perspective-correct interpolation.
|
|
20.txt
1 points
Test z-buffering with perspective transform.
|
|
21.txt
1 points
Test to make sure non-perspective interpolation works with clipping even with a perspective transform.
|
|
22.txt
1 points
Test to make sure perspective-correct interpolation works with clipping even with a perspective transform.
|
|
23.txt
1 points
Large test with triangle rendering. Make sure that rendering is not too inefficient. This test includes many features, including perspective, clipping, perspective-correct interpolation. If something is not quite working, it has a good chance of showing up here. If you find that this test breaks, try pruning out triangles to try to create a smaller test that also breaks. This will be easier to debug.
|
|
24.txt
1 points
Repeat the stress test with indexed rendering. Both stress tests have exactly the same triangles in the same order. The colors are completely different.
|
|
25.txt
10 points
Throw lots of random stuff in and see what happens
|