8th Chapter Light and Shadow
The rich effect of image rendering is largely due to the use of light and shadow. The effect of light and shadow in the real world is very complex, but its essence-the principle of optical transmission is very single, and this is another example of nature simplified. In order to simulate the rich illumination effect, several different light source models (ambient light, parallel light, point light source, Spotlight, etc.) are put forward, which can be used in different situations to achieve a good illumination effect.
In Three.js, the creation and use of light sources and shadows is very convenient. After learning how to control the basic method of light and shadow, if it can be flexibly applied, it will make the scene more realistic rendering effect. In this chapter, we will explore the effects of four commonly used light sources (ambient, point, parallel, Spotlight), and shadow, and how to create the use of lighting.
Series Blog-three.js Getting Started Guide (Zhang Wenli)-Light and Shadow