- 发射光emissive
- 环境光ambient
- 漫反射光diffuse
- 镜面反射光specular
- 高光度shininess,法线方向N,光源方向L,视点方向V
漫反射的反射强度与物体表面法线及光的入射角度有关,而与人眼的观察角度无关
color_out = emissive + ambient + diffuse + specular;
diffuse = _Kd * lightColor * max(dot(N, L), 0);
specular = _Ks * lightColor * pow(max(dot(N, H), 0), shininess);
H为nomalize(L + V)
时间: 2024-11-05 17:16:31