From 563479552e2f491fb94e7fac5772f3c72cee962a Mon Sep 17 00:00:00 2001 From: Brian Date: Fri, 13 Jul 2007 09:25:57 -0600 Subject: Added basic occlusion counting --- src/mesa/state_tracker/st_atom_depth.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/mesa/state_tracker') diff --git a/src/mesa/state_tracker/st_atom_depth.c b/src/mesa/state_tracker/st_atom_depth.c index a1523e06c2..7fc51953dc 100644 --- a/src/mesa/state_tracker/st_atom_depth.c +++ b/src/mesa/state_tracker/st_atom_depth.c @@ -71,6 +71,10 @@ update_depth( struct st_context *st ) depth.func = gl_depth_func_to_sp(st->ctx->Depth.Func); depth.clear = st->ctx->Depth.Clear; + if (st->ctx->Query.CurrentOcclusionObject && + st->ctx->Query.CurrentOcclusionObject->Active) + depth.occlusion_count = 1; + if (memcmp(&depth, &st->state.depth, sizeof(depth)) != 0) { /* state has changed */ st->state.depth = depth; /* struct copy */ -- cgit v1.2.3