| 796 | } |
| 797 | |
| 798 | void AllocInfo::Destroy() |
| 799 | { |
| 800 | if(m_Image) |
| 801 | { |
| 802 | assert(!m_Buffer); |
| 803 | vkDestroyImage(g_hDevice, m_Image, g_Allocs); |
| 804 | m_Image = VK_NULL_HANDLE; |
| 805 | } |
| 806 | if(m_Buffer) |
| 807 | { |
| 808 | assert(!m_Image); |
| 809 | vkDestroyBuffer(g_hDevice, m_Buffer, g_Allocs); |
| 810 | m_Buffer = VK_NULL_HANDLE; |
| 811 | } |
| 812 | if(m_Allocation) |
| 813 | { |
| 814 | vmaFreeMemory(g_hAllocator, m_Allocation); |
| 815 | m_Allocation = VK_NULL_HANDLE; |
| 816 | } |
| 817 | } |
| 818 | |
| 819 | class StagingBufferCollection |
| 820 | { |
no test coverage detected