CS300Project 4Due: Nov 16SynopsisImplement bump mapping, integrating it with previous implementations of texture mapping and Phong lighting and shading.InstructionsThe scene generated by the associated scene.cppfile will generate an object with both a texture map and a bump map. For each visible pixel, you are to do these steps:●Use the object's bump map to compute a perturbation of its surface normal.●Use the object's texture map to compute a diffuse color. ●Use Phong lighting/shading to compute the color for the pixel, using the diffuse color and normal from the previous two steps, and the specular color and shininess exponent from the object's attributes.You will calculate the normal perturbation usingN=ND, where●D= fvPu– fuPv×N∥N∥,●Pu,and Pvare calculated, as shown in class, by assuming the texture coordinate function interpolates linearly across the polygon, and●fu,and fv
This is the end of the preview.
access the rest of the document.