summaryrefslogtreecommitdiffstats
path: root/src/graphics/Frustrum.hpp
blob: e8a6fd6d4c24f69b0a25aa65ffa3994b212b3a6a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#ifndef _FRUSTUM_H
#define _FRUSTUM_H


#include <cmath>
#include <algorithm>
#include <GL/glew.h>
#include <glm/glm.hpp>
#include <glm/gtc/type_ptr.hpp>

class Frustum {
public:
	Frustum() = default;

	~Frustum() = default;

	void CalculateFrustum(glm::mat4 &view_matrix, glm::mat4 &proj_matrix);

	glm::vec4 frustum_planes[6];

	bool TestInsideFrustrum(glm::vec4 Min, glm::vec4 Max);
};

#endif