From: Brian Paul Date: Tue, 3 Mar 2009 00:51:44 +0000 (-0700) Subject: mesa: comments and code documenting a bug with depth 32 TrueColor drawing/reading X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=d652d26a975a884fecd9c407e77b7259fb291906;p=mesa.git mesa: comments and code documenting a bug with depth 32 TrueColor drawing/reading It seems that XGetImage() from a depth 32 TrueColor window is flakey. Drawing with XPutImage() instead of XPutPixel() seems to work better, but still not perfectly. Keep using the original code for now until more is learned. --- diff --git a/src/mesa/drivers/x11/xm_span.c b/src/mesa/drivers/x11/xm_span.c index 57b57494483..309cefcb8e8 100644 --- a/src/mesa/drivers/x11/xm_span.c +++ b/src/mesa/drivers/x11/xm_span.c @@ -471,8 +471,26 @@ static void put_row_8R8G8B_pixmap( PUT_ROW_ARGS ) if (mask) { for (i=0;iDrawBuffer)->rowimage; + GLuint *ptr4 = (GLuint *) rowimg->data; + *ptr4 = PACK_8R8G8B( rgba[i][RCOMP], rgba[i][GCOMP], rgba[i][BCOMP] ); + XMesaPutImage( dpy, buffer, gc, rowimg, 0, 0, x, y, 1, 1 ); +#endif } } }