diff options
Diffstat (limited to 'src/mesa')
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_vec4.cpp | 2 | ||||
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_vec4.h | 6 | ||||
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp | 2 | ||||
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_vs.c | 5 |
4 files changed, 3 insertions, 12 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_vec4.cpp b/src/mesa/drivers/dri/i965/brw_vec4.cpp index d3ee9a1f4c9..2bc8cc4a676 100644 --- a/src/mesa/drivers/dri/i965/brw_vec4.cpp +++ b/src/mesa/drivers/dri/i965/brw_vec4.cpp @@ -1443,7 +1443,7 @@ vec4_visitor::run() } base_ir = NULL; - if (key->userclip_active && !key->uses_clip_distance) + if (key->userclip_active && !prog->UsesClipDistanceOut) setup_uniform_clipplane_values(); emit_thread_end(); diff --git a/src/mesa/drivers/dri/i965/brw_vec4.h b/src/mesa/drivers/dri/i965/brw_vec4.h index 41d91e5c49d..1039d456524 100644 --- a/src/mesa/drivers/dri/i965/brw_vec4.h +++ b/src/mesa/drivers/dri/i965/brw_vec4.h @@ -64,12 +64,6 @@ struct brw_vec4_prog_key { */ GLuint nr_userclip_plane_consts:4; - /** - * True if the shader uses gl_ClipDistance, regardless of whether any clip - * flags are enabled. - */ - GLuint uses_clip_distance:1; - GLuint clamp_vertex_color:1; struct brw_sampler_prog_key_data tex; diff --git a/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp b/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp index 231815f12d4..1752ece5524 100644 --- a/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp +++ b/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp @@ -2789,7 +2789,7 @@ vec4_visitor::emit_vertex() } /* Lower legacy ff and ClipVertex clipping to clip distances */ - if (key->userclip_active && !key->uses_clip_distance) { + if (key->userclip_active && !prog->UsesClipDistanceOut) { current_annotation = "user clip distances"; output_reg[VARYING_SLOT_CLIP_DIST0] = dst_reg(this, glsl_type::vec4_type); diff --git a/src/mesa/drivers/dri/i965/brw_vs.c b/src/mesa/drivers/dri/i965/brw_vs.c index 04cf857c98d..407d3976adf 100644 --- a/src/mesa/drivers/dri/i965/brw_vs.c +++ b/src/mesa/drivers/dri/i965/brw_vs.c @@ -370,8 +370,6 @@ brw_vs_debug_recompile(struct brw_context *brw, old_key->base.nr_userclip_plane_consts, key->base.nr_userclip_plane_consts); - found |= key_debug(brw, "clip distance enable", - old_key->base.uses_clip_distance, key->base.uses_clip_distance); found |= key_debug(brw, "copy edgeflag", old_key->copy_edgeflag, key->copy_edgeflag); found |= key_debug(brw, "PointCoord replace", @@ -396,8 +394,7 @@ brw_setup_vec4_key_clip_info(struct brw_context *brw, struct gl_context *ctx = &brw->ctx; key->userclip_active = (ctx->Transform.ClipPlanesEnabled != 0); - key->uses_clip_distance = program_uses_clip_distance; - if (key->userclip_active && !key->uses_clip_distance) { + if (key->userclip_active && !program_uses_clip_distance) { key->nr_userclip_plane_consts = _mesa_logbase2(ctx->Transform.ClipPlanesEnabled) + 1; } |