Function Prototype
vkGetRenderingAreaGranularityKHR
Returns the granularity for dynamic rendering optimal render area
To query the render area granularity for a render pass instance, call:
void vkGetRenderingAreaGranularityKHR(
VkDevice device,
const VkRenderingAreaInfoKHR* pRenderingAreaInfo,
VkExtent2D* pGranularity);
device
is the logical device that owns the render pass instance.pRenderingAreaInfo
is a pointer to a VkRenderingAreaInfoKHR structure specifying details of the render pass instance to query the render area granularity for.pGranularity
is a pointer to a VkExtent2D structure in which the granularity is returned.
The conditions leading to an optimal renderArea
are:
- the
offset.x
member inrenderArea
is a multiple of thewidth
member of the returned VkExtent2D (the horizontal granularity). - the
offset.y
member inrenderArea
is a multiple of theheight
member of the returned VkExtent2D (the vertical granularity). - either the
extent.width
member inrenderArea
is a multiple of the horizontal granularity oroffset.x
+extent.width
is equal to thewidth
of each attachment used in the render pass instance. - either the
extent.height
member inrenderArea
is a multiple of the vertical granularity oroffset.y
+extent.height
is equal to theheight
of each attachment used in the render pass instance.
Valid Usage (Implicit)
VUID-vkGetRenderingAreaGranularityKHR-device-parameter
device
must be a valid VkDevice handle
VUID-vkGetRenderingAreaGranularityKHR-pRenderingAreaInfo-parameter
pRenderingAreaInfo
must be a valid pointer to a valid VkRenderingAreaInfoKHR structure
VUID-vkGetRenderingAreaGranularityKHR-pGranularity-parameter
pGranularity
must be a valid pointer to a VkExtent2D structure