Mesa (master): i965/fbo: Only try stencil meta blits on gen >= 8

Kenneth Graunke kwg at kemper.freedesktop.org
Mon May 19 18:19:17 UTC 2014


Module: Mesa
Branch: master
Commit: 21dddb22c12614c1d4a4f3d1664a3f38678cfbb1
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=21dddb22c12614c1d4a4f3d1664a3f38678cfbb1

Author: Topi Pohjolainen <topi.pohjolainen at intel.com>
Date:   Mon May 19 10:10:33 2014 +0300

i965/fbo: Only try stencil meta blits on gen >= 8

I don't have an ILK at hand but the fix should be trivial.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=78872
Cc: "10.2" <mesa-stable at lists.freedesktop.org>
Signed-off-by: Topi Pohjolainen <topi.pohjolainen at intel.com>
Reviewed-and-tested-by: Kenneth Graunke <kenneth at whitecape.org>

---

 src/mesa/drivers/dri/i965/intel_fbo.c |    6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/src/mesa/drivers/dri/i965/intel_fbo.c b/src/mesa/drivers/dri/i965/intel_fbo.c
index 5ff4263..6c99de9 100644
--- a/src/mesa/drivers/dri/i965/intel_fbo.c
+++ b/src/mesa/drivers/dri/i965/intel_fbo.c
@@ -865,6 +865,8 @@ intel_blit_framebuffer(struct gl_context *ctx,
                        GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1,
                        GLbitfield mask, GLenum filter)
 {
+   struct brw_context *brw = brw_context(ctx);
+
    /* Page 679 of OpenGL 4.4 spec says:
     *    "Added BlitFramebuffer to commands affected by conditional rendering in
     *     section 10.10 (Bug 9562)."
@@ -872,14 +874,14 @@ intel_blit_framebuffer(struct gl_context *ctx,
    if (!_mesa_check_conditional_render(ctx))
       return;
 
-   mask = brw_blorp_framebuffer(brw_context(ctx),
+   mask = brw_blorp_framebuffer(brw,
                                 srcX0, srcY0, srcX1, srcY1,
                                 dstX0, dstY0, dstX1, dstY1,
                                 mask, filter);
    if (mask == 0x0)
       return;
 
-   if (mask & GL_STENCIL_BUFFER_BIT) {
+   if (brw->gen >= 8 && (mask & GL_STENCIL_BUFFER_BIT)) {
       brw_meta_fbo_stencil_blit(brw_context(ctx),
                                 srcX0, srcY0, srcX1, srcY1,
                                 dstX0, dstY0, dstX1, dstY1);




More information about the mesa-commit mailing list