Lighting is a technique used for adding realism to a graphical scene. This is done by simulating the highlights and dark areas that occur on objects under natural lighting. The default light source is the ambient light, which is a directionless light that shines uniformly on all objects in the scene. You cannot see the light sources themselves. Objects created by functions such as
fill3 as well as the
patch functions can show the effect of light and have several properties which govern how they will be impacted by the light sources.
In this recipe, you will use
teapotdemo supplied by MATLAB to investigate the effects of lighting on visualization. The demo has a console window that ...