Rainbow trianglegit add .

This commit is contained in:
2026-02-20 20:24:42 +00:00
parent b55769bbf2
commit 253fd3006a
10 changed files with 21 additions and 31 deletions

View File

@@ -51,11 +51,16 @@ namespace cve {
}
std::vector<VkVertexInputAttributeDescription> CveModel::Vertex::getAttributeDescriptions() {
std::vector<VkVertexInputAttributeDescription> attributeDescriptions(1);
std::vector<VkVertexInputAttributeDescription> attributeDescriptions(2);
attributeDescriptions[0].binding = 0;
attributeDescriptions[0].location = 0;
attributeDescriptions[0].format = VK_FORMAT_R32G32_SFLOAT;
attributeDescriptions[0].offset = 0;
attributeDescriptions[0].offset = offsetof(Vertex, position);
attributeDescriptions[1].binding = 0;
attributeDescriptions[1].location = 1;
attributeDescriptions[1].format = VK_FORMAT_R32G32B32_SFLOAT;
attributeDescriptions[1].offset = offsetof(Vertex, color);
return attributeDescriptions;
}