summaryrefslogtreecommitdiff
path: root/src/gallium/drivers/llvmpipe/lp_state_surface.c
diff options
context:
space:
mode:
authorKeith Whitwell <keithw@vmware.com>2010-09-16 10:45:52 +0100
committerKeith Whitwell <keithw@vmware.com>2010-09-16 17:34:19 +0100
commit5f00819cb382bdb70c29e2db3c6ff22a879bf10f (patch)
tree6c28495f4caef7c8610189ed011f50596b0e545c /src/gallium/drivers/llvmpipe/lp_state_surface.c
parent045ee4601179c44f815ce3842ef900b36d54c914 (diff)
llvmpipe: add LP_PERF flag to disable various aspects of rasterization
Allows disabling various operations (mainly texture-related, but will grow) to try & identify bottlenecks. Unlike LP_DEBUG, this is active even in release builds - which is necessary for performance investigation.
Diffstat (limited to 'src/gallium/drivers/llvmpipe/lp_state_surface.c')
-rw-r--r--src/gallium/drivers/llvmpipe/lp_state_surface.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gallium/drivers/llvmpipe/lp_state_surface.c b/src/gallium/drivers/llvmpipe/lp_state_surface.c
index 4b135aaf8b..cd1a5b1980 100644
--- a/src/gallium/drivers/llvmpipe/lp_state_surface.c
+++ b/src/gallium/drivers/llvmpipe/lp_state_surface.c
@@ -60,6 +60,10 @@ llvmpipe_set_framebuffer_state(struct pipe_context *pipe,
util_copy_framebuffer_state(&lp->framebuffer, fb);
+ if (LP_PERF & PERF_NO_DEPTH) {
+ pipe_surface_reference(&lp->framebuffer.zsbuf, NULL);
+ }
+
/* Tell draw module how deep the Z/depth buffer is */
if (lp->framebuffer.zsbuf) {
int depth_bits;