Vulkan/Swapchain: Make Acquire Next Image constant
Former-commit-id: 54d3fde63a01b138b8d391d9e318c618e69c5eed [formerly c44a46a3ca62d65f3279bd44f1647996fd03b38e] Former-commit-id: 25bf025b3853879b0eee577ad4bb7ffe9a96fd4a
This commit is contained in:
parent
7989253066
commit
e332f2f77e
|
|
@ -39,7 +39,7 @@ namespace Nz
|
|||
DeviceHandle m_device;
|
||||
VkAllocationCallbacks m_allocator;
|
||||
VkType m_handle;
|
||||
VkResult m_lastErrorCode;
|
||||
mutable VkResult m_lastErrorCode;
|
||||
};
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ namespace Nz
|
|||
Swapchain(Swapchain&&) = default;
|
||||
~Swapchain() = default;
|
||||
|
||||
inline bool AcquireNextImage(Nz::UInt64 timeout, VkSemaphore semaphore, VkFence fence, UInt32* imageIndex);
|
||||
inline bool AcquireNextImage(Nz::UInt64 timeout, VkSemaphore semaphore, VkFence fence, UInt32* imageIndex) const;
|
||||
|
||||
inline bool Create(const DeviceHandle& device, const VkSwapchainCreateInfoKHR& createInfo, const VkAllocationCallbacks* allocator = nullptr);
|
||||
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@ namespace Nz
|
|||
{
|
||||
namespace Vk
|
||||
{
|
||||
inline bool Swapchain::AcquireNextImage(Nz::UInt64 timeout, VkSemaphore semaphore, VkFence fence, UInt32* imageIndex)
|
||||
inline bool Swapchain::AcquireNextImage(Nz::UInt64 timeout, VkSemaphore semaphore, VkFence fence, UInt32* imageIndex) const
|
||||
{
|
||||
m_lastErrorCode = m_device->vkAcquireNextImageKHR(*m_device, m_handle, timeout, semaphore, fence, imageIndex);
|
||||
switch (m_lastErrorCode)
|
||||
|
|
|
|||
Loading…
Reference in New Issue