



Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
This coursework exercise is a practical programming exercise, which should be done using the Web version of the Open Graphics Library (WebGL)1 2.
Typology: Lecture notes
1 / 5
This page cannot be seen from the preview
Don't miss anything!




Important
Make sure that you give yourself enough time to do the coursework by starting it well in advance of the deadlines. If you have questions about the coursework or need any clarifications then you should come to the tutorials or consult the Piazza pages of this course! This coursework exercise is a practical programming exercise, which should be done using the Web version of the Open Graphics Library (WebGL)^1 and the OpenGL Shading Language (GLSL)3 4. To keep the overhead as low as possible, we provide a comprehensive framework to manage basic I/O, shader editing and compilation functionalities.
(^1) http://www.opengl.org/wiki/Getting_Started (^2) http://www.opengl.org/sdk/docs/man/ (^3) http://www.opengl.org/documentation/glsl/ (^4) http://www.lighthouse3d.com/opengl/glsl/
interface variables are mapped to fields in the provided Uniforms tab of the GUI.
The framework also provides a Log widget which shows the result of the shader compilation and linker stages (’Compile & Link’ with the according button in the Editor widget ).
Furthermore, user-defined uniform variables are parsed and made avail- able for manipulation in the Log tab.
To use this mechanism, define a uniform
To communicate between shaders you can use varying
Since the initial shaders are pure pass through shader using a hard-coded constant color for shading, the scene has not much appeal yet. The default model is a teapot but we cannot see its true shape yet because of missing illumination. The check the geometry besides the lack of a proper lighting model the framework provides a Wireframe mode in the Model tab. (Model → show wireframe)
Your tasks are: