mesh correct and textures too

This commit is contained in:
zomseffen 2024-04-27 08:06:18 +02:00
parent 31d4a139ef
commit 8afb2d2a3c
5 changed files with 9 additions and 5 deletions

View file

@ -41,14 +41,14 @@ impl Vertex {
.binding(0)
.location(1)
.format(vk::Format::R32G32B32_SFLOAT)
.offset(size_of::<Vec2>() as u32)
.offset(size_of::<Vec3>() as u32)
.build();
let tex_coord = vk::VertexInputAttributeDescription::builder()
.binding(0)
.location(2)
.format(vk::Format::R32G32_SFLOAT)
.offset((size_of::<Vec2>() + size_of::<Vec3>()) as u32)
.offset((size_of::<Vec3>() + size_of::<Vec3>()) as u32)
.build();
[pos, color, tex_coord]
}