Refactor parent member of the vk::raii classes.

This commit is contained in:
asuessenbach
2021-10-20 16:55:30 +02:00
parent 14bfefb209
commit e725ff31bd
4 changed files with 1296 additions and 1236 deletions

View File

@@ -48,8 +48,8 @@ int main( int /*argc*/, char ** /*argv*/ )
<< "physicalDevices:\n";
for ( size_t j = 0; j < groupProperties[i].physicalDeviceCount; j++ )
{
vk::raii::PhysicalDevice physicalDevice( static_cast<VkPhysicalDevice>( groupProperties[i].physicalDevices[j] ),
instance.getDispatcher() );
vk::raii::PhysicalDevice physicalDevice(
instance, static_cast<VkPhysicalDevice>( groupProperties[i].physicalDevices[j] ) );
std::cout << "\t\t" << j << " : " << physicalDevice.getProperties().deviceName << "\n";
}
std::cout << "\t"
@@ -58,8 +58,8 @@ int main( int /*argc*/, char ** /*argv*/ )
if ( 1 < groupProperties[i].physicalDeviceCount )
{
vk::raii::PhysicalDevice physicalDevice( static_cast<VkPhysicalDevice>( groupProperties[i].physicalDevices[0] ),
instance.getDispatcher() );
vk::raii::PhysicalDevice physicalDevice(
instance, static_cast<VkPhysicalDevice>( groupProperties[i].physicalDevices[0] ) );
// get the QueueFamilyProperties of the first PhysicalDevice
std::vector<vk::QueueFamilyProperties> queueFamilyProperties = physicalDevice.getQueueFamilyProperties();