-
Notifications
You must be signed in to change notification settings - Fork 29
Lighting
Eddie S edited this page Oct 2, 2020
·
3 revisions
Lighting class is contained by Scene. It allows you to add, remove, update lights on scene that have an influence on object material's color.
-
This type of lighting influences all objects on a scene. (Skybox is influenced too)
glm::vec4 ambient_color
First three components is RGB color, A component is intensity.
-
It is runtime lighting calculations are proccessed for each frame in fragment shader. It allows you to move lights around, change its color, radius and other properties.
-
Influences objects in a specified sphere.
struct PointLight { glm::vec4 position; glm::vec4 color; float constant {1.0f}; float linear {0.7f}; float quadratic {1.8f}; float radius; }; `PointLight(const glm::vec3& position, const glm::vec4& color, float radius) noexcept;`
-
struct DirectionalLight { glm::vec4 direction; glm::vec4 color; };
-
Not implemented yet.
-
-
Baking maps is not in the nearest future : /