24 lines
578 B
C++
24 lines
578 B
C++
#pragma once
|
|
|
|
// libs
|
|
#define GLM_FORCE_RADIANS
|
|
#define GLM_FORCE_DEPTH_ZERO_TO_ONE
|
|
#include <glm/glm.hpp>
|
|
|
|
namespace hk
|
|
{
|
|
class Camera
|
|
{
|
|
public:
|
|
Camera() = default;
|
|
~Camera() = default;
|
|
|
|
void setOrthographicProjection(float left, float right, float top, float bottom, float near, float far);
|
|
|
|
void setPerspectiveProjection(float fovY, float aspect, float near, float far);
|
|
|
|
const glm::mat4& getProjection() const { return m_projectionMatrix; }
|
|
private:
|
|
glm::mat4 m_projectionMatrix{1.0f};
|
|
};
|
|
} // namespace hk
|