4 #include <glm/gtc/matrix_transform.hpp>
14 , projection(glm::perspective(fov, aspect, near_clip, far_clip)) {
19 void Camera::Viewport(int width, int height) {
20 Viewport(0, 0, width, height);
23 void Camera::Viewport(int x, int y, int width, int height) {
24 glViewport(x, y, width, height);
25 Aspect(width, height);
28 void Camera::FOV(float f) {
33 void Camera::Aspect(float r) {
38 void Camera::Aspect(float w, float h) {
42 void Camera::Clip(float near, float far) {
49 void Camera::UpdateProjection() {
50 projection = glm::perspective(fov, aspect, near_clip, far_clip);