const BITSET_WORD *dynamic,
const struct vk_multisample_state *ms,
const struct vk_fragment_shading_rate_state *fsr,
- const struct vk_render_pass_state *rp)
+ const struct vk_render_pass_state *rp,
+ const enum brw_sometimes is_mesh)
{
const struct anv_device *device = pipeline->base.device;
key->persample_interp = BRW_SOMETIMES;
}
+ key->mesh_input = is_mesh;
+
/* Vulkan doesn't support fixed-function alpha test */
key->alpha_test_replicate_alpha = false;
state->rs == NULL ||
!state->rs->rasterizer_discard_enable ||
BITSET_TEST(state->dynamic, MESA_VK_DYNAMIC_RS_RASTERIZER_DISCARD_ENABLE);
+ enum brw_sometimes is_mesh = BRW_NEVER;
+ if (device->vk.enabled_extensions.EXT_mesh_shader) {
+ if (anv_pipeline_base_has_stage(pipeline, MESA_SHADER_VERTEX))
+ is_mesh = BRW_NEVER;
+ else if (anv_pipeline_base_has_stage(pipeline, MESA_SHADER_MESH))
+ is_mesh = BRW_ALWAYS;
+ else {
+ assert(pipeline->base.type == ANV_PIPELINE_GRAPHICS_LIB);
+ is_mesh = BRW_SOMETIMES;
+ }
+ }
populate_wm_prog_key(&stages[s],
pipeline,
state->dynamic,
raster_enabled ? state->ms : NULL,
- state->fsr, state->rp);
+ state->fsr, state->rp, is_mesh);
break;
}