panvk: Override the default GetRender[in]AreaGranularityKHR()
Expose the real optimal render area granularity to users, so they can optimize their rendering operations accordingly. Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com> Suggested-by: Erik Faye-Lund <erik.faye-lund@collabora.com> Acked-by: Erik Faye-Lund <erik.faye-lund@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29443>
This commit is contained in:
@@ -217,3 +217,19 @@ panvk_per_arch(destroy_device)(struct panvk_device *device,
|
||||
pan_kmod_dev_destroy(device->kmod.dev);
|
||||
vk_free(&device->vk.alloc, device);
|
||||
}
|
||||
|
||||
VKAPI_ATTR void VKAPI_CALL
|
||||
panvk_per_arch(GetRenderAreaGranularity)(VkDevice device,
|
||||
VkRenderPass renderPass,
|
||||
VkExtent2D *pGranularity)
|
||||
{
|
||||
*pGranularity = (VkExtent2D){32, 32};
|
||||
}
|
||||
|
||||
VKAPI_ATTR void VKAPI_CALL
|
||||
panvk_per_arch(GetRenderingAreaGranularityKHR)(
|
||||
VkDevice _device, const VkRenderingAreaInfoKHR *pRenderingAreaInfo,
|
||||
VkExtent2D *pGranularity)
|
||||
{
|
||||
*pGranularity = (VkExtent2D){32, 32};
|
||||
}
|
||||
|
Reference in New Issue
Block a user