1
0
mirror of https://github.com/LearnOpenGL-CN/LearnOpenGL-CN.git synced 2025-08-23 12:45:29 +08:00

Fix img path issue

This commit is contained in:
Meow J
2015-06-25 23:23:59 +08:00
parent 5ccc5e4059
commit 20e5a7820b

View File

@@ -92,7 +92,7 @@ else if(lightVector.w == 1.0)
幸运的是一些聪明人已经早就把它想到了。下面的方程把一个片段的光的亮度除以一个已经计算出来的衰减值,这个值根据光源的远近得到:
![Latex Formula](https://raw.githubusercontent.com/LearnOpenGL-CN/LearnOpenGL-CN/master/img/Light_casters1.jpg)
![Latex Formula](https://raw.githubusercontent.com/LearnOpenGL-CN/LearnOpenGL-CN/master/img/Light_casters1.png)
在这里I是当前片段的光的亮度d代表片段到光源的距离。为了计算衰减值我们定义3个项常数项Kc一次项Kl和二次项Kq。