if (!is_drawing_points(brw) && !is_drawing_lines(brw))
dw2 |= GEN6_CLIP_XY_TEST;
+ /* BRW_NEW_VUE_MAP_GEOM_OUT */
+ const int max_vp_index =
+ (brw->vue_map_geom_out.slots_valid & VARYING_BIT_VIEWPORT) != 0 ?
+ ctx->Const.MaxViewports : 1;
+
BEGIN_BATCH(4);
OUT_BATCH(_3DSTATE_CLIP << 16 | (4 - 2));
OUT_BATCH(dw1);
OUT_BATCH(U_FIXED(0.125, 3) << GEN6_CLIP_MIN_POINT_WIDTH_SHIFT |
U_FIXED(255.875, 3) << GEN6_CLIP_MAX_POINT_WIDTH_SHIFT |
(_mesa_geometric_layers(fb) > 0 ? 0 : GEN6_CLIP_FORCE_ZERO_RTAINDEX) |
- ((ctx->Const.MaxViewports - 1) & GEN6_CLIP_MAX_VP_INDEX_MASK));
+ ((max_vp_index - 1) & GEN6_CLIP_MAX_VP_INDEX_MASK));
ADVANCE_BATCH();
}
BRW_NEW_GEOMETRY_PROGRAM |
BRW_NEW_META_IN_PROGRESS |
BRW_NEW_PRIMITIVE |
- BRW_NEW_RASTERIZER_DISCARD,
+ BRW_NEW_RASTERIZER_DISCARD |
+ BRW_NEW_VUE_MAP_GEOM_OUT,
},
.emit = upload_clip_state,
};
BRW_NEW_GEOMETRY_PROGRAM |
BRW_NEW_META_IN_PROGRESS |
BRW_NEW_PRIMITIVE |
- BRW_NEW_RASTERIZER_DISCARD,
+ BRW_NEW_RASTERIZER_DISCARD |
+ BRW_NEW_VUE_MAP_GEOM_OUT,
},
.emit = upload_clip_state,
};