diff options
author | Eric Anholt <[email protected]> | 2008-01-10 10:48:05 -0800 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2008-01-10 12:34:08 -0800 |
commit | a04b632350e5d0e9994fc667afc59407a39da0ba (patch) | |
tree | 8907f56e859999fe2448530e4f98fc29656a65b9 /src/mesa/drivers/dri/intel/intel_buffers.c | |
parent | 7086df58688dc375ffd4c0fb9a9884eae05a6e46 (diff) |
[intel] Add more cliprect modes to cover other meanings for batch emits.
The previous change gave us only two modes, one which looped over the batch
per cliprect (3d drawing) and one that didn't (state updeast).
However, we really want 4:
- Batch doesn't care about cliprects (state updates)
- Batch needs DRAWING_RECTANGLE looping per cliprect (3d drawing)
- Batch needs to be executed just once (region fills, copies, etc.)
- Batch already includes cliprect handling, and must be flushed by unlock time
(copybuffers, clears).
All callers should now be fixed to use one of these states for any batchbuffer
emits. Thanks to Keith Whitwell for pointing out the failure.
Diffstat (limited to 'src/mesa/drivers/dri/intel/intel_buffers.c')
-rw-r--r-- | src/mesa/drivers/dri/intel/intel_buffers.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/src/mesa/drivers/dri/intel/intel_buffers.c b/src/mesa/drivers/dri/intel/intel_buffers.c index 73872a97a02..ceb30583519 100644 --- a/src/mesa/drivers/dri/intel/intel_buffers.c +++ b/src/mesa/drivers/dri/intel/intel_buffers.c @@ -469,9 +469,6 @@ intelClearWithTris(struct intel_context *intel, GLbitfield mask) intel->vtbl.meta_color_mask(intel, GL_TRUE); intel->vtbl.meta_draw_region(intel, irbColor->region, NULL); - /* XXX: Using INTEL_BATCH_NO_CLIPRECTS here is dangerous as the - * drawing origin may not be correctly emitted. - */ intel->vtbl.meta_draw_quad(intel, fb->_Xmin, fb->_Xmax, @@ -625,7 +622,7 @@ intelClear(GLcontext *ctx, GLbitfield mask) /* Emit wait for pending flips */ void -intel_wait_flips(struct intel_context *intel, GLuint batch_flags) +intel_wait_flips(struct intel_context *intel) { struct intel_framebuffer *intel_fb = (struct intel_framebuffer *) intel->ctx.DrawBuffer; @@ -641,7 +638,7 @@ intel_wait_flips(struct intel_context *intel, GLuint batch_flags) BATCH_LOCALS; /* Wait for pending flips to take effect */ - BEGIN_BATCH(2, batch_flags); + BEGIN_BATCH(2, NO_LOOP_CLIPRECTS); OUT_BATCH(pf_planes & 0x1 ? (MI_WAIT_FOR_EVENT | MI_WAIT_FOR_PLANE_A_FLIP) : 0); OUT_BATCH(pf_planes & 0x2 ? (MI_WAIT_FOR_EVENT | MI_WAIT_FOR_PLANE_B_FLIP) |