mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-06-09 23:08:18 +02:00
jay: Handle facing that differs across subspans
Will be useful for multipolygon modes. Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/41872>
This commit is contained in:
parent
e3d7d4a77d
commit
b1b579293a
1 changed files with 4 additions and 3 deletions
|
|
@ -1506,9 +1506,10 @@ jay_emit_intrinsic(struct nir_to_jay_state *nj, nir_intrinsic_instr *intr)
|
|||
break;
|
||||
|
||||
case nir_intrinsic_load_front_face: {
|
||||
/* Bit 11 is facingness for the first polygon. TODO: Multipolygon. */
|
||||
jay_inst *and = jay_AND(b, JAY_TYPE_U32, jay_null(),
|
||||
jay_extract(nj->payload.u0, 9), BITFIELD_BIT(11));
|
||||
/* Bit 11 is facingness for subspans 1-2 and 5-6. */
|
||||
jay_inst *and =
|
||||
jay_EXTRACT_SUBSPAN_INFO(b, jay_null(), jay_extract(nj->payload.u0, 9),
|
||||
payload_u1(nj, 9, 1), BITFIELD_BIT(11));
|
||||
|
||||
/* The bit is actually backfacingness so check for equality with 0 */
|
||||
jay_set_conditional_mod(b, and, dst, GEN_CONDITION_EQ);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue