On Thu, 2007-03-08 at 14:25 +0200, Panagiotis Papadakos wrote:
> > Calling radeonSetCliprects when stamp!=lastStamp also helps!
> Sorry meant radeon->lastStamp != driDrawPriv->lastStamp 

That'll usually be fine, but in theory the stamps could be identical
when a different drawable was bound previously.

How does this patch look?

> and radeon->lastStamp != driReadPriv->lastStamp.

That comparison makes no sense as the cliprects and stamps only apply to
the drawable bound for drawing.


-- 
Earthling Michel Dänzer           |          http://tungstengraphics.com
Libre software enthusiast         |          Debian, X and DRI developer
diff --git a/src/mesa/drivers/dri/r300/radeon_context.c b/src/mesa/drivers/dri/r300/radeon_context.c
index d66f1dc..75bd70f 100644
--- a/src/mesa/drivers/dri/r300/radeon_context.c
+++ b/src/mesa/drivers/dri/r300/radeon_context.c
@@ -274,9 +274,8 @@ GLboolean radeonMakeCurrent(__DRIcontextPrivate * driContextPriv,
 		}
 
 		if (radeon->dri.drawable != driDrawPriv ||
-		    radeon->dri.readable != driReadPriv) {
+		    radeon->lastStamp != drawable->lastStamp) {
 			radeon->dri.drawable = driDrawPriv;
-			radeon->dri.readable = driReadPriv;
 
 			r300UpdateWindow(radeon->glCtx);
 			r300UpdateViewportOffset(radeon->glCtx);
@@ -284,6 +283,8 @@ GLboolean radeonMakeCurrent(__DRIcontextPrivate * driContextPriv,
 			radeonSetCliprects(radeon);
 		}
 
+		radeon->dri.readable = driReadPriv;
+
 		_mesa_make_current(radeon->glCtx,
 				    (GLframebuffer *) driDrawPriv->
 				    driverPrivate,
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
--
_______________________________________________
Dri-devel mailing list
Dri-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dri-devel

Reply via email to