actually set pool sizez properly
This commit is contained in:
@@ -29,11 +29,11 @@ const char* *vkGetGryphnDeviceExtensions(uint32_t* outCount, VkPhysicalDevice de
|
|||||||
}
|
}
|
||||||
free(vkExtensions);
|
free(vkExtensions);
|
||||||
|
|
||||||
// if (supportsDescriptorPoolOverallocation) {
|
if (supportsDescriptorPoolOverallocation) {
|
||||||
// count++;
|
count++;
|
||||||
// extensiosns = realloc(extensiosns, sizeof(const char*) * count);
|
extensiosns = realloc(extensiosns, sizeof(const char*) * count);
|
||||||
// extensiosns[(count - 1)] = VK_NV_DESCRIPTOR_POOL_OVERALLOCATION_EXTENSION_NAME;
|
extensiosns[(count - 1)] = VK_NV_DESCRIPTOR_POOL_OVERALLOCATION_EXTENSION_NAME;
|
||||||
// }
|
}
|
||||||
|
|
||||||
*outCount = count;
|
*outCount = count;
|
||||||
|
|
||||||
|
@@ -66,10 +66,23 @@ gnUniform* gnUniformPoolAllocateUniformsFn(gnUniformPool pool, gnUniformAllocati
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
uint32_t count = 0;
|
||||||
|
VkDescriptorPoolSize poolSizes[2] = {};
|
||||||
|
|
||||||
|
if (uniformBufferSize.descriptorCount > 0) {
|
||||||
|
poolSizes[count] = uniformBufferSize;
|
||||||
|
count++;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (imageSize.descriptorCount > 0) {
|
||||||
|
poolSizes[count] = imageSize;
|
||||||
|
count++;
|
||||||
|
}
|
||||||
|
|
||||||
VkDescriptorPoolCreateInfo poolInfo = {
|
VkDescriptorPoolCreateInfo poolInfo = {
|
||||||
.sType = VK_STRUCTURE_TYPE_DESCRIPTOR_POOL_CREATE_INFO,
|
.sType = VK_STRUCTURE_TYPE_DESCRIPTOR_POOL_CREATE_INFO,
|
||||||
.poolSizeCount = 2,
|
.poolSizeCount = count,
|
||||||
.pPoolSizes = (VkDescriptorPoolSize[]){ uniformBufferSize, imageSize },
|
.pPoolSizes = poolSizes,
|
||||||
.maxSets = allocInfo.setCount
|
.maxSets = allocInfo.setCount
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user