X-Git-Url: http://git.draconx.ca/gitweb/gentoo-draconx.git/blobdiff_plain/7f3f6209488ef04d77ab7f08d9597f8562ab378a..77fef06b20a78cee6a698efa23331c283ed7ad92:/media-libs/mesa/files/0001-dri2-Fix-compatibility-with-old-servers.patch diff --git a/media-libs/mesa/files/0001-dri2-Fix-compatibility-with-old-servers.patch b/media-libs/mesa/files/0001-dri2-Fix-compatibility-with-old-servers.patch new file mode 100644 index 0000000..e59d4c7 --- /dev/null +++ b/media-libs/mesa/files/0001-dri2-Fix-compatibility-with-old-servers.patch @@ -0,0 +1,44 @@ +From c8327cc115997275f701993a7edbcbf42b08912b Mon Sep 17 00:00:00 2001 +From: Nick Bowler +Date: Fri, 30 Apr 2010 18:14:20 -0400 +Subject: [PATCH v3] dri2: Fix compatibility with old servers. + +Commit 61d26bc82e7c4100a ("dri2: Event driven buffer validation.") +introduced code to handle "old" servers which do not support invalidate +events (i.e. 1.8.0). However, the compatibility code causes severe +stuttering on my GM45 with "older" servers that do not support swap +events (i.e. 1.7.6). It seems that the solution is to only run the +compatibility code when swap events are supported. + +Fixes fdo bug #27277. + +Signed-off-by: Nick Bowler +--- + src/glx/dri2_glx.c | 4 ++-- + 1 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/src/glx/dri2_glx.c b/src/glx/dri2_glx.c +index 6058c72..5516324 100644 +--- a/src/glx/dri2_glx.c ++++ b/src/glx/dri2_glx.c +@@ -364,7 +364,7 @@ dri2FlushFrontBuffer(__DRIdrawable *driDrawable, void *loaderPrivate) + __GLXDRIdisplayPrivate *pdp = (__GLXDRIdisplayPrivate *)priv->dri2Display; + + /* Old servers don't send invalidate events */ +- if (!pdp->invalidateAvailable) ++ if (pdp->swapAvailable && !pdp->invalidateAvailable) + dri2InvalidateBuffers(priv->dpy, pdraw->base.drawable); + + dri2WaitGL(loaderPrivate); +@@ -428,7 +428,7 @@ dri2SwapBuffers(__GLXDRIdrawable *pdraw, int64_t target_msc, int64_t divisor, + #endif + + /* Old servers don't send invalidate events */ +- if (!pdp->invalidateAvailable) ++ if (pdp->swapAvailable && !pdp->invalidateAvailable) + dri2InvalidateBuffers(dpyPriv->dpy, pdraw->drawable); + + /* Old servers can't handle swapbuffers */ +-- +1.6.4.4 +