[PATCH] EXA: Glyph cache upload tweaks.
Michel Dänzer
michel at tungstengraphics.com
Mon Apr 28 20:00:55 BST 2008
Track damage after using UploadToScreen directly.
Don't waste any effort on empty glyphs.
---
exa/exa_glyphs.c | 9 ++++++++-
1 files changed, 8 insertions(+), 1 deletions(-)
diff --git a/exa/exa_glyphs.c b/exa/exa_glyphs.c
index 95ff4d8..b618365 100644
--- a/exa/exa_glyphs.c
+++ b/exa/exa_glyphs.c
@@ -394,6 +394,12 @@ exaGlyphCacheUploadGlyph(ScreenPtr pScreen,
pExaPixmap->sys_pitch))
return FALSE;
+ exaPixmapDirty (pCachePixmap,
+ CACHE_X(pos) + cacheXoff,
+ CACHE_Y(pos) + cacheYoff,
+ CACHE_X(pos) + cacheXoff + pGlyph->info.width,
+ CACHE_Y(pos) + cacheYoff + pGlyph->info.height);
+
return TRUE;
}
@@ -737,7 +743,8 @@ exaGlyphs (CARD8 op,
glyph = *glyphs++;
pPicture = GlyphPicture (glyph)[pScreen->myNum];
- if (exaBufferGlyph(pScreen, &buffer, glyph, x, y) == ExaGlyphNeedFlush)
+ if (glyph->info.width > 0 && glyph->info.height > 0 &&
+ exaBufferGlyph(pScreen, &buffer, glyph, x, y) == ExaGlyphNeedFlush)
{
if (maskFormat)
exaGlyphsToMask(pMask, &buffer);
--
1.6.0.4
--------------020803010907060606020907
Content-Type: text/x-patch;
name="0007-EXA-Accumulate-glyphs-whenever-possible-for-full-b.patch"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
filename*0="0007-EXA-Accumulate-glyphs-whenever-possible-for-full-b.patc";
filename*1="h"
More information about the Ubuntu-x
mailing list