i965/fb: Use meta path for stencil blits
authorTopi Pohjolainen <topi.pohjolainen@intel.com>
Sat, 19 Apr 2014 14:11:10 +0000 (17:11 +0300)
committerTopi Pohjolainen <topi.pohjolainen@intel.com>
Thu, 15 May 2014 18:39:33 +0000 (21:39 +0300)
This is effective only on gen8 for now as previous generations still
go through blorp.

Cc: "10.2" <mesa-stable@lists.freedesktop.org>
Signed-off-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/drivers/dri/i965/intel_fbo.c

index 61c24efd6348eff8eda65cfeb806d68b6643f230..5ff4263d48f209d57f2b58b3ecf08bb3e35fd872 100644 (file)
@@ -879,6 +879,15 @@ intel_blit_framebuffer(struct gl_context *ctx,
    if (mask == 0x0)
       return;
 
+   if (mask & GL_STENCIL_BUFFER_BIT) {
+      brw_meta_fbo_stencil_blit(brw_context(ctx),
+                                srcX0, srcY0, srcX1, srcY1,
+                                dstX0, dstY0, dstX1, dstY1);
+      mask &= ~GL_STENCIL_BUFFER_BIT;
+      if (mask == 0x0)
+         return;
+   }
+
    /* Try using the BLT engine. */
    mask = intel_blit_framebuffer_with_blitter(ctx,
                                               srcX0, srcY0, srcX1, srcY1,