From d1bdc1238a39469e6760758876e8832019795a54 Mon Sep 17 00:00:00 2001 From: Ilia Mirkin Date: Sat, 11 Jun 2016 16:52:17 -0400 Subject: st/mesa: add support for GL_EXT_window_rectangles MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Make sure to pass the requisite information in draws, blits, and clears that work on the context's draw buffer. Signed-off-by: Ilia Mirkin Reviewed-by: Nicolai Hähnle --- src/mesa/state_tracker/st_cb_blit.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/mesa/state_tracker/st_cb_blit.c') diff --git a/src/mesa/state_tracker/st_cb_blit.c b/src/mesa/state_tracker/st_cb_blit.c index a05a5aff4c6..be0b1030996 100644 --- a/src/mesa/state_tracker/st_cb_blit.c +++ b/src/mesa/state_tracker/st_cb_blit.c @@ -40,6 +40,7 @@ #include "st_cb_blit.h" #include "st_cb_fbo.h" #include "st_manager.h" +#include "st_scissor.h" #include "util/u_format.h" @@ -117,6 +118,7 @@ st_BlitFramebuffer(struct gl_context *ctx, &clip.dstX0, &clip.dstY0, &clip.dstX1, &clip.dstY1)) { return; /* nothing to draw/blit */ } + memset(&blit, 0, sizeof(struct pipe_blit_info)); blit.scissor_enable = (dstX0 != clip.dstX0) || (dstY0 != clip.dstY0) || @@ -190,6 +192,9 @@ st_BlitFramebuffer(struct gl_context *ctx, blit.src.box.height = srcY0 - srcY1; } + if (drawFB != ctx->WinSysDrawBuffer) + st_window_rectangles_to_blit(ctx, &blit); + blit.filter = pFilter; blit.render_condition_enable = TRUE; blit.alpha_blend = FALSE; -- cgit v1.2.3