summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers
diff options
context:
space:
mode:
authorPaul Berry <[email protected]>2011-09-23 21:55:20 -0700
committerPaul Berry <[email protected]>2011-09-28 11:38:04 -0700
commitf02ed012c9d3346ffdea9ecbf03c5818e40a24c7 (patch)
treec4285c960580be5cec2da0be469186a1d968a4da /src/mesa/drivers
parent64ce64a3f88f0c33a3f9a97f231bd98983887e27 (diff)
i965: don't intepolate clip distances on pre-GEN6.
On pre-GEN6 chips, the VUE slots set aside for clip distance aren't actually used, so there is no reason for the clipper to waste time interpolating them. When commit 62bad54727690bff5ed42a74272e7822fd36cdb6 changed the enum value used to represent these VUE slots, that caused the clipper to start interpolating them as an accidental side effect. This patch reverts to the old clipper behavior. Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/mesa/drivers')
-rw-r--r--src/mesa/drivers/dri/i965/brw_clip_util.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_clip_util.c b/src/mesa/drivers/dri/i965/brw_clip_util.c
index a12dab6b350..15abe166848 100644
--- a/src/mesa/drivers/dri/i965/brw_clip_util.c
+++ b/src/mesa/drivers/dri/i965/brw_clip_util.c
@@ -160,8 +160,14 @@ void brw_clip_interp_vertex( struct brw_clip_compile *c,
brw_MOV(p, deref_4f(dest_ptr, delta), brw_imm_f(1));
else
brw_MOV(p, deref_4f(dest_ptr, delta), deref_4f(v0_ptr, delta));
- } else if (vert_result == VERT_RESULT_PSIZ) {
- /* PSIZ doesn't need interpolation */
+ } else if (vert_result == VERT_RESULT_PSIZ ||
+ vert_result == VERT_RESULT_CLIP_DIST0 ||
+ vert_result == VERT_RESULT_CLIP_DIST1) {
+ /* PSIZ doesn't need interpolation because it isn't used by the
+ * fragment shader. CLIP_DIST0 and CLIP_DIST1 don't need
+ * intepolation because on pre-GEN6, these are just placeholder VUE
+ * slots that don't perform any action.
+ */
} else if (vert_result < VERT_RESULT_MAX) {
/* This is a true vertex result (and not a special value for the VUE
* header), so interpolate: