undo descriptor count change
This commit is contained in:
parent
9340114d02
commit
f96d30ae9c
9
vulkan.d
9
vulkan.d
@ -233,7 +233,6 @@ struct Descriptor
|
||||
{
|
||||
DescType type;
|
||||
u32 binding;
|
||||
u32 count;
|
||||
union
|
||||
{
|
||||
Buffer buf;
|
||||
@ -565,11 +564,10 @@ CreatePipelineLayout(T)(Vulkan* vk, T layouts, u32 push_const_size, bool compute
|
||||
}
|
||||
|
||||
void
|
||||
CreateBuffer(Vulkan* vk, Descriptor* desc, BufferType type, u64 size, bool host_visible, DescType desc_type, u32 binding, u32 count = 1)
|
||||
CreateBuffer(Vulkan* vk, Descriptor* desc, BufferType type, u64 size, bool host_visible, DescType desc_type, u32 binding)
|
||||
{
|
||||
desc.type = desc_type;
|
||||
desc.binding = binding;
|
||||
desc.count = count;
|
||||
CreateBuffer(vk, &desc.buf, type, size, host_visible);
|
||||
}
|
||||
|
||||
@ -963,7 +961,6 @@ CreateImageView(Vulkan* vk, Descriptor* view, u32 w, u32 h, u32 ch, u8[] data, D
|
||||
ImageDescCheck(type);
|
||||
view.type = type;
|
||||
view.binding = binding;
|
||||
view.count = 1;
|
||||
CreateImageView(vk, &view.view, w, h, ch, data);
|
||||
}
|
||||
|
||||
@ -1036,7 +1033,6 @@ CreateImageView(Vulkan* vk, Descriptor* desc, u32 w, u32 h, Format format, Image
|
||||
ImageDescCheck(type);
|
||||
desc.type = type;
|
||||
desc.binding = binding;
|
||||
desc.count = 1;
|
||||
CreateImageView(vk, &desc.view, w, h, format, usage);
|
||||
}
|
||||
|
||||
@ -1170,7 +1166,6 @@ CreateBufferView(Vulkan* vk, Descriptor* desc, u64 size, Format format, DescType
|
||||
VkCheckA("CreateBufferView failure: vkCreateBufferView failed", result);
|
||||
|
||||
desc.binding = binding;
|
||||
desc.count = 1;
|
||||
desc.buf_view.size = size;
|
||||
}
|
||||
|
||||
@ -1985,7 +1980,7 @@ PrepareWrite(Vulkan* vk, VkWriteDescriptorSet* write, DescSet set, Descriptor* d
|
||||
write.descriptorType = desc.type;
|
||||
write.dstSet = set.handle;
|
||||
write.dstBinding = desc.binding;
|
||||
write.descriptorCount = desc.count;
|
||||
write.descriptorCount = 1;
|
||||
|
||||
switch(desc.type) with(DescType)
|
||||
{
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user