Computer graphics in Game development
Ivan Belyavtsev
25.01.2020
# - commentv - vertexvn - normalsvt - texture coordinatesf - face (polygon) - list of vertexes, normals, and tex coordinates [1]mtllib [external .mtl file name] - material descriptorusemtl [material name] - next faces should be drawn with [materal name] color[1]
newmtl [material name] - set up material nameillum [mode] - illumination modelKa - ambient colorKd - diffuse colorKs - specular colorNs - specular exponentmap_Kd - duffuse texture [1]\[L(\vec{P}) = Ka + \sum_{lights}{[Kd\vec{N} \cdot \vec{L} + Ks(\vec{V} \cdot \vec{R})^{Ns}]}\]
\[\vec{R} = 2(\vec{N} \cdot \vec{L})\vec{N}−\vec{L}\]
[2], [3]
Let’s implement it together
1. Wavefront obj file format summary // FileFormat.Info.
2. Phong B.T. Illumination for computer generated pictures // Commun. ACM. New York, NY, USA: Association for Computing Machinery, 1975. Vol. 18, № 6. Pp. 311–317.
3. The phong model, introduction to the concepts of shader, reflection models and brdf [Electronic resource]. 2015. URL: https://github.com/akalenuk/wordsandbuttons/blob/master/pages/interactive_guide_to_homogeneous_coordinates.html.