radv: Reject linear modifier for video decode DPB
Reviewed-by: Dave Airlie <airlied@redhat.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36311>
This commit is contained in:
@@ -831,8 +831,14 @@ radv_check_modifier_support(struct radv_physical_device *pdev, const VkPhysicalD
|
||||
return VK_ERROR_FORMAT_NOT_SUPPORTED;
|
||||
|
||||
const bool video = info->usage & (VK_IMAGE_USAGE_VIDEO_DECODE_DST_BIT_KHR | VK_IMAGE_USAGE_VIDEO_ENCODE_SRC_BIT_KHR);
|
||||
if (video && !ac_modifier_supports_video(&pdev->info, modifier))
|
||||
return VK_ERROR_FORMAT_NOT_SUPPORTED;
|
||||
if (video) {
|
||||
if (!ac_modifier_supports_video(&pdev->info, modifier))
|
||||
return VK_ERROR_FORMAT_NOT_SUPPORTED;
|
||||
|
||||
/* Decode DPB and output coincide (tier3) requires tiling. */
|
||||
if (info->usage & VK_IMAGE_USAGE_VIDEO_DECODE_DPB_BIT_KHR && modifier == DRM_FORMAT_MOD_LINEAR)
|
||||
return VK_ERROR_FORMAT_NOT_SUPPORTED;
|
||||
}
|
||||
|
||||
/* We can expand this as needed and implemented but there is not much demand
|
||||
* for more.
|
||||
|
||||
Reference in New Issue
Block a user