diff options
author | Eric Anholt <[email protected]> | 2017-07-27 12:05:56 -0700 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2017-10-10 10:45:22 -0700 |
commit | 087b39a3460e796cee04b754d8cb08251c7a51bc (patch) | |
tree | d3dd4156b1b3d3ef3b2ce898c7b6a4cc0d675e86 /src/gallium/drivers/vc4/vc4_job.c | |
parent | ac0051a5075879970f12f614890c9c6d732663b6 (diff) |
broadcom/vc4: Expose PIPE_CAP_TILE_RASTER_ORDER
Because vc4 can control the order that tiles are rasterized in, we can use
it to implement overlapping blits using normal drawing and
GL_ARB_texture_barrier, as long as we can tell the kernel what order to
render the tiles in.
v2: Fix on the simulator.
v3: Add the cap (disabled) to other drivers, add rst docs for the cap.
v4: Rebase on PIPE_CAP_TGSI_ANY_REG_AS_ADDRESS
v5: Split from the core gallium commit, drop some unnecessary code related
to glBlitFramebuffer(), fix a crash with clears before state has been
bound.
Diffstat (limited to 'src/gallium/drivers/vc4/vc4_job.c')
-rw-r--r-- | src/gallium/drivers/vc4/vc4_job.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/gallium/drivers/vc4/vc4_job.c b/src/gallium/drivers/vc4/vc4_job.c index 6a1d1a4cebf..7fe20c16bad 100644 --- a/src/gallium/drivers/vc4/vc4_job.c +++ b/src/gallium/drivers/vc4/vc4_job.c @@ -264,6 +264,13 @@ vc4_get_job_for_fbo(struct vc4_context *vc4) job->draw_tiles_y = DIV_ROUND_UP(vc4->framebuffer.height, job->tile_height); + /* Initialize the job with the raster order flags -- each draw will + * check that we haven't changed the flags, since that requires a + * flush. + */ + if (vc4->rasterizer) + job->flags = vc4->rasterizer->tile_raster_order_flags; + vc4->job = job; return job; @@ -461,6 +468,7 @@ vc4_job_submit(struct vc4_context *vc4, struct vc4_job *job) submit.clear_z = job->clear_depth; submit.clear_s = job->clear_stencil; } + submit.flags |= job->flags; if (!(vc4_debug & VC4_DEBUG_NORAST)) { int ret; |