CSL781 Assignment 2
Due: Mar 14, 11pm.
To be turned in on Moodle.
OpenGL Graphics
In this assignment, you will replace the raytracer of assignment 1 with OpenGL Pipeline. The scene will largely be the same as before, with the following changes:
- The area light source is removed. Shadows, object reflection and ray refraction are not required.
- Floor is not reflective, but it is tiled (you may find any texture image from the web for the tile).
- Table top has a wood texture (you may find any wood texture image from the web).
- Glass should remain translucent.
You should convert all geometry to triangles offline by yourself, and save them in a single file. Use the following format:
<Object_count: %d>
*** for i in (0..Object_Count]
<Matrix_i: %f %f %f %f %f %f %f %f %f %f %f %f >
<Object_i Vertex_Count: %d>
*** for j in (0..Objec_i_Vertex_Count]
<Object_i_Vertex_j X Y Z: %f %f %f>
<Object_i_Triangle_Count: %d>
*** for j in (0..Object_i_Triangle_Count]
<Object_i_Triangle_j %d %d %d>
Devise a generic reader for your scene. Separate from the primitive file, you may also read the object's illumination parameters from another file.
The interface will adapt as well:
- No area light movement.
- The movement of camera will be by mouse. Left-Right motion moves on lattitude, Up-Down on Longitude, and Diagonal motion combines the two.
- The radius of the sphere on which the camera moves can be reduce with up arrow and increased with down arrow -- simulating forward and backward motion, respectively.
** Revised: Sat, 27 Feb 2021 by Subodh Kumar
-- The URL of this page is: http://www.cse.iitd.ac.in/~subodh/courses/CSL781/opengl.html --