Introduce copy constructor and assignment operator for vk::raii classes that hold handles without a destructor.

This commit is contained in:
asuessenbach
2022-03-22 12:26:28 +01:00
parent 3740f14c38
commit 23c11fe38d
36 changed files with 96 additions and 56 deletions

View File

@@ -99,7 +99,7 @@ int main( int /*argc*/, char ** /*argv*/ )
#if !defined( NDEBUG )
vk::raii::DebugUtilsMessengerEXT debugUtilsMessenger( instance, vk::su::makeDebugUtilsMessengerCreateInfoEXT() );
#endif
vk::raii::PhysicalDevice physicalDevice = std::move( vk::raii::PhysicalDevices( instance ).front() );
vk::raii::PhysicalDevice physicalDevice = vk::raii::PhysicalDevices( instance ).front();
vk::FormatProperties formatProperties = physicalDevice.getFormatProperties( vk::Format::eR8G8B8A8Unorm );
if ( !( formatProperties.optimalTilingFeatures & vk::FormatFeatureFlagBits::eColorAttachment ) )