Module: Mesa Branch: staging/22.1 Commit: cbc81bdbf5982e98e06d56f14ef407a90c3291a3 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=cbc81bdbf5982e98e06d56f14ef407a90c3291a3
Author: Mykhailo Skorokhodov <[email protected]> Date: Sun Jun 19 23:56:12 2022 +0300 anv: Use sampleLocationsEnable for sample locations The spec says: "sampleLocationsEnable controls whether custom sample locations are used. If sampleLocationsEnable is VK_FALSE, the default sample locations are used and the values specified in sampleLocationsInfo are ignored." Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/6675 Signed-off-by: Mykhailo Skorokhodov <[email protected]> Reviewed-by: Lionel Landwerlin <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]> (cherry picked from commit 50b21fb6e41c3d7f91c96c8c8d8e88ee434b7d78) Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17160> --- src/intel/vulkan/anv_pipeline.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/intel/vulkan/anv_pipeline.c b/src/intel/vulkan/anv_pipeline.c index 6dc76362709..9eec762d9d9 100644 --- a/src/intel/vulkan/anv_pipeline.c +++ b/src/intel/vulkan/anv_pipeline.c @@ -2298,7 +2298,7 @@ copy_non_dynamic_state(struct anv_graphics_pipeline *pipeline, default: unreachable("invalid sample count"); } - if (sl_info) { + if (sl_info && sl_info->sampleLocationsEnable) { const VkSampleLocationEXT *positions = sl_info->sampleLocationsInfo.pSampleLocations; for (uint32_t i = 0; i < samples; i++) {
