@@ -401,6 +401,7 @@ std::unique_ptr<CVulkanPhysicalDevice> CVulkanPhysicalDevice::create(core::smart
401401 // vulkan12Properties.denormBehaviorIndependence;
402402 // vulkan12Properties.denormBehaviorIndependence;
403403
404+ // ! preserve of 16bit float checked later when features are known
404405 if (!vulkan12Properties.shaderSignedZeroInfNanPreserveFloat32 )
405406 return nullptr ;
406407 properties.limits .shaderSignedZeroInfNanPreserveFloat64 = vulkan12Properties.shaderSignedZeroInfNanPreserveFloat64 ;
@@ -442,8 +443,8 @@ std::unique_ptr<CVulkanPhysicalDevice> CVulkanPhysicalDevice::create(core::smart
442443 properties.limits .maxDescriptorSetUpdateAfterBindStorageImages = vulkan12Properties.maxDescriptorSetUpdateAfterBindStorageImages ;
443444 properties.limits .maxDescriptorSetUpdateAfterBindInputAttachments = vulkan12Properties.maxDescriptorSetUpdateAfterBindInputAttachments ;
444445
445- properties.limits .supportedDepthResolveModes = static_cast <SPhysicalDeviceLimits::RESOLVE_MODE_FLAGS >(vulkan12Properties.supportedDepthResolveModes );
446- properties.limits .supportedStencilResolveModes = static_cast <SPhysicalDeviceLimits::RESOLVE_MODE_FLAGS >(vulkan12Properties.supportedStencilResolveModes );
446+ properties.limits .supportedDepthResolveModes = static_cast <nbl::hlsl::ResolveModeFlags >(vulkan12Properties.supportedDepthResolveModes );
447+ properties.limits .supportedStencilResolveModes = static_cast <nbl::hlsl::ResolveModeFlags >(vulkan12Properties.supportedStencilResolveModes );
447448
448449 if (!vulkan12Properties.independentResolve || !vulkan12Properties.independentResolveNone )
449450 return nullptr ;
@@ -903,6 +904,13 @@ std::unique_ptr<CVulkanPhysicalDevice> CVulkanPhysicalDevice::create(core::smart
903904 properties.limits .shaderSharedInt64Atomics = vulkan12Features.shaderSharedInt64Atomics ;
904905
905906 properties.limits .shaderFloat16 = vulkan12Features.shaderFloat16 ;
907+ if (!vulkan12Features.shaderFloat16 )
908+ {
909+ // only fail if 16bit floats can be used
910+ if (!vulkan12Properties.shaderSignedZeroInfNanPreserveFloat16 )
911+ return nullptr ;
912+ }
913+
906914 if (!vulkan12Features.shaderInt8 )
907915 return nullptr ;
908916
@@ -1897,4 +1905,4 @@ core::smart_refctd_ptr<ILogicalDevice> CVulkanPhysicalDevice::createLogicalDevic
18971905 return core::make_smart_refctd_ptr<CVulkanLogicalDevice>(core::smart_refctd_ptr<const IAPIConnection>(m_initData.api ),m_rdoc_api,this ,vk_device,params);
18981906}
18991907
1900- }
1908+ }
0 commit comments