-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathPointLight.h
More file actions
executable file
·36 lines (27 loc) · 822 Bytes
/
PointLight.h
File metadata and controls
executable file
·36 lines (27 loc) · 822 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#pragma once
#include <vector>
#include "Light.h"
#include "OmniShadowMap.h"
class PointLight :
public Light
{
public:
PointLight();
PointLight(GLfloat shadowWidth, GLfloat shadowHeight,
GLfloat near, GLfloat far,
GLfloat red, GLfloat green, GLfloat blue,
GLfloat aIntensity, GLfloat dIntensity,
GLfloat xPos, GLfloat yPos, GLfloat zPos,
GLfloat con, GLfloat lin, GLfloat exp);
void UseLight(GLuint ambientIntensityLocation, GLuint ambientColourLocation,
GLuint diffuseIntensityLocation, GLuint positionLocation,
GLuint constantLocation, GLuint linearLocation, GLuint exponentLocation);
std::vector<glm::mat4> CalculateLightTransform();
glm::vec3 GetPosition();
GLfloat GetFarPlane();
~PointLight();
protected:
glm::vec3 position;
GLfloat constant, linear, exponent;
GLfloat farPlane;
};