GPU Programming Lab 7
Adding a Light Source
Due Monday, October 17

Starting with today's demo (round_cube_lit), add a second light source somewhere else, with a different color. The lighting calculations are in the tess_eval shader. fca is set up using R from the first light source. To add a source, calculate the light (R = D I cos(theta)), and add the second light to the first. So if you calculate a second light as R2, the final line would look like this:
fca = vec4(R + R2, 1.0);
		
Just adding together the light sources is the right thing to do, since they're additive in terms of brightness. If they overlap, you'll see an overlap region where there's a contribution from each. Too much light will wash out the sphere, and lead to a white region. This is pretty much what happens in real life too!