i965/blorp: Add fields brw_blorp_mip_info::level,layer
authorChad Versace <chad.versace@linux.intel.com>
Wed, 20 Mar 2013 00:44:50 +0000 (17:44 -0700)
committerChad Versace <chad.versace@linux.intel.com>
Wed, 10 Apr 2013 17:55:10 +0000 (10:55 -0700)
The new fields define the 2D miptree slice to be used. A following patch
will pass the new fields through to intel_miptree_slice_has_hiz().

Reviewed-by: Eric Anholt <eric@anholt.net>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Signed-off-by: Chad Versace <chad.versace@linux.intel.com>
src/mesa/drivers/dri/i965/brw_blorp.cpp
src/mesa/drivers/dri/i965/brw_blorp.h

index ed966c6353f217ca258c87d510752c0d527736ea..9c6fe498e84107ea6c7fb81d211eceacabd0e4f1 100644 (file)
@@ -30,6 +30,8 @@
 
 brw_blorp_mip_info::brw_blorp_mip_info()
    : mt(NULL),
+     level(0),
+     layer(0),
      width(0),
      height(0),
      x_offset(0),
@@ -50,6 +52,8 @@ brw_blorp_mip_info::set(struct intel_mipmap_tree *mt,
    intel_miptree_check_level_layer(mt, level, layer);
 
    this->mt = mt;
+   this->level = level;
+   this->layer = layer;
    this->width = mt->level[level].width;
    this->height = mt->level[level].height;
 
index 79a3f3ae79f80d4bcd9cb74390b89e179e209c9b..1b958182483da26ab70124f0c178308946a268cc 100644 (file)
@@ -68,6 +68,17 @@ public:
 
    struct intel_mipmap_tree *mt;
 
+   /**
+    * The miplevel to use.
+    */
+   uint32_t level;
+
+   /**
+    * The 2D layer within the miplevel. Combined, level and layer define the
+    * 2D miptree slice to use.
+    */
+   uint32_t layer;
+
    /**
     * Width of the miplevel to be used.  For surfaces using
     * INTEL_MSAA_LAYOUT_IMS, this is measured in samples, not pixels.