#pragma once #include "Camera.h" #include using namespace glm; class Camera2D : public Camera { public: Camera2D(const vec2& size, const vec2& position = vec2(0.0f, 0.0f)); Camera2D(const vec3& size = vec3(2.0f, 2.0f, 2.0f), const vec3& position = vec3(0.0f, 0.0f, 0.0f)); void update_size(const vec3& size); void update_position(const vec3& position); void translate(const vec2& translation); void translate(const vec3& translation); const vec3& get_size() const { return m_size; } const vec3& get_position() const { return m_position; } private: void update_scale(); vec3 m_size; vec3 m_position; };