i965/gen7: Minify blit size for stencil tree copy
authorJordan Justen <jordan.l.justen@intel.com>
Wed, 16 Nov 2016 01:55:41 +0000 (17:55 -0800)
committerJordan Justen <jordan.l.justen@intel.com>
Thu, 17 Nov 2016 22:15:44 +0000 (14:15 -0800)
Found by the piglit 'fbo-depth-array stencil-clear' test when
implementing blorp blit splitting for gen7.

Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Ben Widawsky <ben@bwidawsk.net>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
src/mesa/drivers/dri/i965/intel_mipmap_tree.c

index 28001b643bd3162de9fed6c029765552a1f603e9..e7f71c09730caf39a1f2a4b13eb0b446bda2f87d 100644 (file)
@@ -2373,9 +2373,11 @@ intel_update_r8stencil(struct brw_context *brw,
                                  dst, level, layers_per_blit * layer,
                                  MESA_FORMAT_R_UNORM8,
                                  0, 0,
-                                 src->logical_width0, src->logical_height0,
+                                 minify(src->logical_width0, level),
+                                 minify(src->logical_height0, level),
                                  0, 0,
-                                 dst->logical_width0, dst->logical_height0,
+                                 minify(dst->logical_width0, level),
+                                 minify(dst->logical_height0, level),
                                  GL_NEAREST, false, false /*mirror x, y*/,
                                  false, false /* decode/encode srgb */);
       }