diff --git a/src/renderer/camera.hpp b/src/renderer/camera.hpp index 5783e57..09a0156 100644 --- a/src/renderer/camera.hpp +++ b/src/renderer/camera.hpp @@ -12,6 +12,7 @@ public: glm::mat4 GetViewMatrix(); glm::mat4 GetProjectionMatrix(); + glm::mat4 GetFrustrumMatrix(); void UpdateProjection(int width, int height); @@ -34,7 +35,7 @@ private: glm::mat4 viewMatrix = {}; glm::mat4 projMatrix = {}; - + }; #endif diff --git a/src/world/entity.cpp b/src/world/entity.cpp index d41965c..f3bc7fc 100644 --- a/src/world/entity.cpp +++ b/src/world/entity.cpp @@ -13,6 +13,7 @@ Entity::Entity(glm::vec3 postion, glm::vec3 direction, std::shared_ptr c } } +<<<<<<< HEAD Player::Player(glm::vec3 position, glm::vec3 direction) { } @@ -29,3 +30,21 @@ void Player::HandleMouseSDL(SDL_Event e) { void UpdateDirection(glm::vec3 direction); void CameaUpdateProjection(int xres, int yres); +======= +Player::Player(glm::vec3 position, glm::vec3 direction, std::shared_ptr camera) + : Entity(position, direction, camera) { + + camera->Position = + +} + +Player(glm::vec3 position, glm::vec3 direction = {0.0f, 0.0f, 0.0f}); + +void Move(Uint8* state); +void HandleMouse(SDL_Event e); + +void UpdatePosition(glm::vec3 position); +void UpdateDirection(glm::vec3 direction); + +void CameaUpdateProjection(int xres, int yres); +>>>>>>> 0b6a3b520cd2e51e4d8cf7716ec4ddcf51297e2e diff --git a/src/world/entity.hpp b/src/world/entity.hpp index e994d67..57a235c 100644 --- a/src/world/entity.hpp +++ b/src/world/entity.hpp @@ -10,8 +10,6 @@ public: Entity(glm::vec3 position, glm::vec3 direction = { 0.0f, 0.0f, 0.0f }, std::shared_ptr camera = std::make_shared()); - bool Player = false; - // World position, 1.7 units below the // camera position. glm::vec3 Position; @@ -36,7 +34,7 @@ public: class Player : public Entity { public: - Player(glm::vec3 position, glm::vec3 direction = {0.0f, 0.0f, 0.0f}); + Player(glm::vec3 position, glm::vec3 direction, std::shared_ptr camera); void Move(Uint8* state); void HandleMouseSDL(SDL_Event e);