vk/0.132: Add vkDestroyFence()
This commit is contained in:
@@ -2010,6 +2010,7 @@ typedef VkResult (VKAPI *PFN_vkGetObjectMemoryRequirements)(VkDevice device, VkO
|
||||
typedef VkResult (VKAPI *PFN_vkQueueBindSparseBufferMemory)(VkQueue queue, VkBuffer buffer, VkDeviceSize rangeOffset, VkDeviceSize rangeSize, VkDeviceMemory mem, VkDeviceSize memOffset);
|
||||
typedef VkResult (VKAPI *PFN_vkQueueBindSparseImageMemory)(VkQueue queue, VkImage image, const VkImageMemoryBindInfo* pBindInfo, VkDeviceMemory mem, VkDeviceSize memOffset);
|
||||
typedef VkResult (VKAPI *PFN_vkCreateFence)(VkDevice device, const VkFenceCreateInfo* pCreateInfo, VkFence* pFence);
|
||||
typedef VkResult (VKAPI *PFN_vkDestroyFence)(VkDevice device, VkFence fence);
|
||||
typedef VkResult (VKAPI *PFN_vkResetFences)(VkDevice device, uint32_t fenceCount, const VkFence* pFences);
|
||||
typedef VkResult (VKAPI *PFN_vkGetFenceStatus)(VkDevice device, VkFence fence);
|
||||
typedef VkResult (VKAPI *PFN_vkWaitForFences)(VkDevice device, uint32_t fenceCount, const VkFence* pFences, VkBool32 waitAll, uint64_t timeout);
|
||||
@@ -2261,6 +2262,10 @@ VkResult VKAPI vkCreateFence(
|
||||
const VkFenceCreateInfo* pCreateInfo,
|
||||
VkFence* pFence);
|
||||
|
||||
VkResult VKAPI vkDestroyFence(
|
||||
VkDevice device,
|
||||
VkFence fence);
|
||||
|
||||
VkResult VKAPI vkResetFences(
|
||||
VkDevice device,
|
||||
uint32_t fenceCount,
|
||||
|
||||
+16
-3
@@ -1353,9 +1353,8 @@ anv_fence_destroy(struct anv_device *device,
|
||||
|
||||
assert(obj_type == VK_OBJECT_TYPE_FENCE);
|
||||
|
||||
anv_gem_munmap(fence->bo.map, fence->bo.size);
|
||||
anv_gem_close(device, fence->bo.gem_handle);
|
||||
anv_device_free(device, fence);
|
||||
anv_DestroyFence(anv_device_to_handle(device),
|
||||
anv_fence_to_handle(fence));
|
||||
}
|
||||
|
||||
VkResult anv_CreateFence(
|
||||
@@ -1423,6 +1422,20 @@ VkResult anv_CreateFence(
|
||||
return result;
|
||||
}
|
||||
|
||||
VkResult anv_DestroyFence(
|
||||
VkDevice _device,
|
||||
VkFence _fence)
|
||||
{
|
||||
ANV_FROM_HANDLE(anv_device, device, _device);
|
||||
ANV_FROM_HANDLE(anv_fence, fence, _fence);
|
||||
|
||||
anv_gem_munmap(fence->bo.map, fence->bo.size);
|
||||
anv_gem_close(device, fence->bo.gem_handle);
|
||||
anv_device_free(device, fence);
|
||||
|
||||
return VK_SUCCESS;
|
||||
}
|
||||
|
||||
VkResult anv_ResetFences(
|
||||
VkDevice _device,
|
||||
uint32_t fenceCount,
|
||||
|
||||
Reference in New Issue
Block a user