aboutsummaryrefslogtreecommitdiff
path: root/src/vulkan_utils.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/vulkan_utils.hpp')
-rw-r--r--src/vulkan_utils.hpp16
1 files changed, 6 insertions, 10 deletions
diff --git a/src/vulkan_utils.hpp b/src/vulkan_utils.hpp
index 1647e91..c822caa 100644
--- a/src/vulkan_utils.hpp
+++ b/src/vulkan_utils.hpp
@@ -39,7 +39,7 @@ struct Vertex {
};
}
- static constexpr std::array<VkVertexInputAttributeDescription, 3> get_attr_descs() {
+ static constexpr std::array<VkVertexInputAttributeDescription, 2> get_attr_descs() {
return {
VkVertexInputAttributeDescription {
.location = 0,
@@ -51,25 +51,21 @@ struct Vertex {
.location = 1,
.binding = 0,
.format = VK_FORMAT_R32G32B32_SFLOAT,
- .offset = offsetof(Vertex, col),
- },
- VkVertexInputAttributeDescription {
- .location = 2,
- .binding = 0,
- .format = VK_FORMAT_R32G32_SFLOAT,
- .offset = offsetof(Vertex, uv),
+ .offset = offsetof(Vertex, normal),
},
};
}
engine::math::Vector3 pos;
- engine::math::Vector3 col;
- engine::math::Vector2 uv;
+ engine::math::Vector3 normal;
};
// TODO: move to a better place. Also, see TODOs for struct Vertex
struct UniformBufferObject {
alignas(16) engine::math::Matrix4 model, view, proj;
+ // TODO: should me Matrix3, but it isn't implemented yet
+ alignas(16) engine::math::Matrix4 camera_rot;
+ alignas(16) engine::math::Vector3 camera_loc;
};
}