|
Molecular Vis
Improving perception of molecular visualization
|
Class for point-lights. More...
#include <PointLight.h>
Public Member Functions | |
| PointLight (glm::vec3 color, glm::vec3 position, glm::vec3 attenuation) | |
Public Member Functions inherited from Light | |
| virtual void | setUniforms (const std::vector< std::shared_ptr< Shader >> &shaders, int index) final |
Protected Member Functions | |
| virtual void | setUniform (std::shared_ptr< Shader > &shader, int index) |
Class for point-lights.
| PointLight::PointLight | ( | glm::vec3 | color, |
| glm::vec3 | position, | ||
| glm::vec3 | attenuation | ||
| ) |
Creates a point-light.
| color | Color of the light. |
| position | Position of the light. |
| attenuation | Attenuation coefficients of the light.ss |
|
protectedvirtual |
Sets the point-light related uniforms in a shader. Sets following uniforms: pointLights[index].color pointLights[index].position pointLights[index].attenuation
| shader | Shader to be updated |
| index | index of the light among lights of the same type (used in shader to index light) |
Reimplemented from Light.