[Mesa-dev] [PATCH 11/41] intel: Kill intel_mipmap_level::nr_images

Eric Anholt eric at anholt.net
Fri Nov 18 15:57:09 PST 2011


On Fri, 18 Nov 2011 13:36:25 -0800, Chad Versace <chad.versace at linux.intel.com> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> On 11/18/2011 12:22 PM, Eric Anholt wrote:
> > On Thu, 17 Nov 2011 19:58:38 -0800, Chad Versace <chad.versace at linux.intel.com> wrote:
> >>    - For GL_TEXTURE_3D, it is the texture's depth at each miplevel. It's
> >>      value, like width and height, varies with miplevel.
> > 
> > "Its"
> 
> I'll fix the two "It's".
> 
> >> diff --git a/src/mesa/drivers/dri/intel/intel_fbo.c b/src/mesa/drivers/dri/intel/intel_fbo.c
> > The changes in this file don't seem to fit in this patch.
> 
> Oops. These hunks are complete mistake. I assume they were introduced by a rebase.
> They will be removed.
> 
> >> diff --git a/src/mesa/drivers/dri/intel/intel_tex_validate.c b/src/mesa/drivers/dri/intel/intel_tex_validate.c
> >> index f4c1a68..8dad011 100644
> >> --- a/src/mesa/drivers/dri/intel/intel_tex_validate.c
> >> +++ b/src/mesa/drivers/dri/intel/intel_tex_validate.c
> >> @@ -140,12 +140,13 @@ intel_tex_map_image_for_swrast(struct intel_context *intel,
> >>     if (mt->target == GL_TEXTURE_3D ||
> >>         mt->target == GL_TEXTURE_2D_ARRAY ||
> >>         mt->target == GL_TEXTURE_1D_ARRAY) {
> >> -      int i;
> >>  
> >>        /* ImageOffsets[] is only used for swrast's fetch_texel_3d, so we can't
> >>         * share code with the normal path.
> >>         */
> >> -      for (i = 0; i < mt->level[level].depth; i++) {
> >> +      assert(face == 0);
> >> +      int depth = mt->level[level].depth;
> >> +      for (int i = 0; i < depth; i++) {
> >>  	 intel_miptree_get_image_offset(mt, level, face, i, &x, &y);
> >>  	 intel_image->base.ImageOffsets[i] = x + y * mt->region->pitch;
> >>        }
> > 
> > Not really seeing the point of this hunk (pulling depth out of the loop)
> 
> This is really a sloppy commit. There is no need for this hunk either.
> 
> Other than the spurious hunks, are you ok with this patch?

Yeah, r-b other than that.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20111118/48ec81f1/attachment.pgp>


More information about the mesa-dev mailing list