Ambient Light
The first type of lighting that i implemented was ambient lighting.Ambient |
Diffuse Light
The second type of lighting that i added was diffuse lighting.Diffuse |
Specular Light
Specular lighting is similar to diffuse light in that it takes into account the direction of the light and how it interacts with the surface of the object but it is also concerned with the position of the viewer which allows it to create highlights on the surface of the object.Specular |
Combined Light
After all 3 were working i combined them together to try and create a more realistic effect.
Phong Shading
Up until now these lights have been created on the vertex shader, to create the phong shading i had to change my shaders so that all the lighting was calculated on the fragment shader instead.
Phong |
Out of all the light types i have implemented so far the phong shading gives the best effect. and although pretty similar to the combined light it looks a lot better.
Thanks for reading!
Email: 10004794@napier.ac.uk - Please put blog in the subject.
Xbox Gamertag: craigmcmillan01
Twitter: Follow @craigmcmillan01
steam: craigmcmillan01
add or follow and we can game!
No comments:
Post a Comment