Commit 141dd8f2 authored by Erik Faye-Lund 's avatar Erik Faye-Lund

d3d12: report face as integer sysval

parent 869ad840
Pipeline #224151 waiting for manual action with stages
in 20 minutes and 36 seconds
......@@ -514,7 +514,7 @@ validate_geometry_shader_variant(struct d3d12_selection_context *sel_ctx)
if (sel_ctx->fill_mode_lowered != PIPE_POLYGON_MODE_FILL) {
key.fill_mode = sel_ctx->fill_mode_lowered;
key.cull_mode = sel_ctx->cull_mode_lowered;
key.has_front_face = (fs->initial->info.inputs_read & VARYING_BIT_FACE) ? 1 : 0;
key.has_front_face = (fs->initial->info.system_values_read & SYSTEM_BIT_FRONT_FACE) ? 1 : 0;
if (key.cull_mode != PIPE_FACE_NONE || key.has_front_face)
key.front_ccw = ctx->gfx_pipeline_state.rast->base.front_ccw ^ (ctx->flip_y < 0);
key.edge_flag_fix = needs_edge_flag_fix(ctx->initial_api_prim);
......@@ -635,7 +635,6 @@ d3d12_fill_shader_key(struct d3d12_selection_context *sel_ctx,
pipe_shader_type stage = sel->stage;
uint64_t system_generated_in_values =
VARYING_BIT_FACE |
VARYING_BIT_PNTC |
VARYING_BIT_PRIMITIVE_ID;
......@@ -821,10 +820,7 @@ select_shader_variant(struct d3d12_selection_context *sel_ctx, d3d12_shader_sele
}
if (key.fs.remap_front_facing) {
nir_foreach_variable(input, &new_nir_variant->inputs) {
if (input->data.location == VARYING_SLOT_FACE)
input->data.location = VARYING_SLOT_VAR12;
}
d3d12_forward_front_face(new_nir_variant);
nir_function_impl *impl = nir_shader_get_entrypoint(new_nir_variant);
nir_shader_gather_info(new_nir_variant, impl);
......
......@@ -256,6 +256,9 @@ d3d12_get_param(struct pipe_screen *pscreen, enum pipe_cap param)
case PIPE_CAP_TGSI_FS_COORD_ORIGIN_UPPER_LEFT:
return 1;
case PIPE_CAP_TGSI_FS_FACE_IS_INTEGER_SYSVAL:
return 1;
case PIPE_CAP_ACCELERATED:
return 1;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment