dzn: No need to add another bind flag for clears if one is already present

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20400>
This commit is contained in:
Jesse Natalie 2022-12-20 14:14:32 -08:00 committed by Marge Bot
parent c59141d3c2
commit 8b79e6fb5e

View file

@ -240,7 +240,9 @@ dzn_image_create(struct dzn_device *device,
* destination. Both operations require the RT or DS cap flags. * destination. Both operations require the RT or DS cap flags.
*/ */
if ((image->vk.usage & VK_IMAGE_USAGE_TRANSFER_DST_BIT) && if ((image->vk.usage & VK_IMAGE_USAGE_TRANSFER_DST_BIT) &&
image->vk.tiling == VK_IMAGE_TILING_OPTIMAL) { image->vk.tiling == VK_IMAGE_TILING_OPTIMAL &&
(image->desc.Flags & (D3D12_RESOURCE_FLAG_ALLOW_RENDER_TARGET |
D3D12_RESOURCE_FLAG_ALLOW_DEPTH_STENCIL)) == D3D12_RESOURCE_FLAG_NONE) {
D3D12_FEATURE_DATA_FORMAT_SUPPORT dfmt_info = D3D12_FEATURE_DATA_FORMAT_SUPPORT dfmt_info =
dzn_physical_device_get_format_support(pdev, pCreateInfo->format); dzn_physical_device_get_format_support(pdev, pCreateInfo->format);