Extend your HW5 program.
Average the normals for each face to create a unique normal for each vertex.
Implement the Phong shading model.
Illuminate your geometric model with at least two point lights.
Implement both Gouraud and Phong shading algorithms.
Allow the user to interactively select either Gouraud and Phong shading.
Allow the user to choose the material properties
of your model from a pre-defined list of at least three materials.
The three materials should be significantly different, i.e. don't just change the color. You should also change the shading properties.
One of your materials should produce a bright white specular
highlight similar to the example below.
(Gouraud shading on the left and Phong shading on the right).
One of your materials should have the following properties:
When I load bound-lo-sphere.smf I should see an output similar
to the one above. (One sphere of course.)
When I switch between Gouraud and Phong shading, the output should switch between the two above spheres.
Similar to your camera, place one of your lights on a
cylinder around the object and allow the user to change the
light location by modifying the angle, radius and
height of the light's location.
The light should only move when the user changes its location. This light should be defined in the coordinate system of the object.
The other light should be defined in the camera coordinate system, i.e. it moves with the camera, and it should be located near the eye point.
Last modified February 26, 2017.