terravisor/include/scene.h

47 lines
909 B
C++

#ifndef SCENE_H_
#define SCENE_H_
#include <GLFW/glfw3.h>
#include <glm/glm.hpp>
#include "fbo.h"
class Scene {
public:
Scene(int width, int height);
~Scene();
void Init();
void Display(GLFWwindow* window);
void DrawGui(GLFWwindow* window);
void Idle();
void ReloadShader();
int window_width;
int window_height;
private:
void InitBuffers();
void InitQuadBuffers();
void InitShaders();
FBO fbo_;
FBO post_fbo_;
GLuint shader_program_;
GLuint quad_shader_program_;
GLuint vao_;
GLuint quad_vao_;
float angle_;
float scale_;
float aspect_;
float near_z_;
float far_z_;
float fov_;
glm::mat4 view_matrix_;
glm::mat4 projection_matrix_;
void UpdateCamera();
};
#endif // SCENE_H_