From 4ef7d93a941257b18506eae056631e8f4a11f893 Mon Sep 17 00:00:00 2001 From: Marek Olšák Date: Sun, 5 Jul 2015 16:34:59 +0200 Subject: cso: remove clip state handling There is no need for this. v2: handle redundant clip state changes in st/mesa --- src/mesa/state_tracker/st_atom_clip.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src/mesa/state_tracker/st_atom_clip.c') diff --git a/src/mesa/state_tracker/st_atom_clip.c b/src/mesa/state_tracker/st_atom_clip.c index f82c1332afc..506a770499f 100644 --- a/src/mesa/state_tracker/st_atom_clip.c +++ b/src/mesa/state_tracker/st_atom_clip.c @@ -59,8 +59,11 @@ static void update_clip( struct st_context *st ) memcpy(clip.ucp, use_eye ? ctx->Transform.EyeUserPlane : ctx->Transform._ClipUserPlane, sizeof(clip.ucp)); - st->state.clip = clip; - cso_set_clip(st->cso_context, &clip); + + if (memcmp(&st->state.clip, &clip, sizeof(clip)) != 0) { + st->state.clip = clip; + st->pipe->set_clip_state(st->pipe, &clip); + } } -- cgit v1.2.3