GLSL Diffuse Lighting Shader Tutorial

preview_player
Показать описание
A tutorial on calculating diffuse light in a GLSL shader. Diffuse light requires a bit of math, but is easy to compute in a GLSL diffuse lighting shader tutorial.
Рекомендации по теме
Комментарии
Автор

In addition to the angle between the surface normal and the light source normal, I think the intensity of light returned from a surface patch to a camera also depends (proportional to 1 over distance squared) on 1) how far the patch is from the point light source and 2) how far the patch is from the camera.

forbeswinthrop
Автор

I've never realized that "faceted" sounds like that :D

Nuriyasov
Автор

What does your fragment shader code look like?

HarrisonGould
join shbcf.ru