summaryrefslogtreecommitdiff
path: root/src/mesa/drivers/dri/i915/intel_tris.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/drivers/dri/i915/intel_tris.c')
-rw-r--r--src/mesa/drivers/dri/i915/intel_tris.c17
1 files changed, 5 insertions, 12 deletions
diff --git a/src/mesa/drivers/dri/i915/intel_tris.c b/src/mesa/drivers/dri/i915/intel_tris.c
index 6ed54b072a..9d93636900 100644
--- a/src/mesa/drivers/dri/i915/intel_tris.c
+++ b/src/mesa/drivers/dri/i915/intel_tris.c
@@ -89,29 +89,20 @@ intelStartInlinePrimitive(struct intel_context *intel,
{
BATCH_LOCALS;
+ intel_wait_flips(intel);
+
intel->vtbl.emit_state(intel);
- /* Need to make sure at the very least that we don't wrap
- * batchbuffers in BEGIN_BATCH below, otherwise the primitive will
- * be emitted to a batchbuffer missing the required full-state
- * preamble.
- */
- if (intel_batchbuffer_space(intel->batch) < 100) {
- intel_batchbuffer_flush(intel->batch);
- intel->vtbl.emit_state(intel);
- }
+ intel->no_batch_wrap = GL_TRUE;
/* _mesa_printf("%s *", __progname); */
- intel_wait_flips(intel);
-
/* Emit a slot which will be filled with the inline primitive
* command later.
*/
BEGIN_BATCH(2, batch_flags);
OUT_BATCH(0);
- assert(intel->batch->id == intel->last_state_batch_id);
assert((intel->batch->dirty_state & (1<<1)) == 0);
intel->prim.start_ptr = intel->batch->ptr;
@@ -121,6 +112,8 @@ intelStartInlinePrimitive(struct intel_context *intel,
OUT_BATCH(0);
ADVANCE_BATCH();
+ intel->no_batch_wrap = GL_FALSE;
+
/* _mesa_printf(">"); */
}