WIP crafter.math
This commit is contained in:
parent
98b775e33e
commit
84099f07ed
11 changed files with 139 additions and 310 deletions
|
|
@ -1,26 +1,18 @@
|
|||
module;
|
||||
|
||||
#include <cstdint>
|
||||
#define GLM_FORCE_RADIANS
|
||||
#define GLM_FORCE_DEPTH_ZERO_TO_ONE
|
||||
#define GLM_ENABLE_EXPERIMENTAL
|
||||
#include <glm/glm.hpp>
|
||||
#include <glm/gtc/matrix_transform.hpp>
|
||||
#include <glm/gtc/matrix_inverse.hpp>
|
||||
#include <glm/gtc/type_ptr.hpp>
|
||||
#include "VulkanBuffer.h"
|
||||
#include "camera.hpp"
|
||||
|
||||
export module Crafter.Graphics:Camera;
|
||||
import :VulkanBuffer;
|
||||
import Crafter.Component;
|
||||
import Crafter.Math;
|
||||
|
||||
namespace Crafter {
|
||||
export class Camera : public Component {
|
||||
public:
|
||||
glm::mat4 projection;
|
||||
glm::mat4 view;
|
||||
glm::mat4 projectionView;
|
||||
Camera();
|
||||
Matrix<float, 4, 4, 1> projection;
|
||||
Matrix<float, 4, 4, 1> view;
|
||||
Matrix<float, 4, 4, 1> projectionView;
|
||||
Camera(float fov, float aspectRatio, float near, float far);
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue