mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-30 20:50:09 +01:00
vulkan: Add a vk_fragment_shading_rate_is_disabled() helper
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31585>
This commit is contained in:
parent
29dd0236b5
commit
746ea7b0cd
1 changed files with 9 additions and 0 deletions
|
|
@ -427,6 +427,15 @@ struct vk_fragment_shading_rate_state {
|
|||
VkFragmentShadingRateCombinerOpKHR combiner_ops[2];
|
||||
};
|
||||
|
||||
static inline bool
|
||||
vk_fragment_shading_rate_is_disabled(const struct vk_fragment_shading_rate_state *fsr)
|
||||
{
|
||||
return fsr->fragment_size.width == 1 &&
|
||||
fsr->fragment_size.height == 1 &&
|
||||
fsr->combiner_ops[0] == VK_FRAGMENT_SHADING_RATE_COMBINER_OP_KEEP_KHR &&
|
||||
fsr->combiner_ops[1] == VK_FRAGMENT_SHADING_RATE_COMBINER_OP_KEEP_KHR;
|
||||
}
|
||||
|
||||
/***/
|
||||
struct vk_sample_locations_state {
|
||||
/** VkSampleLocationsInfoEXT::sampleLocationsPerPixel */
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue