vulkan: vulkan_compute initialize base on plugin creation

This commit is contained in:
columbarius 2023-08-11 23:03:31 +02:00 committed by Wim Taymans
parent 402ed65a79
commit 06a1d5151b
3 changed files with 11 additions and 2 deletions

View file

@ -414,7 +414,6 @@ int spa_vulkan_init_stream(struct vulkan_compute_state *s, struct vulkan_stream
int spa_vulkan_prepare(struct vulkan_compute_state *s)
{
if (!s->prepared) {
CHECK(spa_vulkan_init(s));
CHECK(createFence(s));
CHECK(createDescriptors(s));
CHECK(createComputePipeline(s, s->shaderName));
@ -435,7 +434,6 @@ int spa_vulkan_unprepare(struct vulkan_compute_state *s)
vkDestroyPipeline(s->base.device, s->pipeline, NULL);
vkDestroyCommandPool(s->base.device, s->commandPool, NULL);
vkDestroyFence(s->base.device, s->fence, NULL);
spa_vulkan_deinit(s);
s->prepared = false;
}
return 0;