diff options
author | Eric Anholt <[email protected]> | 2017-07-24 14:45:49 -0700 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2017-07-25 14:44:52 -0700 |
commit | 16e17ce04b60ac6f3d9a89535ea583fabebead7a (patch) | |
tree | 04628663f50c1b31fabebedea1681ce047aec445 /src | |
parent | 93fec49a75ce799bb6fe167f9409fd553a5781c6 (diff) |
broadcom/vc4: Scissor blits performed using the rendering engine.
Without this, a BlitFramebuffer would mark the whole framebuffer as being
changed (so we emit loads/stores of all of it) rather than just the
modified subset.
Diffstat (limited to 'src')
-rw-r--r-- | src/gallium/drivers/vc4/vc4_blit.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/gallium/drivers/vc4/vc4_blit.c b/src/gallium/drivers/vc4/vc4_blit.c index 0e4ab5bfa0c..7f4c76968e7 100644 --- a/src/gallium/drivers/vc4/vc4_blit.c +++ b/src/gallium/drivers/vc4/vc4_blit.c @@ -195,6 +195,15 @@ vc4_render_blit(struct pipe_context *ctx, struct pipe_blit_info *info) return false; } + /* Enable the scissor, so we get a minimal set of tiles rendered. */ + if (!info->scissor_enable) { + info->scissor_enable = true; + info->scissor.minx = info->dst.box.x; + info->scissor.miny = info->dst.box.y; + info->scissor.maxx = info->dst.box.x + info->dst.box.width; + info->scissor.maxy = info->dst.box.y + info->dst.box.height; + } + vc4_blitter_save(vc4); util_blitter_blit(vc4->blitter, info); |