feat: cameras saving/loading

This commit is contained in:
MihailRis
2024-07-11 22:45:57 +03:00
parent 45c4da048c
commit a013e7eefd
8 changed files with 66 additions and 17 deletions
+8 -6
View File
@@ -5,20 +5,22 @@
class Camera {
void updateVectors();
float fov;
float fov = 1.0f;
public:
glm::vec3 front;
glm::vec3 up;
glm::vec3 right;
glm::vec3 dir;
glm::vec3 front {};
glm::vec3 up {};
glm::vec3 right {};
glm::vec3 dir {};
glm::vec3 position;
glm::vec3 position {};
float zoom = 1.0f;
glm::mat4 rotation {1.0f};
bool perspective = true;
bool flipped = false;
float aspect = 0.0f;
Camera() {}
Camera(glm::vec3 position, float fov);
void rotate(float x, float y, float z);