A call to radeon_prepare_render() at the beginning of draw
operations was placed too deep in the call chain,
inside r300RunRenderPrimitive(), instead of
r300DrawPrims() where it belongs. This leads to
emission of stale target color renderbuffer into the cs if
bufferswaps via page-flipping are used, and thereby causes
massive rendering corruption due to unsynchronized
rendering into the active frontbuffer.
This patch fixes such problems for use with the
upcoming radeon page-flipping patches.
Signed-off-by: Mario Kleiner <mario.kleiner@tuebingen.mpg.de>
GLuint max_index)
{
GLboolean retval;
+ struct r300_context *r300 = R300_CONTEXT(ctx);
+ radeonContextPtr radeon = &r300->radeon;
+
+ radeon_prepare_render(radeon);
/* This check should get folded into just the places that
* min/max index are really needed.
BATCH_LOCALS(&rmesa->radeon);
int type, num_verts;
- radeon_prepare_render(&rmesa->radeon);
-
type = r300PrimitiveType(rmesa, prim);
num_verts = r300NumVerts(rmesa, end - start, prim);