diff options
author | Eric Anholt <[email protected]> | 2017-11-01 14:04:45 -0700 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2017-11-07 09:19:48 -0800 |
commit | 735b844b1b32a440738b1a6096ea3aa4df6b52a7 (patch) | |
tree | 0934aa2c9e15c968ef75c7b58d2be576cb72c43c /src | |
parent | 386e9362a5711db9344229e4e05953d95a33d114 (diff) |
broadcom/vc5: Skip emitting depth offset while disabled.
The enable flag is also in the rasterizer state, so it will be emitted
once it's needed.
Diffstat (limited to 'src')
-rw-r--r-- | src/gallium/drivers/vc5/vc5_emit.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/gallium/drivers/vc5/vc5_emit.c b/src/gallium/drivers/vc5/vc5_emit.c index 0c2cde70880..06df16730c2 100644 --- a/src/gallium/drivers/vc5/vc5_emit.c +++ b/src/gallium/drivers/vc5/vc5_emit.c @@ -277,14 +277,17 @@ vc5_emit_state(struct pipe_context *pctx) } - if (vc5->dirty & VC5_DIRTY_RASTERIZER) { + if (vc5->dirty & VC5_DIRTY_RASTERIZER && + vc5->rasterizer->base.offset_tri) { cl_emit(&job->bcl, DEPTH_OFFSET, depth) { depth.depth_offset_factor = vc5->rasterizer->offset_factor; depth.depth_offset_units = vc5->rasterizer->offset_units; } + } + if (vc5->dirty & VC5_DIRTY_RASTERIZER) { cl_emit(&job->bcl, POINT_SIZE, point_size) { point_size.point_size = vc5->rasterizer->point_size; } |