[Mesa-dev] [PATCH 01/12] intel: Add flag intel_context.use_hiz

chad at chad-versace.us chad at chad-versace.us
Fri Apr 29 18:04:51 PDT 2011


From: Chad Versace <chad.versace at intel.com>

Currently, it is always set it to false. Once the HiZ implementation is
complete, it needs to be enabled on Gen >= 5.

Even though support for hiz is present only on gen >= 5, the field belongs
in intel_context, not brw_context, because the functions that interact
with DRI2 and choose buffer formats are passed an intel_context.

Signed-off-by: Chad Versace <chad.versace at intel.com>
---
 src/mesa/drivers/dri/intel/intel_context.c |    3 +++
 src/mesa/drivers/dri/intel/intel_context.h |    1 +
 2 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/src/mesa/drivers/dri/intel/intel_context.c b/src/mesa/drivers/dri/intel/intel_context.c
index acdf35f..07ce8de 100644
--- a/src/mesa/drivers/dri/intel/intel_context.c
+++ b/src/mesa/drivers/dri/intel/intel_context.c
@@ -675,6 +675,9 @@ intelInitContext(struct intel_context *intel,
       }
    }
 
+   /* FINISHME: When HiZ implementation is complete, enable it for Gen >= 5. */
+   intel->use_hiz = false;
+
    memset(&ctx->TextureFormatSupported, 0,
 	  sizeof(ctx->TextureFormatSupported));
    ctx->TextureFormatSupported[MESA_FORMAT_ARGB8888] = GL_TRUE;
diff --git a/src/mesa/drivers/dri/intel/intel_context.h b/src/mesa/drivers/dri/intel/intel_context.h
index d3a8a65..3362241 100644
--- a/src/mesa/drivers/dri/intel/intel_context.h
+++ b/src/mesa/drivers/dri/intel/intel_context.h
@@ -275,6 +275,7 @@ struct intel_context
 
    GLboolean use_texture_tiling;
    GLboolean use_early_z;
+   GLboolean use_hiz;
 
    int driFd;
 
-- 
1.7.4.2



More information about the mesa-dev mailing list