> For the complete documentation index, see [llms.txt](https://devlog.joonas.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://devlog.joonas.io/graphics/opengl/untitled.md).

# \[WIP] Lighting, Normal Mapping

## Normal Mapping

노멀맵과 라이트

노멀맵을 대충 만들어주는 사이트: <http://www.smart-page.net/smartnormal/>

두 종류

* Model/Object Space Normal Map
* Tangent Space Normal Map

## Light

빛의 유형

* point light – 한 점에서 광원이 전체로 뻗는 형태. 각 버텍스마다 다른 빛의 방향을 가진다. (전구, 횃불 등)
* spot light – 한 점에서 콘(cone) 형태로 정해진 각도만큼 밝힘.
* directional light – 위치는 없고 방향만 있는 빛. 모든 정점에 동일한 세기와 각도로 도착한다. (태양광)

Lambertian reflectance

Phong shading
