freedreno/a4xx: re-emit program on dirty framebuffer
authorIlia Mirkin <imirkin@alum.mit.edu>
Sun, 22 Nov 2015 19:06:26 +0000 (14:06 -0500)
committerIlia Mirkin <imirkin@alum.mit.edu>
Mon, 23 Nov 2015 16:17:15 +0000 (11:17 -0500)
The program emit depends on certain fb details. Make sure those get
updated when the fb changes.

Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
src/gallium/drivers/freedreno/a4xx/fd4_emit.c

index 69f263e3ba8d5bcd020492fd6458910856b47986..f220fc7ac1fc0481ab268d7a74833fc5b20f2f61 100644 (file)
@@ -613,7 +613,7 @@ fd4_emit_state(struct fd_context *ctx, struct fd_ringbuffer *ring,
                OUT_RING(ring, A4XX_GRAS_CL_VPORT_ZSCALE_0(ctx->viewport.scale[2]));
        }
 
-       if (dirty & FD_DIRTY_PROG) {
+       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);
        }