| 448 | } |
| 449 | |
| 450 | VkFormatFeatureFlags2 Device::FormatFeaturesBuffer(VkFormat format) const { |
| 451 | if (IsEnabledExtension(VK_KHR_FORMAT_FEATURE_FLAGS_2_EXTENSION_NAME) || |
| 452 | target_api_version_ >= VK_API_VERSION_1_3) { |
| 453 | VkFormatProperties3 fmt_props_3 = vku::InitStructHelper(); |
| 454 | VkFormatProperties2 fmt_props_2 = vku::InitStructHelper(&fmt_props_3); |
| 455 | vk::GetPhysicalDeviceFormatProperties2(Physical(), format, &fmt_props_2); |
| 456 | return fmt_props_3.bufferFeatures; |
| 457 | } else { |
| 458 | VkFormatProperties format_properties; |
| 459 | vk::GetPhysicalDeviceFormatProperties(Physical(), format, &format_properties); |
| 460 | return format_properties.bufferFeatures; |
| 461 | } |
| 462 | } |
| 463 | |
| 464 | void Device::Wait() const { ASSERT_EQ(VK_SUCCESS, vk::DeviceWaitIdle(handle())); } |
| 465 |
no test coverage detected