diff options
author | Rob Clark <[email protected]> | 2016-03-05 16:53:11 -0500 |
---|---|---|
committer | Rob Clark <[email protected]> | 2016-03-13 12:23:41 -0400 |
commit | f68c6951b86ac38ebdb89bc6b5a6285433e684a6 (patch) | |
tree | 94e5a8268fc5fe875d88120a3010e14537d79d57 /src/gallium/drivers/freedreno/a4xx/fd4_emit.c | |
parent | b3fe196e21dbbb51e62ed42dce890ada2bfd6db8 (diff) |
freedreno/a4xx: hw binning
Signed-off-by: Rob Clark <[email protected]>
Diffstat (limited to 'src/gallium/drivers/freedreno/a4xx/fd4_emit.c')
-rw-r--r-- | src/gallium/drivers/freedreno/a4xx/fd4_emit.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/gallium/drivers/freedreno/a4xx/fd4_emit.c b/src/gallium/drivers/freedreno/a4xx/fd4_emit.c index 58ddf2aeebe..81ed16ce8ac 100644 --- a/src/gallium/drivers/freedreno/a4xx/fd4_emit.c +++ b/src/gallium/drivers/freedreno/a4xx/fd4_emit.c @@ -606,7 +606,11 @@ fd4_emit_state(struct fd_context *ctx, struct fd_ringbuffer *ring, if (dirty & (FD_DIRTY_PROG | FD_DIRTY_FRAMEBUFFER)) { struct pipe_framebuffer_state *pfb = &ctx->framebuffer; - fd4_program_emit(ring, emit, pfb->nr_cbufs, pfb->cbufs); + unsigned n = pfb->nr_cbufs; + /* if we have depth/stencil, we need at least on MRT: */ + if (pfb->zsbuf) + n = MAX2(1, n); + fd4_program_emit(ring, emit, n, pfb->cbufs); } if (emit->prog == &ctx->prog) { /* evil hack to deal sanely with clear path */ |