

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!


Due: Thursday, March 27th at 11:59pm
Goal: Learn to use render-to-texture and geometry shaders. Note: You may work in groups of two for this project, but you will be expected to implement a larger variety of techniques.
Problem 1 (25 points): Use render into a texture to store your output for reuse in another pass. Use “ping-ponging” to bounce your output back and forth between rendering passes.
Start using either a random binary image or load some examples I will post on the web page. Please slow the steps down so I can see them (say 5 or 10 steps per second). Groups of two must also allow on-screen clicks to add 2 × 2 black (live) regions at those points.
Allow me to select the next filter to apply using either a menu or keystrokes, however if you bind these filters to keystokes, please output text in the OpenGL window displaying the key controls.
Problem 2 (25 points): Write a program that loads a model from a file and displays it on screen, using a shader program to display only the silhouette edges. Silhouette edges are defined as edges where one of the adjacent triangles points away from the viewer (i.e., N · V > 0 ) and the other adjacent triangle points towards the viewer (i.e., N · V <= 0 ).
Groups must also have a mode where the silhouettes are not computed from the eye’s point of view but are computed from the light’s point of view. You should write a different geometry shader that then extrudes these sil- houettes into triangles in the direction away from the light (i.e., you are creating shadow polygons that could be used for shadow volumes). This geometry shader would not output a GL LINE STRIP but would rather output a GL TRIANGLE STRIP with a maximum 4 output vertices per input line.
NOTE: Please include a README file describing the platform your program runs on as well how to compile your program. If you do not include all the models with your submission, tell me where the models must be for your program to find them.