The complete tutorial on how to render lighting using OpenGL can be found here: http://www.haroldserrano.com/blog/anatomy-of-light-in-computer-graphics