Lighting and suggestive contours require surface normals (vectors pointing away from the face of the model to the outside) to be added to our models. Currently, we only store positions of each vertex. We would need to modify a lot of drawing code as well to add in these surface normals. Changes would be needed to our shaders to accept the normals, and rendering code in the Model class. Additionally, the parser would have to be modified to read in the files containing the surface normals.
Adding normals is done in terms of the Model and WavefrontParser class. Our shader needs to be updated to use them, and they need to be passed to the program in the Model.init() code in draw().
Lighting and suggestive contours require surface normals (vectors pointing away from the face of the model to the outside) to be added to our models. Currently, we only store positions of each vertex. We would need to modify a lot of drawing code as well to add in these surface normals. Changes would be needed to our shaders to accept the normals, and rendering code in the Model class. Additionally, the parser would have to be modified to read in the files containing the surface normals.