[Mesa-dev] [PATCH 3/3] i965: Remove redundant null check
Chad Versace
chad.versace at linux.intel.com
Tue Aug 14 16:58:22 PDT 2012
intel_renderbuffer_resolve_hiz checks if rb->mt is null, so there is no
need for the caller to do so.
Signed-off-by: Chad Versace <chad.versace at linux.intel.com>
---
src/mesa/drivers/dri/i965/brw_draw.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/src/mesa/drivers/dri/i965/brw_draw.c b/src/mesa/drivers/dri/i965/brw_draw.c
index 0b1a4e0..f9e4445 100644
--- a/src/mesa/drivers/dri/i965/brw_draw.c
+++ b/src/mesa/drivers/dri/i965/brw_draw.c
@@ -305,9 +305,8 @@ brw_predraw_resolve_buffers(struct brw_context *brw)
/* Resolve the depth buffer's HiZ buffer. */
depth_irb = intel_get_renderbuffer(ctx->DrawBuffer, BUFFER_DEPTH);
- if (depth_irb && depth_irb->mt) {
+ if (depth_irb)
intel_renderbuffer_resolve_hiz(intel, depth_irb);
- }
/* Resolve depth buffer of each enabled depth texture. */
for (int i = 0; i < BRW_MAX_TEX_UNIT; i++) {
--
1.7.11.4
More information about the mesa-dev
mailing list